[PATCH 01/10] board: ti: am62x: Init DRAM size in R5/A53 SPL

Nishanth Menon nm at ti.com
Fri Jan 12 13:40:01 CET 2024


On 18:01-20240112, Siddharth Vadapalli wrote:
> Hello Nishanth,
> 
> On 12/01/24 17:56, Nishanth Menon wrote:
> > On 12:17-20240112, Siddharth Vadapalli wrote:
> >> From: Kishon Vijay Abraham I <kishon at ti.com>
> >>
> >> Call dram_init_banksize() from spl_board_init() otherwise TFTP download
> >> fails with error "TFTP error: trying to overwrite reserved memory..."
> >> due to lmb_get_free_size() not able to find unreserved region due
> >> to lack of DRAM size info. Required to support Ethernet boot on AM62x.
> >>
> >> Signed-off-by: Kishon Vijay Abraham I <kishon at ti.com>
> >> Signed-off-by: Siddharth Vadapalli <s-vadapalli at ti.com>
> >> ---
> >>  board/ti/am62x/evm.c | 3 +++
> >>  1 file changed, 3 insertions(+)
> >>
> >> diff --git a/board/ti/am62x/evm.c b/board/ti/am62x/evm.c
> >> index ad93908840..35f291d83a 100644
> >> --- a/board/ti/am62x/evm.c
> >> +++ b/board/ti/am62x/evm.c
> >> @@ -85,6 +85,9 @@ void spl_board_init(void)
> >>  	if (IS_ENABLED(CONFIG_SPL_SPLASH_SCREEN) && IS_ENABLED(CONFIG_SPL_BMP))
> >>  		splash_display();
> >>  
> >> +	if (IS_ENABLED(CONFIG_SPL_ETH))
> >> +		/* Init DRAM size for R5/A53 SPL */
> >> +		dram_init_banksize();
> >>  }
> >>  
> >>  #if defined(CONFIG_K3_AM64_DDRSS)
> >> -- 
> >> 2.34.1
> >>
> > 
> > Are you sure? tftp seems to work without this patch.
> > 
> > https://gist.github.com/nmenon/91e3282e00e38ae42e8cf640be2ab888
> 
> I noticed the error pointed out in the commit message at the A53 SPL stage when
> the U-Boot Image is being fetched over TFTP without this patch, so I have
> verified that this patch is necessary. The logs you have shared verify TFTP at
> U-Boot, but this patch is for enabling TFTP at A53 SPL for fetching U-Boot image
> via TFTP.

Please fix the commit message.

I still dont get why we have to explicitly  have to call
dram_init_banksize is that because some sort of configuration option was
missed?

-- 
Regards,
Nishanth Menon
Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3  1A34 DDB5 849D 1736 249D


More information about the U-Boot mailing list