diff options
Diffstat (limited to 'hw/mips_mipssim.c')
-rw-r--r-- | hw/mips_mipssim.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/hw/mips_mipssim.c b/hw/mips_mipssim.c index 0d46cc4c5a..ac65555b74 100644 --- a/hw/mips_mipssim.c +++ b/hw/mips_mipssim.c @@ -35,6 +35,8 @@ #include "mips-bios.h" #include "loader.h" #include "elf.h" +#include "sysbus.h" +#include "exec-memory.h" static struct _loaderparams { int ram_size; @@ -112,6 +114,22 @@ static void main_cpu_reset(void *opaque) } } +static void mipsnet_init(int base, qemu_irq irq, NICInfo *nd) +{ + DeviceState *dev; + SysBusDevice *s; + + dev = qdev_create(NULL, "mipsnet"); + qdev_set_nic_properties(dev, nd); + qdev_init_nofail(dev); + + s = sysbus_from_qdev(dev); + sysbus_connect_irq(s, 0, irq); + memory_region_add_subregion(get_system_io(), + base, + sysbus_mmio_get_region(s, 0)); +} + static void mips_mipssim_init (ram_addr_t ram_size, const char *boot_device, |