diff options
author | Andreas Färber <afaerber@suse.de> | 2013-01-18 14:10:34 +0100 |
---|---|---|
committer | Andreas Färber <afaerber@suse.de> | 2013-02-16 14:50:59 +0100 |
commit | 4025cfd5d7175203008343a375f9287c77cd383c (patch) | |
tree | 812788cf080e81b35b976324d2bf71afd14ed8bc /hw/mcf5206.c | |
parent | c7937d9f9a99d8cc2848e85f608d89c6f326daf0 (diff) |
mcf5206: Pass M68kCPU to mcf5206_init()
Store it in m5206_mbar_state. Prepares for passing M68kCPU to
m68k_set_irq_level().
Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'hw/mcf5206.c')
-rw-r--r-- | hw/mcf5206.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/hw/mcf5206.c b/hw/mcf5206.c index d8c0059ed6..9bb393e3d4 100644 --- a/hw/mcf5206.c +++ b/hw/mcf5206.c @@ -145,7 +145,7 @@ static m5206_timer_state *m5206_timer_init(qemu_irq irq) /* System Integration Module. */ typedef struct { - CPUM68KState *env; + M68kCPU *cpu; MemoryRegion iomem; m5206_timer_state *timer[2]; void *uart[2]; @@ -226,7 +226,7 @@ static void m5206_mbar_update(m5206_mbar_state *s) level = 0; vector = 0; } - m68k_set_irq_level(s->env, level, vector); + m68k_set_irq_level(&s->cpu->env, level, vector); } static void m5206_mbar_set_irq(void *opaque, int irq, int level) @@ -525,7 +525,7 @@ static const MemoryRegionOps m5206_mbar_ops = { .endianness = DEVICE_NATIVE_ENDIAN, }; -qemu_irq *mcf5206_init(MemoryRegion *sysmem, uint32_t base, CPUM68KState *env) +qemu_irq *mcf5206_init(MemoryRegion *sysmem, uint32_t base, M68kCPU *cpu) { m5206_mbar_state *s; qemu_irq *pic; @@ -541,7 +541,7 @@ qemu_irq *mcf5206_init(MemoryRegion *sysmem, uint32_t base, CPUM68KState *env) s->timer[1] = m5206_timer_init(pic[10]); s->uart[0] = mcf_uart_init(pic[12], serial_hds[0]); s->uart[1] = mcf_uart_init(pic[13], serial_hds[1]); - s->env = env; + s->cpu = cpu; m5206_mbar_reset(s); return pic; |