]> git.ipfire.org Git - thirdparty/libvirt.git/commit
qemu/conf: set HOTPLUGGABLE connect flag during PCI address set init
authorLaine Stump <laine@redhat.com>
Mon, 6 Apr 2020 02:40:37 +0000 (22:40 -0400)
committerLaine Stump <laine@redhat.com>
Mon, 13 Apr 2020 02:39:51 +0000 (22:39 -0400)
commitaa15e9259f1f246e69fb9742581ced720c88695d
tree7b86ddb25312fb6fc33f519cdc3dff8d77d5d586
parentfcdf87d3ef14de9dfb0acaf4b4445e1580dfc629
qemu/conf: set HOTPLUGGABLE connect flag during PCI address set init

virDomainPCIAddressBusSetModel() is called for each PCI controller
when building an address set prior to assiging PCI addresses to
devices.

This patch adds a new argument, allowHotplug, to that function that
can be set to false if we know for certain that a particular
controller won't support hotplug

The most interesting case is in qemuDomainPCIAddressSetCreate(), where
the config of each existing controller is available while building the
address set, so we can appropriately set allowHotplug = false when the
user has "hotplug='off'" in the config of a controller that normally
would support hotplug. In all other cases, it is set to true or false
in accordance with the capability of the controller model.

So far we aren't doing anything with this bus flag in the address set.

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
src/conf/domain_addr.c
src/conf/domain_addr.h
src/qemu/qemu_domain_address.c