hw/isa/vt82c686: Prefer pci_address_space() over get_system_memory()

Unlike get_system_memory(), pci_address_space() respects the memory tree
available to the parent device.

Signed-off-by: Bernhard Beschow <shentey@gmail.com>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-Id: <20220901114127.53914-4-shentey@gmail.com>
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
This commit is contained in:
Bernhard Beschow 2022-09-01 13:41:17 +02:00 committed by Philippe Mathieu-Daudé
parent 91ba92d1a3
commit dd28cc87aa

View File

@ -589,7 +589,7 @@ static void via_isa_realize(PCIDevice *d, Error **errp)
qdev_init_gpio_out(dev, &s->cpu_intr, 1); qdev_init_gpio_out(dev, &s->cpu_intr, 1);
isa_irq = qemu_allocate_irqs(via_isa_request_i8259_irq, s, 1); isa_irq = qemu_allocate_irqs(via_isa_request_i8259_irq, s, 1);
isa_bus = isa_bus_new(dev, get_system_memory(), pci_address_space_io(d), isa_bus = isa_bus_new(dev, pci_address_space(d), pci_address_space_io(d),
&error_fatal); &error_fatal);
s->isa_irqs = i8259_init(isa_bus, *isa_irq); s->isa_irqs = i8259_init(isa_bus, *isa_irq);
isa_bus_irqs(isa_bus, s->isa_irqs); isa_bus_irqs(isa_bus, s->isa_irqs);