From 48a18b3c698295e4d891f34e919615e84e20f027 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Herv=C3=A9=20Poussineau?= Date: Thu, 15 Dec 2011 22:09:51 +0100 Subject: isa: give ISABus/ISADevice to isa_create(), isa_bus_irqs() and isa_get_irq() functions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit NULL is a valid bus/device, so there is no change in behaviour. Signed-off-by: Hervé Poussineau Signed-off-by: Anthony Liguori --- hw/mips_r4k.c | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) (limited to 'hw/mips_r4k.c') diff --git a/hw/mips_r4k.c b/hw/mips_r4k.c index d0564d4449..c078078264 100644 --- a/hw/mips_r4k.c +++ b/hw/mips_r4k.c @@ -165,6 +165,7 @@ void mips_r4k_init (ram_addr_t ram_size, ResetData *reset_info; int i; qemu_irq *i8259; + ISABus *isa_bus; DriveInfo *hd[MAX_IDE_BUS * MAX_IDE_DEVS]; DriveInfo *dinfo; int be; @@ -256,36 +257,36 @@ void mips_r4k_init (ram_addr_t ram_size, cpu_mips_clock_init(env); /* The PIC is attached to the MIPS CPU INT0 pin */ - isa_bus_new(NULL, get_system_io()); - i8259 = i8259_init(env->irq[2]); - isa_bus_irqs(i8259); + isa_bus = isa_bus_new(NULL, get_system_io()); + i8259 = i8259_init(isa_bus, env->irq[2]); + isa_bus_irqs(isa_bus, i8259); - rtc_init(2000, NULL); + rtc_init(isa_bus, 2000, NULL); /* Register 64 KB of ISA IO space at 0x14000000 */ isa_mmio_init(0x14000000, 0x00010000); isa_mem_base = 0x10000000; - pit = pit_init(0x40, 0); + pit = pit_init(isa_bus, 0x40, 0); for(i = 0; i < MAX_SERIAL_PORTS; i++) { if (serial_hds[i]) { - serial_isa_init(i, serial_hds[i]); + serial_isa_init(isa_bus, i, serial_hds[i]); } } - isa_vga_init(); + isa_vga_init(isa_bus); if (nd_table[0].vlan) - isa_ne2000_init(0x300, 9, &nd_table[0]); + isa_ne2000_init(isa_bus, 0x300, 9, &nd_table[0]); ide_drive_get(hd, MAX_IDE_BUS); for(i = 0; i < MAX_IDE_BUS; i++) - isa_ide_init(ide_iobase[i], ide_iobase2[i], ide_irq[i], + isa_ide_init(isa_bus, ide_iobase[i], ide_iobase2[i], ide_irq[i], hd[MAX_IDE_DEVS * i], hd[MAX_IDE_DEVS * i + 1]); - isa_create_simple("i8042"); + isa_create_simple(isa_bus, "i8042"); } static QEMUMachine mips_machine = { -- cgit v1.2.3