linux: enable MODULE_ALLOW_BTF_MISMATCH
Right now it looks like the BTFs are not reproducible between different builds of the same kernel, and the kernel will refuse to load modules if the BTF doesn't match. This can cause some interesting side effects when Nix uses different substituters for different parts of the kernel. This is far from ideal, and we _really_ should figure out how to actually make the BTF building consistently reproducible, but that seems more complicated, so maybe we should do this to get affected systems booting. See also: https://lore.kernel.org/bpf/YfK18x%2FXrYL4Vw8o@syu-laptop/ , where the openSUSE people ran into similar issues.
This commit is contained in:
@@ -45,6 +45,10 @@ let
|
||||
# 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
|
||||
# See https://github.com/NixOS/nixpkgs/pull/181456 for details.
|
||||
MODULE_ALLOW_BTF_MISMATCH = whenAtLeast "5.18" (option yes);
|
||||
BPF_LSM = whenAtLeast "5.7" (option yes);
|
||||
DEBUG_KERNEL = yes;
|
||||
DEBUG_DEVRES = no;
|
||||
|
||||
Reference in New Issue
Block a user