From: Georgi Vlaev Date: Tue, 14 Jun 2022 14:45:30 +0000 (+0300) Subject: arm: mach-k3: common: Use ddr_init in spl_enable_dcache X-Git-Tag: baikal/mips/sdk5.8.2~5^2~292^2~5^2~39 X-Git-Url: https://git.baikalelectronics.ru/sdk/?a=commitdiff_plain;h=39f1fb48018f616bb566c10943aefd0f622ad7c1;p=uboot.git arm: mach-k3: common: Use ddr_init in spl_enable_dcache The spl_enable_dcache() function calls dram_init_banksize() to get the total memory size. Normally the dram_init_banksize() setups the memory banks, while the total size is reported by ddr_init(). This worked so far for K3 since we set the gd->ram_size in dram_init_banksize() as well. Signed-off-by: Georgi Vlaev Reviewed-by: Tom Rini --- diff --git a/arch/arm/mach-k3/common.c b/arch/arm/mach-k3/common.c index b4b75f4e6c..70f6444e79 100644 --- a/arch/arm/mach-k3/common.c +++ b/arch/arm/mach-k3/common.c @@ -516,7 +516,7 @@ void spl_enable_dcache(void) #if !(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF)) phys_addr_t ram_top = CONFIG_SYS_SDRAM_BASE; - dram_init_banksize(); + dram_init(); /* reserve TLB table */ gd->arch.tlb_size = PGTABLE_SIZE;