[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 1/8] sun4u: pass PCIDevice into pci_ebus_init() inst
From: |
Mark Cave-Ayland |
Subject: |
[Qemu-devel] [PATCH 1/8] sun4u: pass PCIDevice into pci_ebus_init() instead of PCIBus |
Date: |
Tue, 11 Jul 2017 22:53:20 +0100 |
In order to wire up the ebus PCI address spaces differently then we need
access to the underlying PCIDevice.
Signed-off-by: Mark Cave-Ayland <address@hidden>
---
hw/sparc64/sun4u.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/hw/sparc64/sun4u.c b/hw/sparc64/sun4u.c
index 69f565d..7738856 100644
--- a/hw/sparc64/sun4u.c
+++ b/hw/sparc64/sun4u.c
@@ -224,13 +224,11 @@ static void isa_irq_handler(void *opaque, int n, int
level)
/* EBUS (Eight bit bus) bridge */
static ISABus *
-pci_ebus_init(PCIBus *bus, int devfn, qemu_irq *irqs)
+pci_ebus_init(PCIDevice *pci_dev, qemu_irq *irqs)
{
qemu_irq *isa_irq;
- PCIDevice *pci_dev;
ISABus *isa_bus;
- pci_dev = pci_create_simple(bus, devfn, "ebus");
isa_bus = ISA_BUS(qdev_get_child_bus(DEVICE(pci_dev), "isa.0"));
isa_irq = qemu_allocate_irqs(isa_irq_handler, irqs, 16);
isa_bus_irqs(isa_bus, isa_irq);
@@ -429,6 +427,7 @@ static void sun4uv_init(MemoryRegion *address_space_mem,
unsigned int i;
uint64_t initrd_addr, initrd_size, kernel_addr, kernel_size, kernel_entry;
PCIBus *pci_bus, *pci_bus2, *pci_bus3;
+ PCIDevice *ebus;
ISABus *isa_bus;
SysBusDevice *s;
qemu_irq *ivec_irqs, *pbm_irqs;
@@ -452,7 +451,8 @@ static void sun4uv_init(MemoryRegion *address_space_mem,
pci_vga_init(pci_bus);
// XXX Should be pci_bus3
- isa_bus = pci_ebus_init(pci_bus, -1, pbm_irqs);
+ ebus = pci_create_simple(pci_bus, -1, "ebus");
+ isa_bus = pci_ebus_init(ebus, pbm_irqs);
i = 0;
if (hwdef->console_serial_base) {
--
1.7.10.4
- [Qemu-devel] [PATCH 2/8] sun4u: switch to using qdev to instantiate fw_cfg interface, (continued)
- [Qemu-devel] [PATCH 2/8] sun4u: switch to using qdev to instantiate fw_cfg interface, Mark Cave-Ayland, 2017/07/11
- [Qemu-devel] [PATCH 4/8] apb: fix up PCI bus nomenclature, Mark Cave-Ayland, 2017/07/11
- [Qemu-devel] [PATCH 3/8] sun4u: expose fw_cfg and NVRAM on ebus PCI IO address space, Mark Cave-Ayland, 2017/07/11
- [Qemu-devel] [PATCH 7/8] sun4u: create single default onboard ne2k_pci NIC for machine, Mark Cave-Ayland, 2017/07/11
- [Qemu-devel] [PATCH 6/8] apb: add busA qdev property to PBM PCI bridge, Mark Cave-Ayland, 2017/07/11
- [Qemu-devel] [PATCH 8/8] sun4u: move in-built devices behind PCI bridge A, Mark Cave-Ayland, 2017/07/11
- [Qemu-devel] [PATCH 1/8] sun4u: pass PCIDevice into pci_ebus_init() instead of PCIBus,
Mark Cave-Ayland <=
- [Qemu-devel] [PATCH 5/8] apb: fix endianness for APB and PCI config accesses, Mark Cave-Ayland, 2017/07/11
- Re: [Qemu-devel] [PATCH 0/8] sun4u: change PCI topology to better match a real Ultra 5, no-reply, 2017/07/11