diff options
author | Bernhard Beschow | 2022-10-22 17:04:31 +0200 |
---|---|---|
committer | Philippe Mathieu-Daudé | 2022-10-31 11:32:07 +0100 |
commit | 57654b8e98785f2188b64dd45489dc29b426663c (patch) | |
tree | 3f999f80e888d1696a03c50cd62a9cec988644ab /hw/isa | |
parent | hw/isa/piix3: Modernize reset handling (diff) | |
download | qemu-57654b8e98785f2188b64dd45489dc29b426663c.tar.gz qemu-57654b8e98785f2188b64dd45489dc29b426663c.tar.xz qemu-57654b8e98785f2188b64dd45489dc29b426663c.zip |
hw/isa/piix3: Prefer pci_address_space() over get_system_memory()
get_system_memory() accesses global state while pci_address_space() uses
whatever has been passed to the device instance, so avoid the global.
Moreover, PIIX4 uses pci_address_space() here as well.
Signed-off-by: Bernhard Beschow <shentey@gmail.com>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-Id: <20221022150508.26830-7-shentey@gmail.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Diffstat (limited to 'hw/isa')
-rw-r--r-- | hw/isa/piix3.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/isa/piix3.c b/hw/isa/piix3.c index 723ad0a896..0bea4aefe7 100644 --- a/hw/isa/piix3.c +++ b/hw/isa/piix3.c @@ -301,7 +301,7 @@ static void pci_piix3_realize(PCIDevice *dev, Error **errp) PIIX3State *d = PIIX3_PCI_DEVICE(dev); ISABus *isa_bus; - isa_bus = isa_bus_new(DEVICE(d), get_system_memory(), + isa_bus = isa_bus_new(DEVICE(d), pci_address_space(dev), pci_address_space_io(dev), errp); if (!isa_bus) { return; |