diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2011-11-07 13:25:45 +0000 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2011-11-14 11:26:32 -0600 |
commit | e1556ad5b8143a15c26067c3862fe20631c0053f (patch) | |
tree | d4d116b8a6b4db2042b4ca029b8b016385f1ef23 | |
parent | 371572dff4d4dae128a03b30d623b7d212238a70 (diff) |
hw/omap_gpio: Fix infinite recursion when doing 8/16 bit reads
Fix a long-standing bug which meant that any attempt to do an
8 or 16 bit read from the OMAP GPIO module would cause qemu to
crash due to an infinite recursion.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
-rw-r--r-- | hw/omap_gpio.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/omap_gpio.c b/hw/omap_gpio.c index 42e59c3a53..30630a8aa9 100644 --- a/hw/omap_gpio.c +++ b/hw/omap_gpio.c @@ -510,7 +510,7 @@ static void omap2_gpio_module_write(void *opaque, target_phys_addr_t addr, static uint32_t omap2_gpio_module_readp(void *opaque, target_phys_addr_t addr) { - return omap2_gpio_module_readp(opaque, addr) >> ((addr & 3) << 3); + return omap2_gpio_module_read(opaque, addr & ~3) >> ((addr & 3) << 3); } static void omap2_gpio_module_writep(void *opaque, target_phys_addr_t addr, |