From bad4d76dac4fbed0b57c4e9f7b8bbf829c52bfb5 Mon Sep 17 00:00:00 2001 From: Dominique Martinet Date: Sat, 9 Jul 2022 10:29:40 +0900 Subject: [PATCH] linux-kernel config: disable DEBUG_INFO_REDUCED Linux's aarch64 defconfig has been updated in 5.13 to enable "reduced" debug infos (upstream commit ed938a4bfc58 ("arm64: defconfig: Use DEBUG_INFO_REDUCED"), but that commits locks DEBUG_INFO_BTF as noticed in #175467 This disables it back which should fix bpftrace usage of BTF not working on newer kernels. (cherry picked from commit 47f9f047883996aa54defa9cda7ccd7e04df7901) --- pkgs/os-specific/linux/kernel/common-config.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pkgs/os-specific/linux/kernel/common-config.nix b/pkgs/os-specific/linux/kernel/common-config.nix index e1d4cdb83648..ea6a420f787a 100644 --- a/pkgs/os-specific/linux/kernel/common-config.nix +++ b/pkgs/os-specific/linux/kernel/common-config.nix @@ -41,6 +41,9 @@ let (whenBetween "5.2" "5.18" yes) ]; DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT = whenAtLeast "5.18" yes; + # Reduced debug info conflict with BTF and have been enabled in + # aarch64 defconfig since 5.13 + DEBUG_INFO_REDUCED = whenAtLeast "5.13" (option no); DEBUG_INFO_BTF = whenAtLeast "5.2" (option yes); # Allow loading modules with mismatched BTFs # FIXME: figure out how to actually make BTFs reproducible instead