On 10/5/21 1:51 AM, Ani Sinha wrote:
qemu added support for i440fx specific global boolean flag

PIIX4_PM.acpi-pci-hotplug-with-bridge-support

around version 2.1. This flag is enabled by default. When disabled, it turns
off acpi pci hotplug for cold plugged pci bridges in i440fx machine types.

Very recently, in qemu version 6.1, the same global option was also added for
q35 machine types as well.

ICH9-LPC.acpi-pci-hotplug-with-bridge-support

This option turns on or off acpi based hotplug for cold plugged pcie bridges
like pcie root ports. This flag is also enabled by default. Please refer to
the following qemu changes:

c0e427d6eb5fef ("hw/acpi/ich9: Enable ACPI PCI hot-plug")
17858a16950860 ("hw/acpi/ich9: Set ACPI PCI hot-plug as default on Q35")

This patch adds the corresponding qemu capabilities in libvirt. For i440fx,
the capability is detected as QEMU_CAPS_PIIX_ACPI_HOTPLUG_BRIDGE. For q35,
the capability is detected as QEMU_CAPS_ICH9_ACPI_HOTPLUG_BRIDGE.

Please note that the test specific qemu capabilities .replies files has already
been updated as a part of regular refreshing them when a new qemu version is
released. Hence, no updates to those files are required.

Signed-off-by: Ani Sinha <a...@anisinha.ca>
Reviewed-by: Laine Stump <la...@redhat.com>
---
  src/qemu/qemu_capabilities.c                      | 4 ++++
  src/qemu/qemu_capabilities.h                      | 2 ++
  tests/qemucapabilitiesdata/caps_2.11.0.x86_64.xml | 1 +
  tests/qemucapabilitiesdata/caps_2.12.0.x86_64.xml | 1 +
  tests/qemucapabilitiesdata/caps_3.0.0.x86_64.xml  | 1 +
  tests/qemucapabilitiesdata/caps_3.1.0.x86_64.xml  | 1 +
  tests/qemucapabilitiesdata/caps_4.0.0.x86_64.xml  | 1 +
  tests/qemucapabilitiesdata/caps_4.1.0.x86_64.xml  | 1 +
  tests/qemucapabilitiesdata/caps_4.2.0.x86_64.xml  | 1 +
  tests/qemucapabilitiesdata/caps_5.0.0.x86_64.xml  | 1 +
  tests/qemucapabilitiesdata/caps_5.1.0.x86_64.xml  | 1 +
  tests/qemucapabilitiesdata/caps_5.2.0.x86_64.xml  | 1 +
  tests/qemucapabilitiesdata/caps_6.0.0.x86_64.xml  | 1 +
  tests/qemucapabilitiesdata/caps_6.1.0.x86_64.xml  | 2 ++
  14 files changed, 19 insertions(+)

diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c
index 82687dbf39..c4d0e1858c 100644
--- a/src/qemu/qemu_capabilities.c
+++ b/src/qemu/qemu_capabilities.c
@@ -644,6 +644,8 @@ VIR_ENUM_IMPL(virQEMUCaps,
                "virtio-mem-pci", /* QEMU_CAPS_DEVICE_VIRTIO_MEM_PCI */
                "memory-backend-file.reserve", /* 
QEMU_CAPS_MEMORY_BACKEND_RESERVE */
                "piix4.acpi-root-pci-hotplug", /* 
QEMU_CAPS_PIIX4_ACPI_ROOT_PCI_HOTPLUG */
+              "piix4.acpi-hotplug-bridge", /* 
QEMU_CAPS_PIIX4_ACPI_HOTPLUG_BRIDGE */
+              "ich9.acpi-hotplug-bridge", /* 
QEMU_CAPS_ICH9_ACPI_HOTPLUG_BRIDGE */

The mechanics of this are all fine, as long as everyone is happy with the names.

Reviewed-by: Laine Stump <la...@redhat.com>

Reply via email to