aboutsummaryrefslogtreecommitdiff
path: root/hw/sparc64
diff options
context:
space:
mode:
authorMark Cave-Ayland <mark.cave-ayland@ilande.co.uk>2017-12-21 07:32:57 +0000
committerMark Cave-Ayland <mark.cave-ayland@ilande.co.uk>2018-01-09 21:31:31 +0000
commit8c40b8d9fb596cd1e9517d0176043c478bb8e7e2 (patch)
tree22b97adea8aa2ea2c236b90dea9375b0f6230dc4 /hw/sparc64
parentad6856e875ee0f60fb89c74b0410fd99c2c5e9a2 (diff)
sun4u: move ISABus inside of EBusState
Since the EBus is effectively a PCI-ISA bridge then the underlying ISA bus should be contained within the PCI bridge itself. Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> Reviewed-by: Artyom Tarasenko <atar4qemu@gmail.com> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Diffstat (limited to 'hw/sparc64')
-rw-r--r--hw/sparc64/sun4u.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/hw/sparc64/sun4u.c b/hw/sparc64/sun4u.c
index 394b7d6c59..63b4aaa6eb 100644
--- a/hw/sparc64/sun4u.c
+++ b/hw/sparc64/sun4u.c
@@ -84,6 +84,7 @@ typedef struct EbusState {
/*< private >*/
PCIDevice parent_obj;
+ ISABus *isa_bus;
MemoryRegion bar0;
MemoryRegion bar1;
} EbusState;
@@ -245,8 +246,10 @@ static void ebus_realize(PCIDevice *pci_dev, Error **errp)
{
EbusState *s = EBUS(pci_dev);
- if (!isa_bus_new(DEVICE(pci_dev), get_system_memory(),
- pci_address_space_io(pci_dev), errp)) {
+ s->isa_bus = isa_bus_new(DEVICE(pci_dev), get_system_memory(),
+ pci_address_space_io(pci_dev), errp);
+ if (!s->isa_bus) {
+ error_setg(errp, "unable to instantiate EBUS ISA bus");
return;
}