summaryrefslogtreecommitdiff
path: root/drivers/mtd
diff options
context:
space:
mode:
authorStefan Roese <sr@denx.de>2013-04-03 02:47:46 +0200
committerStefan Roese <sr@denx.de>2013-04-04 07:07:30 +0200
commit81a4f7098ba137ea1961cb997ca16d57de2b3483 (patch)
treeb5f60bcb9fb78a25131ece1cb7c894bd0f2f4858 /drivers/mtd
parentc502321c4a1bc8d859ecf19b22f9d0ce03954fd6 (diff)
downloadu-boot-imx-81a4f7098ba137ea1961cb997ca16d57de2b3483.zip
u-boot-imx-81a4f7098ba137ea1961cb997ca16d57de2b3483.tar.gz
u-boot-imx-81a4f7098ba137ea1961cb997ca16d57de2b3483.tar.bz2
cfi_flash: Use uintptr_t for casts from u32 to void *
This fixes this build warning: Configuring for qemu_mips64 - Board: qemu-mips64, Options: SYS_BIG_ENDIAN text data bss dec hex filename 215344 13082 218720 447146 6d2aa qemu_mips64/u-boot cfi_flash.c: In function 'flash_map': cfi_flash.c:217:9: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast] Signed-off-by: Stefan Roese <sr@denx.de> Cc: Tom Rini <trini@ti.com>
Diffstat (limited to 'drivers/mtd')
-rw-r--r--drivers/mtd/cfi_flash.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mtd/cfi_flash.c b/drivers/mtd/cfi_flash.c
index 328c76d..cf10b0d 100644
--- a/drivers/mtd/cfi_flash.c
+++ b/drivers/mtd/cfi_flash.c
@@ -214,7 +214,7 @@ flash_map (flash_info_t * info, flash_sect_t sect, uint offset)
unsigned int addr = (info->start[sect] + byte_offset);
unsigned int mask = 0xffffffff << (info->portwidth - 1);
- return (void *)(addr & mask);
+ return (void *)(uintptr_t)(addr & mask);
}
static inline void flash_unmap(flash_info_t *info, flash_sect_t sect,