Files
linux-stable-mirror/arch/mips/include/asm/mach-ralink/kmalloc.h
T
Qingfang DengandThomas Bogendoerfer 1dc85756b7 MIPS: ralink: reduce ARCH_DMA_MINALIGN
Currently, Ralink SoCs use the default ARCH_DMA_MINALIGN value of 128
bytes defined in mach-generic. This is excessive for these platforms
and leads to significant memory waste in kmalloc.

Override ARCH_DMA_MINALIGN to use L1_CACHE_BYTES, which is 16 bytes for
RT288X and 32 bytes for other Ralink SoCs.

Signed-off-by: Qingfang Deng <qingfang.deng@linux.dev>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
2026-05-26 16:35:37 +02:00

10 lines
232 B
C

/* SPDX-License-Identifier: GPL-2.0 */
#ifndef __ASM_MACH_RALINK_KMALLOC_H
#define __ASM_MACH_RALINK_KMALLOC_H
#ifdef CONFIG_DMA_NONCOHERENT
#define ARCH_DMA_MINALIGN L1_CACHE_BYTES
#endif
#endif /* __ASM_MACH_RALINK_KMALLOC_H */