diff options
author | Andreas Färber <afaerber@suse.de> | 2012-05-04 00:42:39 +0200 |
---|---|---|
committer | Andreas Färber <afaerber@suse.de> | 2012-06-04 23:00:41 +0200 |
commit | 5f4ef08b20ece1b3711bcfb3751efb13986d17e5 (patch) | |
tree | 18eb37664743669762b8753d928ec54b04e97be8 /hw/omap2.c | |
parent | 43824588af2fa77f9586e16ef2f01d1990c6460e (diff) |
omap: Use cpu_arm_init() to store ARMCPU in omap_mpu_state_s
Fix tab indentations of comments, add braces, use cpu_reset().
Signed-off-by: Andreas Färber <afaerber@suse.de>
Acked-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/omap2.c')
-rw-r--r-- | hw/omap2.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/hw/omap2.c b/hw/omap2.c index 42fce5e986..196c4b6cc8 100644 --- a/hw/omap2.c +++ b/hw/omap2.c @@ -2222,7 +2222,7 @@ static void omap2_mpu_reset(void *opaque) omap_mmc_reset(mpu->mmc); omap_mcspi_reset(mpu->mcspi[0]); omap_mcspi_reset(mpu->mcspi[1]); - cpu_state_reset(mpu->env); + cpu_reset(CPU(mpu->cpu)); } static int omap2_validate_addr(struct omap_mpu_state_s *s, @@ -2253,8 +2253,8 @@ struct omap_mpu_state_s *omap2420_mpu_init(MemoryRegion *sysmem, /* Core */ s->mpu_model = omap2420; - s->env = cpu_init(core ?: "arm1136-r2"); - if (!s->env) { + s->cpu = cpu_arm_init(core ?: "arm1136-r2"); + if (s->cpu == NULL) { fprintf(stderr, "Unable to find CPU definition\n"); exit(1); } @@ -2277,7 +2277,7 @@ struct omap_mpu_state_s *omap2420_mpu_init(MemoryRegion *sysmem, s->l4 = omap_l4_init(sysmem, OMAP2_L4_BASE, 54); /* Actually mapped at any 2K boundary in the ARM11 private-peripheral if */ - cpu_irq = arm_pic_init_cpu(s->env); + cpu_irq = arm_pic_init_cpu(&s->cpu->env); s->ih[0] = qdev_create(NULL, "omap2-intc"); qdev_prop_set_uint8(s->ih[0], "revision", 0x21); qdev_prop_set_ptr(s->ih[0], "fclk", omap_findclk(s, "mpu_intc_fclk")); |