From bded9847d790e1cf300eac899f68185c2b01d3be Mon Sep 17 00:00:00 2001 From: Siva Durga Prasad Paladugu Date: Thu, 8 Jun 2017 11:33:35 +0530 Subject: [PATCH] lib: fdtdec: Fill initial ram top with DDR start value from dt Fill initial ram top with DDR base addr value from DT as not filling it here always assumes it as zero while calculating relocation offset and hence lead to failures in somecases. This will assumed as zero if CONFIG_SYS_SDRAM_BASE is not defined. Signed-off-by: Siva Durga Prasad Paladugu Signed-off-by: Michal Simek --- lib/fdtdec.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/fdtdec.c b/lib/fdtdec.c index 81f47ef2c7f..7bef63d6998 100644 --- a/lib/fdtdec.c +++ b/lib/fdtdec.c @@ -1192,6 +1192,7 @@ int fdtdec_setup_memory_size(void) } gd->ram_size = (phys_size_t)(res.end - res.start + 1); + gd->ram_top = (unsigned long)res.start; debug("%s: Initial DRAM size %llx\n", __func__, (u64)gd->ram_size); return 0; -- 2.47.3