1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter.git synced 2025-02-12 19:31:52 +00:00

Test to fix RPI4 with more than 1Go another way

This commit is contained in:
Ycarus (Yannick Chabanois) 2019-07-16 21:34:29 +02:00
parent 650fc95f8d
commit 3a50139946
2 changed files with 29 additions and 2 deletions

View file

@ -1,5 +1,5 @@
#
# Copyright (C) 2012-2016 OpenWrt.org
# Copyright (C) 2012-2019 OpenWrt.org
# Copyright (C) 2017 LEDE project
#
# This is free software, licensed under the GNU General Public License v2.
@ -14,7 +14,7 @@ FEATURES:=ext4 audio usb usbgadget display gpio fpu squashfs rootfs-part boot-pa
MAINTAINER:=Álvaro Fernández Rojas <noltari@gmail.com>
SUBTARGETS:=bcm2708 bcm2709 bcm2710 bcm2711
KERNEL_PATCHVER:=4.14
KERNEL_PATCHVER:=4.19
define Target/Description
Build firmware image for Broadcom BCM27xx SoC devices.

View file

@ -0,0 +1,27 @@
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;