mirror of
https://git.codelinaro.org/clo/qsdk/oss/boot/u-boot-2016.git
synced 2025-12-10 07:44:53 +01:00
sf: Fix sram size issue for 4GB DDR
In this case, the variable sram_end(Base + Size) will hold (0x40000000 + 0xC0000000) and will overflow 32bits. Update the variable type to u64. Change-Id: Iadf008c0ace552b793b9424e5c9ded0873599a64 Signed-off-by: anusha <anusharao@codeaurora.org>
This commit is contained in:
parent
c6915cd738
commit
3e6aa907bd
1 changed files with 1 additions and 1 deletions
|
|
@ -267,7 +267,7 @@ static int do_spi_flash_read_write(int argc, char * const argv[])
|
||||||
int ret = 1;
|
int ret = 1;
|
||||||
int dev = 0;
|
int dev = 0;
|
||||||
loff_t offset, len, maxsize;
|
loff_t offset, len, maxsize;
|
||||||
unsigned long sram_end = CONFIG_SYS_SDRAM_BASE + gd->ram_size;
|
u64 sram_end = CONFIG_SYS_SDRAM_BASE + (u64)gd->ram_size;
|
||||||
|
|
||||||
if (argc < 3)
|
if (argc < 3)
|
||||||
return -1;
|
return -1;
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue