Hi,
Even with the default ddr4_timing.c file I could boot successfully with device tree changes as below in kernel and build imx8mnevk.conf file.
Changes are as below in kernel source code for my samsung DDR4 of 512MB model K4A4G165WF-BCTD,
diff --git a/arch/arm64/boot/dts/freescale/imx8mn.dtsi b/arch/arm64/boot/dts/freescale/imx8mn.dtsi
index 5d4c245376b0..2b619745f67e 100644
--- a/arch/arm64/boot/dts/freescale/imx8mn.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx8mn.dtsi
@@ -151,7 +151,7 @@
memory@40000000 {
device_type = "memory";
- reg = <0x0 0x40000000 0 0x80000000>;
+ reg = <0x0 0x40000000 0 0x60000000>;
};
resmem: reserved-memory {
@@ -163,8 +163,8 @@
linux,cma {
compatible = "shared-dma-pool";
reusable;
- size = <0 0x28000000>;
- alloc-ranges = <0 0x40000000 0 0x60000000>;
+ size = <0 0xa000000>;
+ alloc-ranges = <0 0x40000000 0 0x50000000>;
linux,cma-default;
};
};
In imx-yocto-bsp/sources/meta-imx/meta-bsp/conf/machine/imx8mnevk.conf
I modified as below,
- required conf/machine/imx8mnlpddr4evk.conf
+ required conf/machine/imx8mnlpddr4evk.conf
And I configured with bitbake -c menuconfig virtual/kernel
Library routines->DMA Contiguous Memory Allocator->Size in Mega Bytes
I have kept 160MB for my 512MB ram. One can increase or decrease according to there RAM size.
After all these, I could compile and build and boot successfully.
Thank you Zhiming and NXP for the support.