summaryrefslogtreecommitdiffstats
path: root/hw/acpi/piix4.c
diff options
context:
space:
mode:
authorIgor Mammedov2014-02-03 11:44:59 +0100
committerMichael S. Tsirkin2014-02-05 15:55:49 +0100
commit99d09dd32820f5702031e3c08c81f8c209dc2220 (patch)
treefdc0505a6f922b9cf8a614ad552eadc05a1f2080 /hw/acpi/piix4.c
parentpcihp: make PCI hotplug mmio handlers indifferent to PCI_HOTPLUG_ADDR (diff)
downloadqemu-99d09dd32820f5702031e3c08c81f8c209dc2220.tar.gz
qemu-99d09dd32820f5702031e3c08c81f8c209dc2220.tar.xz
qemu-99d09dd32820f5702031e3c08c81f8c209dc2220.zip
pcihp: make pci_read() mmio calback compatible with legacy ACPI hotplug
due to recent change introduced by: "pcihp: reduce number of device check events" 'up' field is cleared right after it's read. This is incompatible with legacy BIOS ACPI code where PCNF ACPI method reads this field 32 times. To make pci_read mmio callback compatible with legacy 'up' behavior, pcihp code will need to know in which mode it runs add 'legacy_piix' field to AcpiPciHpState structure and alter register behavior accordingly. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw/acpi/piix4.c')
-rw-r--r--hw/acpi/piix4.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/hw/acpi/piix4.c b/hw/acpi/piix4.c
index 5d55a3c222..2aedfe5998 100644
--- a/hw/acpi/piix4.c
+++ b/hw/acpi/piix4.c
@@ -695,7 +695,8 @@ static void piix4_acpi_system_hot_add_init(MemoryRegion *parent,
memory_region_add_subregion(parent, GPE_BASE, &s->io_gpe);
if (s->use_acpi_pci_hotplug) {
- acpi_pcihp_init(&s->acpi_pci_hotplug, bus, parent);
+ acpi_pcihp_init(&s->acpi_pci_hotplug, bus, parent,
+ s->use_acpi_pci_hotplug);
} else {
memory_region_init_io(&s->io_pci, OBJECT(s), &piix4_pci_ops, s,
"acpi-pci-hotplug", PCI_HOTPLUG_SIZE);