mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-28 13:57:42 +03:00
qemuDomainSupportsVcpuHotplug: Base return value on virQEMUCapsGetMachineHotplugCpus
The QEMU_CAPS_QUERY_HOTPLUGGABLE_CPUS flag is always asserted as all qemu versions support the command and selectively cleared when copying the capabilities for VM use if given machine type does not support cpu hotplug. Rework this to directly probe the machine as we now populate the data also when re-connecting to a qemu instance after daemon restart, so that the capability can be removed. Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
51daa85d7c
commit
4d82bce836
@ -9985,7 +9985,9 @@ qemuDomainSupportsVcpuHotplug(virDomainObj *vm)
|
||||
{
|
||||
qemuDomainObjPrivate *priv = vm->privateData;
|
||||
|
||||
return virQEMUCapsGet(priv->qemuCaps, QEMU_CAPS_QUERY_HOTPLUGGABLE_CPUS);
|
||||
return virQEMUCapsGetMachineHotplugCpus(priv->qemuCaps,
|
||||
vm->def->virtType,
|
||||
vm->def->os.machine);
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user