diff options
author | Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com> | 2018-07-16 15:56:10 +0530 |
---|---|---|
committer | Michal Simek <michal.simek@xilinx.com> | 2018-07-19 10:49:56 +0200 |
commit | 1473b12ad0b33771ded1b2fd6b73d2cd6d73b8f7 (patch) | |
tree | 9fa0de2e820f89ffa33941b069e5eb96865b0b8c /lib/fdtdec.c | |
parent | f4da871a7f09540557792ea5da688c54790add7d (diff) | |
download | u-boot-1473b12ad0b33771ded1b2fd6b73d2cd6d73b8f7.tar.gz |
lib: fdtdec: Update ram_base to store ram start adddress
This patch updates the ram_base to store the start address of
the first bank DRAM and the use this ram_base to calculate ram_top
properly. This patch fixes the erroneous calculation of ram_top
incase of non zero ram start address.
Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'lib/fdtdec.c')
-rw-r--r-- | lib/fdtdec.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/fdtdec.c b/lib/fdtdec.c index 1b0c430945..66dff0f906 100644 --- a/lib/fdtdec.c +++ b/lib/fdtdec.c @@ -1173,6 +1173,7 @@ int fdtdec_setup_memory_size(void) } gd->ram_size = (phys_size_t)(res.end - res.start + 1); + gd->ram_base = (unsigned long)res.start; debug("%s: Initial DRAM size %llx\n", __func__, (unsigned long long)gd->ram_size); |