virDomainAuditMemory(vm, 0, virDomainDefGetMemoryActual(vm->def),
"start", true);
virDomainAuditVcpu(vm, 0, vm->def->vcpus, "start", true);
- if (vm->def->iothreads)
- virDomainAuditIOThread(vm, 0, vm->def->iothreads, "start", true);
+ if (vm->def->niothreadids)
+ virDomainAuditIOThread(vm, 0, vm->def->niothreadids, "start", true);
virDomainAuditLifecycle(vm, "start", reason, success);
}
goto error;
}
if (n) {
- if (n > def->iothreads) {
+ if (n > def->niothreadids) {
virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
_("too many iothreadsched nodes in cputune"));
goto error;
virBufferAsprintf(buf, " current='%u'", def->vcpus);
virBufferAsprintf(buf, ">%u</vcpu>\n", def->maxvcpus);
- if (def->iothreads > 0) {
+ if (def->niothreadids > 0) {
virBufferAsprintf(buf, "<iothreads>%u</iothreads>\n",
def->iothreads);
/* Only print out iothreadids if we read at least one */
virCommandAddArg(cmd, smp);
VIR_FREE(smp);
- if (def->iothreads > 0 &&
+ if (def->niothreadids > 0 &&
virQEMUCapsGet(qemuCaps, QEMU_CAPS_OBJECT_IOTHREAD)) {
/* Create iothread objects using the defined iothreadids list
* and the defined id and name from the list. These may be used
size_t i;
int ret = -1;
- if (targetDef->iothreads == 0)
+ if (targetDef->niothreadids == 0)
return 0;
if ((hostcpus = nodeGetCPUCount(NULL)) < 0)
goto cleanup;
- if (VIR_ALLOC_N(info_ret, targetDef->iothreads) < 0)
+ if (VIR_ALLOC_N(info_ret, targetDef->niothreadids) < 0)
goto cleanup;
for (i = 0; i < targetDef->niothreadids; i++) {
*info = info_ret;
info_ret = NULL;
- ret = targetDef->iothreads;
+ ret = targetDef->niothreadids;
cleanup:
if (info_ret) {
- for (i = 0; i < targetDef->iothreads; i++)
+ for (i = 0; i < targetDef->niothreadids; i++)
virDomainIOThreadInfoFree(info_ret[i]);
VIR_FREE(info_ret);
}
size_t idx;
int rc = -1;
int ret = -1;
- unsigned int orig_niothreads = vm->def->iothreads;
- unsigned int exp_niothreads = vm->def->iothreads;
+ unsigned int orig_niothreads = vm->def->niothreadids;
+ unsigned int exp_niothreads = vm->def->niothreadids;
int new_niothreads = 0;
qemuMonitorIOThreadInfoPtr *new_iothreads = NULL;
virCgroupPtr cgroup_iothread = NULL;
char *alias = NULL;
int rc = -1;
int ret = -1;
- unsigned int orig_niothreads = vm->def->iothreads;
- unsigned int exp_niothreads = vm->def->iothreads;
+ unsigned int orig_niothreads = vm->def->niothreadids;
+ unsigned int exp_niothreads = vm->def->niothreadids;
int new_niothreads = 0;
qemuMonitorIOThreadInfoPtr *new_iothreads = NULL;
if (niothreads < 0)
goto cleanup;
- if (niothreads != vm->def->iothreads) {
+ if (niothreads != vm->def->niothreadids) {
virReportError(VIR_ERR_INTERNAL_ERROR,
_("got wrong number of IOThread pids from QEMU monitor. "
- "got %d, wanted %d"),
- niothreads, vm->def->iothreads);
+ "got %d, wanted %zu"),
+ niothreads, vm->def->niothreadids);
goto cleanup;
}