From 07141d408124bcf71aa160102e166950610dd862 Mon Sep 17 00:00:00 2001 From: Asha Magadi Venkateshamurthy Date: Tue, 29 Sep 2020 21:42:54 +0530 Subject: [PATCH] mm/Kconfig: forcing allocators to return ZONE_DMA32 memory Add a new config item, CONFIG_FORCE_ALLOC_FROM_DMA_ZONE, which can be used to optionally force certain allocators to always return memory from ZONE_DMA32. This option helps ensure that clients who require ZONE_DMA32 memory are always using ZONE_DMA32 memory. Change-Id: Id2d36214307789f27aa775c2bef2dab5047c4ff0 Signed-off-by: Praveen Kurapati Signed-off-by: Liam Mark Signed-off-by: Patrick Daly Signed-off-by: Sudarshan Rajagopalan Signed-off-by: Asha Magadi Venkateshamurthy --- mm/Kconfig | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/mm/Kconfig b/mm/Kconfig index c73d368dbd60..b6dbab55f77a 100644 --- a/mm/Kconfig +++ b/mm/Kconfig @@ -875,3 +875,13 @@ config PROCESS_RECLAIM (addr, addr + size-bytes) of the process. Any other value is ignored. + +config FORCE_ALLOC_FROM_DMA_ZONE + bool "Force certain memory allocators to always return ZONE_DMA32 memory" + depends on ZONE_DMA32 + help + Ensure certain memory allocators always return memory from ZONE_DMA32. + This option helps ensure that clients who require ZONE_DMA32 memory are + always using ZONE_DMA32 memory. + + If unsure, say "n".