Skip to contentSkip to conversation

imx93_frdm: Add support for 2CS 2GB DRAM support

PATCH New Mathieu Dubois-Briand 1 participant 1 message Jun 16 Arm i.MX and Layerscape

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 imx93_frdm: Add support for 2CS 2GB DRAM support

Add 2CS 2GB DRAM configuration, as revision B2 of the i.MX93 FRDM board is using it.

This is mostly an import of Tom Zheng work from NXP u-boot git:
https://github.com/nxp-imx/uboot-imx/commit/4c35a6086aed

---
Tom, please tell me if you want me to add a
Co-developed-by/Signed-off-by tag.
---
Changes in v2:
- Added link to original commit in my commit messsage.
- Link to v1: https://lore.kernel.org/r/[email protected]

---
 board/nxp/imx93_frdm/Makefile                      |    2 +-
 board/nxp/imx93_frdm/lpddr4_timing.h               |    3 +-
 ...ddr4x_2gb_timing.c => lpddr4x_1cs_2gb_timing.c} |    2 +-
 board/nxp/imx93_frdm/lpddr4x_2cs_2gb_timing.c      | 2006 ++++++++++++++++++++
 board/nxp/imx93_frdm/spl.c                         |    5 +-
 5 files changed, 2013 insertions(+), 5 deletions(-)
board/nxp/imx93_frdm/Makefile +1 -1
index 9612b1fa55b7..751ebfc94580 100644
@@ -7,5 +7,5 @@
 obj-y += imx93_frdm.o
 
 ifdef CONFIG_XPL_BUILD
-obj-y += spl.o lpddr4x_1gb_timing.o lpddr4x_2gb_timing.o
+obj-y += spl.o lpddr4x_1gb_timing.o lpddr4x_1cs_2gb_timing.o lpddr4x_2cs_2gb_timing.o
 endif
board/nxp/imx93_frdm/lpddr4_timing.h +2 -1
index 192bc9e1519c..3ff50d8519ba 100644
@@ -7,6 +7,7 @@
 #define __LPDDR4_TIMING_H__
 
 extern struct dram_timing_info dram_timing_1GB;
-extern struct dram_timing_info dram_timing_2GB;
+extern struct dram_timing_info dram_timing_1CS_2GB;
+extern struct dram_timing_info dram_timing_2CS_2GB;
 
 #endif /* __LPDDR4_TIMING_H__ */
board/nxp/imx93_frdm/lpddr4x_1cs_2gb_timing.c renamed from board/nxp/imx93_frdm/lpddr4x_2gb_timing.c +1 -1
similarity index 99%
rename from board/nxp/imx93_frdm/lpddr4x_2gb_timing.c
rename to board/nxp/imx93_frdm/lpddr4x_1cs_2gb_timing.c
index cd129e129591..5439a039c3d3 100644
@@ -1978,7 +1978,7 @@ static struct dram_fsp_msg ddr_dram_fsp_msg[] = {
 };
 
 /* ddr timing config params */
-struct dram_timing_info dram_timing_2GB = {
+struct dram_timing_info dram_timing_1CS_2GB = {
 	.ddrc_cfg = ddr_ddrc_cfg,
 	.ddrc_cfg_num = ARRAY_SIZE(ddr_ddrc_cfg),
 	.ddrphy_cfg = ddr_ddrphy_cfg,
board/nxp/imx93_frdm/lpddr4x_2cs_2gb_timing.c new file +2006 -0

2,006 lines not on this page · raw message

board/nxp/imx93_frdm/spl.c +3 -2
index 068091ba0e96..40054ff72d03 100644
@@ -33,9 +33,10 @@ static struct _drams {
 	u8 mr8;
 	struct dram_timing_info *pdram_timing;
 	char *name;
-} frdm_drams[2] = {
+} frdm_drams[3] = {
 	{0x10, &dram_timing_1GB, "1GB DRAM" },
-	{0x18, &dram_timing_2GB, "2GB DRAM" },
+	{0x12, &dram_timing_2CS_2GB, "2CS_2GB DRAM" },
+	{0x18, &dram_timing_1CS_2GB, "1CS_2GB DRAM" },
 };
 
 int spl_board_boot_device(enum boot_device boot_dev_spl)

---
base-commit: 1a8b7ad50aed5f5f0a4ccbfd455233919c097293
change-id: 20260609-mathieu-ram-6a076ef19369

Best regards,

Signature · 1 line
Mathieu Dubois-Briand <[email protected]>