diff mbox

[U-Boot] spl_nor: fix warning when compiled for 64bit target

Message ID 1456746634-31118-1-git-send-email-yamada.masahiro@socionext.com
State Accepted
Commit 70e6428d8cbaede09691f71f69c93e0f7899fe2e
Delegated to: Tom Rini
Headers show

Commit Message

Masahiro Yamada Feb. 29, 2016, 11:50 a.m. UTC
Fix "warning: cast to pointer from integer of different size".

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
---

 common/spl/spl_nor.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Tom Rini March 1, 2016, 1:59 a.m. UTC | #1
On Mon, Feb 29, 2016 at 08:50:34PM +0900, Masahiro Yamada wrote:

> Fix "warning: cast to pointer from integer of different size".
> 
> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>

Reviewed-by: Tom Rini <trini@konsulko.com>
Tom Rini March 17, 2016, 2:04 a.m. UTC | #2
On Mon, Feb 29, 2016 at 08:50:34PM +0900, Masahiro Yamada wrote:

> Fix "warning: cast to pointer from integer of different size".
> 
> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
> Reviewed-by: Tom Rini <trini@konsulko.com>

Applied to u-boot/master, thanks!
diff mbox

Patch

diff --git a/common/spl/spl_nor.c b/common/spl/spl_nor.c
index e08afe2..d0bd0b0 100644
--- a/common/spl/spl_nor.c
+++ b/common/spl/spl_nor.c
@@ -59,7 +59,7 @@  int spl_nor_load_image(void)
 	spl_parse_image_header(
 			(const struct image_header *)CONFIG_SYS_UBOOT_BASE);
 
-	memcpy((void *)spl_image.load_addr,
+	memcpy((void *)(unsigned long)spl_image.load_addr,
 	       (void *)(CONFIG_SYS_UBOOT_BASE + sizeof(struct image_header)),
 	       spl_image.size);