diff options
author | blueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162> | 2008-12-02 17:47:02 +0000 |
---|---|---|
committer | blueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162> | 2008-12-02 17:47:02 +0000 |
commit | e64d7d595f9454d29de7110e3ec6591105c8e467 (patch) | |
tree | 26eaa11fc8ea8b8817b0e6e99fabaa8af196973a /hw/sparc32_dma.c | |
parent | 0e8f096751f279a8de01d9c66c87911ec431fa4c (diff) |
Remove address masking
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5853 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'hw/sparc32_dma.c')
-rw-r--r-- | hw/sparc32_dma.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/hw/sparc32_dma.c b/hw/sparc32_dma.c index c69b559bec..e12216d60a 100644 --- a/hw/sparc32_dma.c +++ b/hw/sparc32_dma.c @@ -45,7 +45,6 @@ do { printf("DMA: " fmt , ##args); } while (0) #define DMA_REGS 4 #define DMA_SIZE (4 * sizeof(uint32_t)) -#define DMA_MAXADDR (DMA_SIZE - 1) #define DMA_VER 0xa0000000 #define DMA_INTR 1 @@ -157,7 +156,7 @@ static uint32_t dma_mem_readl(void *opaque, target_phys_addr_t addr) DMAState *s = opaque; uint32_t saddr; - saddr = (addr & DMA_MAXADDR) >> 2; + saddr = addr >> 2; DPRINTF("read dmareg " TARGET_FMT_plx ": 0x%8.8x\n", addr, s->dmaregs[saddr]); @@ -169,7 +168,7 @@ static void dma_mem_writel(void *opaque, target_phys_addr_t addr, uint32_t val) DMAState *s = opaque; uint32_t saddr; - saddr = (addr & DMA_MAXADDR) >> 2; + saddr = addr >> 2; DPRINTF("write dmareg " TARGET_FMT_plx ": 0x%8.8x -> 0x%8.8x\n", addr, s->dmaregs[saddr], val); switch (saddr) { |