From: shenjiatong Date: Sun, 17 Nov 2024 14:44:26 +0000 (+0800) Subject: QEMU: allow to hot plugging virtio-serial-pci device X-Git-Tag: v10.10.0-rc1~74 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c54df8ed9e25d6d9dad63750f6b607a0398f7aff;p=thirdparty%2Flibvirt.git QEMU: allow to hot plugging virtio-serial-pci device Virtio-serial-pci device is hot pluggable, loosen the restriction and allow user to hot plug it. Signed-off-by: shenjiatong Reviewed-by: Michal Privoznik --- diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c index bddd553c88..55512476e4 100644 --- a/src/qemu/qemu_hotplug.c +++ b/src/qemu/qemu_hotplug.c @@ -837,7 +837,8 @@ qemuDomainAttachControllerDevice(virDomainObj *vm, { .controller = controller } }; bool releaseaddr = false; - if (controller->type != VIR_DOMAIN_CONTROLLER_TYPE_SCSI) { + if (controller->type != VIR_DOMAIN_CONTROLLER_TYPE_SCSI && \ + controller->type != VIR_DOMAIN_CONTROLLER_TYPE_VIRTIO_SERIAL) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, _("'%1$s' controller cannot be hot plugged."), virDomainControllerTypeToString(controller->type));