diff options
author | Arnd Bergmann <arnd@arndb.de> | 2014-04-29 07:18:25 -0400 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2014-04-30 23:31:13 -0400 |
commit | 1aa91b6dd44a9517dee42913ecf9f51650b32cb6 (patch) | |
tree | c57888179dd5ab97a3c112f5fcf7fbb6ed2f20ca /sound/soc/samsung | |
parent | 01c2cb67eaa37f86196e3e6074dea096fe46511a (diff) |
ASoC: samsung-idma: avoid 64-bit division
dma_addr_t may be 64 bit wide, which causes a build failure
when doing a division on it. Here it is safe to cast to an
u32 type, which avoids the problem.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Xia Kaixu <kaixu.xia@linaro.org>
Tested-by: Tushar Behera <tushar.behera@linaro.org>
Signed-off-by: Mark Brown <broonie@linaro.org>
Diffstat (limited to 'sound/soc/samsung')
-rw-r--r-- | sound/soc/samsung/idma.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/soc/samsung/idma.c b/sound/soc/samsung/idma.c index 3d5cf1530b6f..e9891b44f0e2 100644 --- a/sound/soc/samsung/idma.c +++ b/sound/soc/samsung/idma.c | |||
@@ -274,7 +274,7 @@ static irqreturn_t iis_irq(int irqno, void *dev_id) | |||
274 | 274 | ||
275 | addr = readl(idma.regs + I2SLVL0ADDR) - idma.lp_tx_addr; | 275 | addr = readl(idma.regs + I2SLVL0ADDR) - idma.lp_tx_addr; |
276 | addr += prtd->periodsz; | 276 | addr += prtd->periodsz; |
277 | addr %= (prtd->end - prtd->start); | 277 | addr %= (u32)(prtd->end - prtd->start); |
278 | addr += idma.lp_tx_addr; | 278 | addr += idma.lp_tx_addr; |
279 | 279 | ||
280 | writel(addr, idma.regs + I2SLVL0ADDR); | 280 | writel(addr, idma.regs + I2SLVL0ADDR); |