1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter.git synced 2025-02-24 15:04:16 +00:00
openmptcprouter/root/target/linux/brcm2708/patches-4.19/962-limit-DMA-zone-for-arm64.patch

28 lines
914 B
Diff
Raw Normal View History

From e6bef7f1fafb6b0f69c2194821d93b3244dd5c0a Mon Sep 17 00:00:00 2001
From: Andrei Gherzan <andrei@balena.io>
Date: Tue, 16 Jul 2019 13:28:22 +0100
Subject: [PATCH] arm64/mm: Limit the DMA zone for arm64
On RaspberryPi, only the first 1Gb can be used for DMA[1].
[1] http://lists.infradead.org/pipermail/linux-arm-kernel/2019-July/665986.html
Signed-off-by: Andrei Gherzan <andrei@balena.io>
---
arch/arm64/mm/init.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm64/mm/init.c b/arch/arm64/mm/init.c
index 774c3e17c7982..75006fa076a01 100644
--- a/arch/arm64/mm/init.c
+++ b/arch/arm64/mm/init.c
@@ -475,7 +475,7 @@ void __init arm64_memblock_init(void)
/* 4GB maximum for 32-bit only capable devices */
if (IS_ENABLED(CONFIG_ZONE_DMA32))
- arm64_dma_phys_limit = max_zone_dma_phys();
+ arm64_dma_phys_limit = 0x40000000;
else
arm64_dma_phys_limit = PHYS_MASK + 1;