From fe58c121167255eef7b234d6d1193281d2c8f5e6 Mon Sep 17 00:00:00 2001 From: "Isaac J. Manjarres" Date: Mon, 1 Nov 2021 15:04:31 -0700 Subject: [PATCH] ANDROID: Allow the deferred-free library heap to be compiled into the GKI The deferred-free library heap can be useful for modular implementations of the system heap, so compile it as a part of the GKI for arm64 and x86. Bug: 194472281 Change-Id: Iedd85682a90980b26a2f9aac0a53fcf4e1da219e Signed-off-by: Isaac J. Manjarres --- arch/arm64/configs/gki_defconfig | 1 + arch/x86/configs/gki_defconfig | 1 + drivers/dma-buf/heaps/Kconfig | 6 ++++-- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/arch/arm64/configs/gki_defconfig b/arch/arm64/configs/gki_defconfig index 1807cc184e33..e3c30f842e14 100644 --- a/arch/arm64/configs/gki_defconfig +++ b/arch/arm64/configs/gki_defconfig @@ -522,6 +522,7 @@ CONFIG_RTC_CLASS=y CONFIG_RTC_DRV_PL030=y CONFIG_RTC_DRV_PL031=y CONFIG_DMABUF_HEAPS=y +CONFIG_DMABUF_HEAPS_DEFERRED_FREE=y CONFIG_UIO=y CONFIG_VHOST_VSOCK=y CONFIG_STAGING=y diff --git a/arch/x86/configs/gki_defconfig b/arch/x86/configs/gki_defconfig index bd1934cbc5e3..6d30b7026bd1 100644 --- a/arch/x86/configs/gki_defconfig +++ b/arch/x86/configs/gki_defconfig @@ -488,6 +488,7 @@ CONFIG_EDAC=y CONFIG_RTC_CLASS=y # CONFIG_RTC_HCTOSYS is not set CONFIG_DMABUF_HEAPS=y +CONFIG_DMABUF_HEAPS_DEFERRED_FREE=y CONFIG_UIO=y CONFIG_VHOST_VSOCK=y CONFIG_STAGING=y diff --git a/drivers/dma-buf/heaps/Kconfig b/drivers/dma-buf/heaps/Kconfig index 1c46b90fd2f4..ad58616b34df 100644 --- a/drivers/dma-buf/heaps/Kconfig +++ b/drivers/dma-buf/heaps/Kconfig @@ -1,5 +1,7 @@ -config DMABUF_HEAPS_DEFERRED_FREE - tristate +menuconfig DMABUF_HEAPS_DEFERRED_FREE + bool "DMA-BUF heaps deferred-free library" + help + Choose this option to enable the DMA-BUF heaps deferred-free library. config DMABUF_HEAPS_SYSTEM tristate "DMA-BUF System Heap"