linux/drivers/mmc
Arnd Bergmann d34712d2e3 mmc: sunxi: avoid invalid pointer calculation
The sunxi mmc driver tries to calculate a dma address by using pointer
arithmetic, which causes a warning when dma_addr_t is wider than a pointer:

drivers/mmc/host/sunxi-mmc.c: In function 'sunxi_mmc_init_idma_des':
drivers/mmc/host/sunxi-mmc.c:296:35: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
  struct sunxi_idma_des *pdes_pa = (struct sunxi_idma_des *)host->sg_dma;
                                   ^

To avoid this warning and to simplify the logic, this changes
the code to avoid the cast and calculate the correct address
manually. The behavior should be unchanged.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: David Lanzendörfer <david.lanzendoerfer@o2s.ch>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
2015-03-23 14:13:42 +01:00
..
card mmc: block: Remove unnecessary temporary variable 2015-01-28 12:32:17 +01:00
core mmc: pwrseq_simple: fix error path in mmc_pwrseq_simple_alloc 2015-03-19 11:26:35 +01:00
host mmc: sunxi: avoid invalid pointer calculation 2015-03-23 14:13:42 +01:00
Kconfig
Makefile mmc: sdhci-pci: add platform data 2012-01-11 23:58:47 -05:00