From cf965d24064671ce2d5a874e532b8189fdb6e863 Mon Sep 17 00:00:00 2001 From: balrog Date: Sun, 4 Nov 2007 12:19:22 +0000 Subject: Add register mappings in DSP space (must be accessible for MPU too). Don't set microwire CSR-busy bit too early. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3530 c046a42c-6fe2-441c-8c8c-71466251a162 --- hw/omap_i2c.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'hw/omap_i2c.c') diff --git a/hw/omap_i2c.c b/hw/omap_i2c.c index af00be3..878c046 100644 --- a/hw/omap_i2c.c +++ b/hw/omap_i2c.c @@ -194,7 +194,7 @@ void omap_i2c_reset(struct omap_i2c_s *s) static uint32_t omap_i2c_read(void *opaque, target_phys_addr_t addr) { struct omap_i2c_s *s = (struct omap_i2c_s *) opaque; - int offset = addr - s->base; + int offset = addr & OMAP_MPUI_REG_MASK; uint16_t ret; switch (offset) { @@ -286,7 +286,7 @@ static void omap_i2c_write(void *opaque, target_phys_addr_t addr, uint32_t value) { struct omap_i2c_s *s = (struct omap_i2c_s *) opaque; - int offset = addr - s->base; + int offset = addr & OMAP_MPUI_REG_MASK; int nack; switch (offset) { -- cgit v1.1