From: Valentin Longchamp Date: Fri, 3 Oct 2014 09:16:19 +0000 (+0200) Subject: common/board_r: remove warning in initr_mem for 64-bit phys_size_t X-Git-Url: http://git.dujemihanovic.xyz/?a=commitdiff_plain;h=ae1a74ebe7b4627205703f19e60c1c2c2fa06c73;p=u-boot.git common/board_r: remove warning in initr_mem for 64-bit phys_size_t Since on powerpc phys_size_t can be unsigned long long, this printout line can result in a not nice compile warning. Signed-off-by: Valentin Longchamp Acked-by: Simon Glass --- diff --git a/common/board_r.c b/common/board_r.c index c339aad7f5..7e1a76d97f 100644 --- a/common/board_r.c +++ b/common/board_r.c @@ -664,7 +664,7 @@ int initr_mem(void) /* Also take the logbuffer into account (pram is in kB) */ pram += (LOGBUFF_LEN + LOGBUFF_OVERHEAD) / 1024; # endif - sprintf(memsz, "%ldk", (gd->ram_size / 1024) - pram); + sprintf(memsz, "%ldk", (long int) ((gd->ram_size / 1024) - pram)); setenv("mem", memsz); return 0;