diff options
author | Hervé Poussineau <hpoussin@reactos.org> | 2015-06-03 22:45:45 +0200 |
---|---|---|
committer | Leon Alrae <leon.alrae@imgtec.com> | 2015-06-11 10:13:30 +0100 |
commit | 104655a5c818ea8de1329cef50d1cc8defc524f3 (patch) | |
tree | 70b28e86a5eca3382cf88fab8274ed847babbfe1 /hw/mips/mips_jazz.c | |
parent | 3df5de64f06f6b288b1cf30ce2bad7878a96454b (diff) | |
download | qemu-104655a5c818ea8de1329cef50d1cc8defc524f3.zip qemu-104655a5c818ea8de1329cef50d1cc8defc524f3.tar.gz qemu-104655a5c818ea8de1329cef50d1cc8defc524f3.tar.bz2 |
net/dp8393x: QOM'ify
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
Signed-off-by: Hervé Poussineau <hpoussin@reactos.org>
Reviewed-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Leon Alrae <leon.alrae@imgtec.com>
Diffstat (limited to 'hw/mips/mips_jazz.c')
-rw-r--r-- | hw/mips/mips_jazz.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/hw/mips/mips_jazz.c b/hw/mips/mips_jazz.c index 29a13c0..648654e 100644 --- a/hw/mips/mips_jazz.c +++ b/hw/mips/mips_jazz.c @@ -273,8 +273,16 @@ static void mips_jazz_init(MachineState *machine, if (!nd->model) nd->model = g_strdup("dp83932"); if (strcmp(nd->model, "dp83932") == 0) { - dp83932_init(nd, 0x80001000, 2, get_system_memory(), - qdev_get_gpio_in(rc4030, 4), rc4030_dma_mr); + qemu_check_nic_model(nd, "dp83932"); + + dev = qdev_create(NULL, "dp8393x"); + qdev_set_nic_properties(dev, nd); + qdev_prop_set_uint8(dev, "it_shift", 2); + qdev_prop_set_ptr(dev, "dma_mr", rc4030_dma_mr); + qdev_init_nofail(dev); + sysbus = SYS_BUS_DEVICE(dev); + sysbus_mmio_map(sysbus, 0, 0x80001000); + sysbus_connect_irq(sysbus, 0, qdev_get_gpio_in(rc4030, 4)); break; } else if (is_help_option(nd->model)) { fprintf(stderr, "qemu: Supported NICs: dp83932\n"); |