0
0
mirror of https://git.openwrt.org/openwrt/openwrt.git synced 2024-11-22 04:56:15 +00:00
openwrt/target/linux/bcm27xx/patches-6.6/950-0908-arm64-Kconfig-Don-t-set-DMA_BOUNCE_UNALIGNED_KMALLOC.patch
Álvaro Fernández Rojas 8c405cdccc bcm27xx: add 6.6 kernel patches
The patches were generated from the RPi repo with the following command:
git format-patch v6.6.34..rpi-6.1.y

Some patches needed rebasing and, as usual, the applied and reverted, wireless
drivers, Github workflows, READMEs and defconfigs patches were removed.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-06-18 18:52:49 +02:00

31 lines
1.1 KiB
Diff

From 953f00c3ceb5879d8f0d2f2683d70ff93efedad4 Mon Sep 17 00:00:00 2001
From: Phil Elwell <phil@raspberrypi.com>
Date: Wed, 21 Feb 2024 14:16:21 +0000
Subject: [PATCH 0908/1085] arm64/Kconfig: Don't set
DMA_BOUNCE_UNALIGNED_KMALLOC
If enabled, DMA_BOUNCE_UNALIGNED_KMALLOC causes the swiotlb buffers
(64MB, by default) to be allocated, even on systems where the DMA
controller can reach all of RAM. This is a huge amount of RAM to
waste on a device with only 512MB to start with, such as the Zero 2 W.
See: https://github.com/raspberrypi/linux/issues/5975
Signed-off-by: Phil Elwell <phil@raspberrypi.com>
---
arch/arm64/Kconfig | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
--- a/arch/arm64/Kconfig
+++ b/arch/arm64/Kconfig
@@ -122,7 +122,8 @@ config ARM64
select CRC32
select DCACHE_WORD_ACCESS
select DYNAMIC_FTRACE if FUNCTION_TRACER
- select DMA_BOUNCE_UNALIGNED_KMALLOC
+ # Disable this to save 64MB when DMA controllers can reach all of RAM
+ # select DMA_BOUNCE_UNALIGNED_KMALLOC
select DMA_DIRECT_REMAP
select EDAC_SUPPORT
select FRAME_POINTER