[U-Boot] Issue in u-boot; TFTP error: trying to overwrite reserved memory...
Bernhard Kirchen
schlimmchen at gmail.com
Thu Nov 12 16:27:17 CET 2020
Hello Christopher, hello SImon,
today I debugged this problem, as tftp was not working in my u-boot SPL
(AM335x based custom board) for the reasons described in this thread.
It turns out that lmb_init_and_reserve() could not set proper values
as bd->bi_dram[0].size = 00000000. The reason IMHO is that
dram_init_banksize() is NOT called in SPL unless CONFIG_SPL_OS_BOOT or
CONFIG_HANDOFF or CONFIG_SPL_ATF is defined (see
common/spl/spl.c:board_init_r(). As I have no use to set any of those,
dram_init_banksize() is never called in my case. Subsequently, tftp fails
when checking available memory.
By calling dram_init_banksize() from my board's am33xx_spl_board_init() I
can work around the issue.
However, I think that dram_init_banksize() should be called in
common/spl/spl.c:board_init_r() also if CONFIG_LBM is defined.
Best,
Bernhard
More information about the U-Boot
mailing list