From e845c965addb7acecfb3642afa6a7514ad92e30b Mon Sep 17 00:00:00 2001 From: Minchan Kim Date: Tue, 23 Mar 2021 18:11:13 -0700 Subject: [PATCH] ANDROID: GKI: enable CONFIG_CMA_SYSFS Since CMA is getting used more widely, it's more important to keep monitoring CMA statistics for system health since it's directly related to user experience. This feature introduces sysfs statistics for CMA, in order to provide some basic monitoring of the CMA allocator. * the number of CMA page successful allocations * the number of CMA page allocation failures These two values allow the user to calculate the allocation failure rate for each CMA area. Bug: 179256052 Signed-off-by: Minchan Kim Change-Id: I5c8dc58a5d195d2e1b2e25628545f7d2a9c3b7df Signed-off-by: Richard Chang (cherry picked from commit f45afb45088ce84a82ce0d0aac13abf10b47688d) --- arch/arm64/configs/gki_defconfig | 1 + arch/x86/configs/gki_defconfig | 1 + 2 files changed, 2 insertions(+) diff --git a/arch/arm64/configs/gki_defconfig b/arch/arm64/configs/gki_defconfig index 6f0618c3f4c6..6059094a28a0 100644 --- a/arch/arm64/configs/gki_defconfig +++ b/arch/arm64/configs/gki_defconfig @@ -118,6 +118,7 @@ CONFIG_TRANSPARENT_HUGEPAGE_MADVISE=y CONFIG_CLEANCACHE=y CONFIG_CMA=y CONFIG_CMA_DEBUGFS=y +CONFIG_CMA_SYSFS=y CONFIG_CMA_AREAS=16 CONFIG_ZSMALLOC=m # CONFIG_ZONE_DMA is not set diff --git a/arch/x86/configs/gki_defconfig b/arch/x86/configs/gki_defconfig index d6f3d06f4660..894f9fa4fa7c 100644 --- a/arch/x86/configs/gki_defconfig +++ b/arch/x86/configs/gki_defconfig @@ -98,6 +98,7 @@ CONFIG_TRANSPARENT_HUGEPAGE_MADVISE=y CONFIG_CLEANCACHE=y CONFIG_CMA=y CONFIG_CMA_DEBUGFS=y +CONFIG_CMA_SYSFS=y CONFIG_CMA_AREAS=16 CONFIG_ZSMALLOC=m # CONFIG_ZONE_DMA is not set