From e5016ad0daa69b4dc014a224001bf8f3edaeee89 Mon Sep 17 00:00:00 2001 From: Connor O'Brien Date: Mon, 28 Feb 2022 13:02:17 -0800 Subject: [PATCH] ANDROID: GKI: defconfig: enable BTF debug info Build BTF type info into the kernel to enable use of BPF-based tools such as BCC's libbpf-tools. By default, modules whose split BTF is inconsistent with vmlinux BTF will fail to load, which can prevent loading compatible but separately built modules. Instead, enable MODULE_ALLOW_BTF_MISMATCH to ignore such modules' BTF rather than refusing to load the module. Bug: 203823368 Bug: 218515241 Test: build Signed-off-by: Connor O'Brien Change-Id: I8efaab5f1a5c6ad6e9e6ccf1e78088d81a880480 --- 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 831e123e06c3..9f3e6ce5b3ca 100644 --- a/arch/arm64/configs/gki_defconfig +++ b/arch/arm64/configs/gki_defconfig @@ -674,6 +674,8 @@ CONFIG_PRINTK_TIME=y CONFIG_PRINTK_CALLER=y CONFIG_DYNAMIC_DEBUG_CORE=y CONFIG_DEBUG_INFO_DWARF4=y +CONFIG_DEBUG_INFO_BTF=y +CONFIG_MODULE_ALLOW_BTF_MISMATCH=y CONFIG_HEADERS_INSTALL=y # CONFIG_SECTION_MISMATCH_WARN_ONLY is not set CONFIG_MAGIC_SYSRQ=y diff --git a/arch/x86/configs/gki_defconfig b/arch/x86/configs/gki_defconfig index 7aae33e7c691..1a48260a5be1 100644 --- a/arch/x86/configs/gki_defconfig +++ b/arch/x86/configs/gki_defconfig @@ -626,6 +626,8 @@ CONFIG_DMA_CMA=y CONFIG_PRINTK_TIME=y CONFIG_DYNAMIC_DEBUG_CORE=y CONFIG_DEBUG_INFO_DWARF4=y +CONFIG_DEBUG_INFO_BTF=y +CONFIG_MODULE_ALLOW_BTF_MISMATCH=y CONFIG_HEADERS_INSTALL=y # CONFIG_SECTION_MISMATCH_WARN_ONLY is not set CONFIG_MAGIC_SYSRQ=y