diff options
Diffstat (limited to 'hw/arm/omap1.c')
-rw-r--r-- | hw/arm/omap1.c | 65 |
1 files changed, 44 insertions, 21 deletions
diff --git a/hw/arm/omap1.c b/hw/arm/omap1.c index abb183c2d5..061504495d 100644 --- a/hw/arm/omap1.c +++ b/hw/arm/omap1.c @@ -207,7 +207,8 @@ static void omap_mpu_timer_write(void *opaque, hwaddr addr, struct omap_mpu_timer_s *s = (struct omap_mpu_timer_s *) opaque; if (size != 4) { - return omap_badwidth_write32(opaque, addr, value); + omap_badwidth_write32(opaque, addr, value); + return; } switch (addr) { @@ -314,7 +315,8 @@ static void omap_wd_timer_write(void *opaque, hwaddr addr, struct omap_watchdog_timer_s *s = (struct omap_watchdog_timer_s *) opaque; if (size != 2) { - return omap_badwidth_write16(opaque, addr, value); + omap_badwidth_write16(opaque, addr, value); + return; } switch (addr) { @@ -440,7 +442,8 @@ static void omap_os_timer_write(void *opaque, hwaddr addr, int offset = addr & OMAP_MPUI_REG_MASK; if (size != 4) { - return omap_badwidth_write32(opaque, addr, value); + omap_badwidth_write32(opaque, addr, value); + return; } switch (offset) { @@ -585,7 +588,8 @@ static void omap_ulpd_pm_write(void *opaque, hwaddr addr, uint16_t diff; if (size != 2) { - return omap_badwidth_write16(opaque, addr, value); + omap_badwidth_write16(opaque, addr, value); + return; } switch (addr) { @@ -857,7 +861,8 @@ static void omap_pin_cfg_write(void *opaque, hwaddr addr, uint32_t diff; if (size != 4) { - return omap_badwidth_write32(opaque, addr, value); + omap_badwidth_write32(opaque, addr, value); + return; } switch (addr) { @@ -1012,7 +1017,8 @@ static void omap_id_write(void *opaque, hwaddr addr, uint64_t value, unsigned size) { if (size != 4) { - return omap_badwidth_write32(opaque, addr, value); + omap_badwidth_write32(opaque, addr, value); + return; } OMAP_BAD_REG(addr); @@ -1081,7 +1087,8 @@ static void omap_mpui_write(void *opaque, hwaddr addr, struct omap_mpu_state_s *s = (struct omap_mpu_state_s *) opaque; if (size != 4) { - return omap_badwidth_write32(opaque, addr, value); + omap_badwidth_write32(opaque, addr, value); + return; } switch (addr) { @@ -1175,7 +1182,8 @@ static void omap_tipb_bridge_write(void *opaque, hwaddr addr, struct omap_tipb_bridge_s *s = (struct omap_tipb_bridge_s *) opaque; if (size < 2) { - return omap_badwidth_write16(opaque, addr, value); + omap_badwidth_write16(opaque, addr, value); + return; } switch (addr) { @@ -1284,7 +1292,8 @@ static void omap_tcmi_write(void *opaque, hwaddr addr, struct omap_mpu_state_s *s = (struct omap_mpu_state_s *) opaque; if (size != 4) { - return omap_badwidth_write32(opaque, addr, value); + omap_badwidth_write32(opaque, addr, value); + return; } switch (addr) { @@ -1379,7 +1388,8 @@ static void omap_dpll_write(void *opaque, hwaddr addr, int div, mult; if (size != 2) { - return omap_badwidth_write16(opaque, addr, value); + omap_badwidth_write16(opaque, addr, value); + return; } if (addr == 0x00) { /* CTL_REG */ @@ -1647,7 +1657,8 @@ static void omap_clkm_write(void *opaque, hwaddr addr, }; if (size != 2) { - return omap_badwidth_write16(opaque, addr, value); + omap_badwidth_write16(opaque, addr, value); + return; } switch (addr) { @@ -1775,7 +1786,8 @@ static void omap_clkdsp_write(void *opaque, hwaddr addr, uint16_t diff; if (size != 2) { - return omap_badwidth_write16(opaque, addr, value); + omap_badwidth_write16(opaque, addr, value); + return; } switch (addr) { @@ -1982,7 +1994,8 @@ static void omap_mpuio_write(void *opaque, hwaddr addr, int ln; if (size != 2) { - return omap_badwidth_write16(opaque, addr, value); + omap_badwidth_write16(opaque, addr, value); + return; } switch (offset) { @@ -2210,7 +2223,8 @@ static void omap_uwire_write(void *opaque, hwaddr addr, int offset = addr & OMAP_MPUI_REG_MASK; if (size != 2) { - return omap_badwidth_write16(opaque, addr, value); + omap_badwidth_write16(opaque, addr, value); + return; } switch (offset) { @@ -2349,7 +2363,8 @@ static void omap_pwl_write(void *opaque, hwaddr addr, int offset = addr & OMAP_MPUI_REG_MASK; if (size != 1) { - return omap_badwidth_write8(opaque, addr, value); + omap_badwidth_write8(opaque, addr, value); + return; } switch (offset) { @@ -2444,7 +2459,8 @@ static void omap_pwt_write(void *opaque, hwaddr addr, int offset = addr & OMAP_MPUI_REG_MASK; if (size != 1) { - return omap_badwidth_write8(opaque, addr, value); + omap_badwidth_write8(opaque, addr, value); + return; } switch (offset) { @@ -2637,7 +2653,8 @@ static void omap_rtc_write(void *opaque, hwaddr addr, time_t ti[2]; if (size != 1) { - return omap_badwidth_write8(opaque, addr, value); + omap_badwidth_write8(opaque, addr, value); + return; } switch (offset) { @@ -3410,9 +3427,14 @@ static void omap_mcbsp_write(void *opaque, hwaddr addr, uint64_t value, unsigned size) { switch (size) { - case 2: return omap_mcbsp_writeh(opaque, addr, value); - case 4: return omap_mcbsp_writew(opaque, addr, value); - default: return omap_badwidth_write16(opaque, addr, value); + case 2: + omap_mcbsp_writeh(opaque, addr, value); + break; + case 4: + omap_mcbsp_writew(opaque, addr, value); + break; + default: + omap_badwidth_write16(opaque, addr, value); } } @@ -3586,7 +3608,8 @@ static void omap_lpg_write(void *opaque, hwaddr addr, int offset = addr & OMAP_MPUI_REG_MASK; if (size != 1) { - return omap_badwidth_write8(opaque, addr, value); + omap_badwidth_write8(opaque, addr, value); + return; } switch (offset) { |