diff mbox

[RFC,5/7] hw/acpi: prepare pci hotplug IO for ich9

Message ID 1464716918-29689-6-git-send-email-marcel@redhat.com (mailing list archive)
State New, archived
Headers show

Commit Message

Marcel Apfelbaum May 31, 2016, 5:48 p.m. UTC
Does not have any effect yet since the pcihp is not enabled for ICH9.

Signed-off-by: Marcel Apfelbaum <marcel@redhat.com>
---
 hw/i386/acpi-build.c | 12 +++++-------
 1 file changed, 5 insertions(+), 7 deletions(-)
diff mbox

Patch

diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
index 2097c4c..8ae3e53 100644
--- a/hw/i386/acpi-build.c
+++ b/hw/i386/acpi-build.c
@@ -130,13 +130,6 @@  static void acpi_get_pm_info(AcpiPmInfo *pm)
     if (piix) {
         obj = piix;
         pm->cpu_hp_io_base = PIIX4_CPU_HOTPLUG_IO_BASE;
-        pcihp_io_base =
-            object_property_get_int(obj, ACPI_PCIHP_IO_BASE_PROP, NULL);
-        pcihp_io_len =
-            object_property_get_int(obj, ACPI_PCIHP_IO_LEN_PROP, NULL);
-
-        pm->pcihp_io_base = (pcihp_io_base == -1) ? 0 : pcihp_io_base;
-        pm->pcihp_io_len = (pcihp_io_len == -1) ? 0 : pcihp_io_len;
     }
     if (lpc) {
         obj = lpc;
@@ -144,6 +137,11 @@  static void acpi_get_pm_info(AcpiPmInfo *pm)
     }
     assert(obj);
 
+    pcihp_io_base = object_property_get_int(obj, ACPI_PCIHP_IO_BASE_PROP, NULL);
+    pcihp_io_len = object_property_get_int(obj, ACPI_PCIHP_IO_LEN_PROP, NULL);
+
+    pm->pcihp_io_base = (pcihp_io_base == -1) ? 0 : pcihp_io_base;
+    pm->pcihp_io_len = (pcihp_io_len == -1) ? 0 : pcihp_io_len;
     pm->cpu_hp_io_len = ACPI_GPE_PROC_LEN;
     pm->mem_hp_io_base = ACPI_MEMORY_HOTPLUG_BASE;
     pm->mem_hp_io_len = ACPI_MEMORY_HOTPLUG_IO_LEN;