diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2015-03-02 13:20:43 +0000 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2015-03-02 13:20:43 +0000 |
commit | 5de090464f1ec5360c4f30faa01d8a9f8826cd58 (patch) | |
tree | 6ab14c4d57029b50bf6ec08b4b881bfad0625217 /hw/mips | |
parent | 2dffe5516e74215fadf2e0f5ee401db4d5a86f7a (diff) | |
parent | 4bc6a3e54e06c47b8e23bfa3d873fa2f42dfec02 (diff) | |
download | qemu-5de090464f1ec5360c4f30faa01d8a9f8826cd58.zip |
Merge remote-tracking branch 'remotes/afaerber/tags/qom-devices-for-peter' into staging
QOM infrastructure fixes and device conversions
* Assertion fix for device_add with non-device types
* Documentation fix
* qdev_init() error reporting cleanups
# gpg: Signature made Tue Feb 24 13:56:33 2015 GMT using RSA key ID 3E7E013F
# gpg: Good signature from "Andreas Färber <afaerber@suse.de>"
# gpg: aka "Andreas Färber <afaerber@suse.com>"
* remotes/afaerber/tags/qom-devices-for-peter:
parallel: parallel_hds_isa_init() shouldn't fail
parallel: Factor out common parallel_hds_isa_init()
serial: serial_hds_isa_init() shouldn't fail
serial: Factor out common serial_hds_isa_init()
etsec: Replace qdev_init() by qdev_init_nofail()
leon3: Replace unchecked qdev_init() by qdev_init_nofail()
ide/isa: Replace unchecked qdev_init() by qdev_init_nofail()
qdev: Improve qdev_init_nofail()'s error reporting
qom: Fix typo, 'my_class_init' -> 'derived_class_init'
qdev: Avoid type assertion in qdev_build_hotpluggable_device_list()
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/mips')
-rw-r--r-- | hw/mips/mips_fulong2e.c | 12 | ||||
-rw-r--r-- | hw/mips/mips_malta.c | 7 | ||||
-rw-r--r-- | hw/mips/mips_r4k.c | 6 |
3 files changed, 6 insertions, 19 deletions
diff --git a/hw/mips/mips_fulong2e.c b/hw/mips/mips_fulong2e.c index 6a9ebfa911..ea73585a92 100644 --- a/hw/mips/mips_fulong2e.c +++ b/hw/mips/mips_fulong2e.c @@ -277,7 +277,6 @@ static void mips_fulong2e_init(MachineState *machine) PCIBus *pci_bus; ISABus *isa_bus; I2CBus *smbus; - int i; DriveInfo *hd[MAX_IDE_BUS * MAX_IDE_DEVS]; MIPSCPU *cpu; CPUMIPSState *env; @@ -384,15 +383,8 @@ static void mips_fulong2e_init(MachineState *machine) rtc_init(isa_bus, 2000, NULL); - for(i = 0; i < MAX_SERIAL_PORTS; i++) { - if (serial_hds[i]) { - serial_isa_init(isa_bus, i, serial_hds[i]); - } - } - - if (parallel_hds[0]) { - parallel_init(isa_bus, 0, parallel_hds[0]); - } + serial_hds_isa_init(isa_bus, MAX_SERIAL_PORTS); + parallel_hds_isa_init(isa_bus, 1); /* Sound card */ audio_init(pci_bus); diff --git a/hw/mips/mips_malta.c b/hw/mips/mips_malta.c index 5845158a74..533b2e60fe 100644 --- a/hw/mips/mips_malta.c +++ b/hw/mips/mips_malta.c @@ -1172,10 +1172,9 @@ void mips_malta_init(MachineState *machine) isa_create_simple(isa_bus, "i8042"); rtc_init(isa_bus, 2000, NULL); - serial_isa_init(isa_bus, 0, serial_hds[0]); - serial_isa_init(isa_bus, 1, serial_hds[1]); - if (parallel_hds[0]) - parallel_init(isa_bus, 0, parallel_hds[0]); + serial_hds_isa_init(isa_bus, 2); + parallel_hds_isa_init(isa_bus, 1); + for(i = 0; i < MAX_FD; i++) { fd[i] = drive_get(IF_FLOPPY, 0, i); } diff --git a/hw/mips/mips_r4k.c b/hw/mips/mips_r4k.c index 3e90e273dc..52564be692 100644 --- a/hw/mips/mips_r4k.c +++ b/hw/mips/mips_r4k.c @@ -284,11 +284,7 @@ void mips_r4k_init(MachineState *machine) pit = pit_init(isa_bus, 0x40, 0, NULL); - for(i = 0; i < MAX_SERIAL_PORTS; i++) { - if (serial_hds[i]) { - serial_isa_init(isa_bus, i, serial_hds[i]); - } - } + serial_hds_isa_init(isa_bus, MAX_SERIAL_PORTS); isa_vga_init(isa_bus); |