diff options
| author | Jonas Karlman <[email protected]> | 2026-06-27 20:24:09 +0000 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2026-06-30 13:38:12 -0600 |
| commit | 5602e89a834ccbedc686053b14206c062a144107 (patch) | |
| tree | 2d4ab4cc373e40b4af1711d3ce81b3dc8fcd3b39 /tools/bddb/new.php | |
| parent | 5a49a1dd557d8590741db0155a4b64c23e8d620c (diff) | |
rockchip: sdram: Fix initialization of DRAM banksnext
The commit 55a342176984 ("common: Add an option to relocate on ram top")
changed so that dram_init_banksize() is called before gd->ram_top has
been initialized. This change broke Rockchip DRAM banks configuration
due to gd->ram_top now being 0 when dram_init_banksize() is called.
This makes first DRAM bank size calculation overflow and end up with
DRAM bank = 0x0000000000000000
-> start = 0x0000000000200000
-> size = 0xffffffffffe00000
instead of the expected (for 2 GiB)
DRAM bank = 0x0000000000000000
-> start = 0x0000000000200000
-> size = 0x000000007fe00000
or (for 4 GiB)
DRAM bank = 0x0000000000000000
-> start = 0x0000000000200000
-> size = 0x00000000f7e00000
on e.g. RK3399 boards.
Change to not depend on gd->ram_top having to be pre-calculated before
dram_init_banksize() is called, also move the related method
board_get_usable_ram_top() closer to more easily get an overview of
their interdependence, to restore working DRAM bank initialization.
Fixes: 55a342176984 ("common: Add an option to relocate on ram top")
Signed-off-by: Jonas Karlman <[email protected]>
Reported-by: Ilias Apalodimas <[email protected]>
Acked-by: Ilias Apalodimas <[email protected]>
Tested-by: Ilias Apalodimas <[email protected]> # on Radxa ROCK
Diffstat (limited to 'tools/bddb/new.php')
0 files changed, 0 insertions, 0 deletions
