path: root/lib/Kconfig.ubsan
diff options
authorKees Cook <>2020-12-15 20:46:31 -0800
committerLinus Torvalds <>2020-12-15 22:46:18 -0800
commit79791378a1bc9e218462211742e48e375371e8c5 (patch)
tree18833f785eb1e8af91d99717c09ac334d251bb79 /lib/Kconfig.ubsan
parent61e0349f703d1576a12f88c15f25e0a56fd277af (diff)
ubsan: disable UBSAN_TRAP for all*config
Doing all*config builds attempts to build as much as possible. UBSAN_TRAP effectively short-circuits lib/usban.c, so it should be disabled for COMPILE_TEST so that the lib/ubsan.c code gets built. Link: Signed-off-by: Kees Cook <> Reviewed-by: Nathan Chancellor <> Cc: Andrey Ryabinin <> Cc: Ard Biesheuvel <> Cc: Arnd Bergmann <> Cc: Dmitry Vyukov <> Cc: George Popescu <> Cc: Herbert Xu <> Cc: Linus Torvalds <> Cc: Marco Elver <> Cc: Masahiro Yamada <> Cc: Michal Marek <> Cc: Nick Desaulniers <> Cc: Peter Oberparleiter <> Cc: Randy Dunlap <> Signed-off-by: Andrew Morton <> Signed-off-by: Linus Torvalds <>
Diffstat (limited to 'lib/Kconfig.ubsan')
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/Kconfig.ubsan b/lib/Kconfig.ubsan
index 4190a99b1eaa..6e8b67d4b0d9 100644
--- a/lib/Kconfig.ubsan
+++ b/lib/Kconfig.ubsan
@@ -14,6 +14,7 @@ if UBSAN
bool "On Sanitizer warnings, abort the running kernel code"
+ depends on !COMPILE_TEST
depends on $(cc-option, -fsanitize-undefined-trap-on-error)
Building kernels with Sanitizer features enabled tends to grow