public inbox for linux-arm-kernel@lists.infradead.org
 help / color / mirror / Atom feed
* [PATCH] arm64: dts: amlogic: t7: khadas-vim4: fix memory layout for 8GB RAM
@ 2026-03-06  3:10 Nick Xie
  2026-03-06  7:54 ` Ronald Claveau
  0 siblings, 1 reply; 2+ messages in thread
From: Nick Xie @ 2026-03-06  3:10 UTC (permalink / raw)
  To: neil.armstrong, khilman, martin.blumenstingl, jbrunet
  Cc: krzk+dt, robh, conor+dt, linux-amlogic, linux-arm-kernel,
	devicetree, linux-kernel, Nick Xie

The Khadas VIM4 features 8GB of LPDDR4X RAM. The previous memory node
mapped a single incorrect region. This caused the kernel to map MMIO
and secure firmware (ATF/TrustZone) memory holes as standard RAM,
leading to an Asynchronous SError Interrupt during early boot
(paging_init) when the kernel attempted to clear those pages.

Fix this by splitting the 8GB memory layout into three separate
regions to properly avoid the memory holes (e.g., 0xe0000000 -
0xffffffff):
- 3.5GB @ 0x000000000
- 3.5GB @ 0x100000000
- 1.0GB @ 0x200000000

Signed-off-by: Nick Xie <nick@khadas.com>
---
 arch/arm64/boot/dts/amlogic/amlogic-t7-a311d2-khadas-vim4.dts | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/amlogic/amlogic-t7-a311d2-khadas-vim4.dts b/arch/arm64/boot/dts/amlogic/amlogic-t7-a311d2-khadas-vim4.dts
index 25b478e106451..106eab2b4c2e2 100644
--- a/arch/arm64/boot/dts/amlogic/amlogic-t7-a311d2-khadas-vim4.dts
+++ b/arch/arm64/boot/dts/amlogic/amlogic-t7-a311d2-khadas-vim4.dts
@@ -17,7 +17,9 @@ aliases {
 
 	memory@0 {
 		device_type = "memory";
-		reg = <0x0 0x0 0x2 0x0>; /* 8 GB */
+		reg = <0x00000000 0x00000000 0x00000000 0xE0000000
+			0x00000001 0x00000000 0x00000000 0xE0000000
+			0x00000002 0x00000000 0x00000000 0x40000000>;
 	};
 
 	reserved-memory {
-- 
2.34.1



^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-03-06  7:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-06  3:10 [PATCH] arm64: dts: amlogic: t7: khadas-vim4: fix memory layout for 8GB RAM Nick Xie
2026-03-06  7:54 ` Ronald Claveau

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox