From 291f8636115d96a9ba20ce6142fad37599b0bcb9 Mon Sep 17 00:00:00 2001 From: Suren Baghdasaryan Date: Mon, 25 Nov 2024 16:14:19 -0800 Subject: [PATCH] ANDROID: enable memory allocation profiling configs Enable memory allocation profiling while keeping it turned off by default. The feature can be enabled using kernel command like by adding the below boot parameter: sysctl.vm.mem_profiling=1,compressed Bug: 380948583 Change-Id: I7c863153b69aa7b9dc2fcfef6678260852ffa258 Signed-off-by: Suren Baghdasaryan --- arch/arm64/configs/gki_defconfig | 2 ++ arch/x86/configs/gki_defconfig | 2 ++ 2 files changed, 4 insertions(+) diff --git a/arch/arm64/configs/gki_defconfig b/arch/arm64/configs/gki_defconfig index 166378231d66..7d7f925d5b9d 100644 --- a/arch/arm64/configs/gki_defconfig +++ b/arch/arm64/configs/gki_defconfig @@ -755,6 +755,8 @@ CONFIG_UBSAN_TRAP=y # CONFIG_UBSAN_ENUM is not set CONFIG_PAGE_OWNER=y CONFIG_DEBUG_MEMORY_INIT=y +CONFIG_MEM_ALLOC_PROFILING=y +# CONFIG_MEM_ALLOC_PROFILING_ENABLED_BY_DEFAULT is not set CONFIG_KASAN=y CONFIG_KASAN_HW_TAGS=y CONFIG_KFENCE=y diff --git a/arch/x86/configs/gki_defconfig b/arch/x86/configs/gki_defconfig index 4f6796c7c7ce..ecffcdb6976e 100644 --- a/arch/x86/configs/gki_defconfig +++ b/arch/x86/configs/gki_defconfig @@ -684,6 +684,8 @@ CONFIG_UBSAN_TRAP=y # CONFIG_UBSAN_ENUM is not set CONFIG_PAGE_OWNER=y CONFIG_DEBUG_MEMORY_INIT=y +CONFIG_MEM_ALLOC_PROFILING=y +# CONFIG_MEM_ALLOC_PROFILING_ENABLED_BY_DEFAULT is not set CONFIG_KFENCE=y CONFIG_KFENCE_SAMPLE_INTERVAL=500 CONFIG_KFENCE_NUM_OBJECTS=63