
On 2/7/23 19:27, Jonas Karlman wrote:
DRAM initialization blobs for rk356x and rk3588 from vendor encode sdram info in a new version 3 format. The new format makes use of more bits in sys_reg3 compared to the version 2 format. RK3588 blob also encode information on sdram channel 3+4 in sys_reg4+5 using the same format.
This series adds support for decoding basic information from this new version 3 format. It also adds support for adding a second dram bank with any usable memory beyond the 4GB mark.
With these patches my Radxa ROCK 3 Model A 2GB correctly report 2GB of DRAM, instead of 4GB, and my 8GB board can make full use of its memory. My Radxa ROCK 5 Model B 8GB also correctly report and can make full use of its 8GB of DRAM with these patches.
Changes in v2:
- Change CONFIG_SYS_SDRAM_BASE to CFG_SYS_SDRAM_BASE
- Added a note on RK3588 blobs use of sys_reg4+5 to cover letter
Jonas Karlman (2): rockchip: sdram: add basic support for sdram reg info version 3 rockchip: sdram: add dram bank with usable memory beyond 4GB
arch/arm/include/asm/arch-rockchip/sdram.h | 28 +++++++++++++++------- arch/arm/mach-rockchip/sdram.c | 21 ++++++++++++---- 2 files changed, 35 insertions(+), 14 deletions(-)
Tested-by: Eugen Hristev eugen.hristev@collabora.com
Thanks !