path: root/lib/Kconfig.kasan
diff options
authorAndrey Konovalov <>2021-02-24 12:05:26 -0800
committerLinus Torvalds <>2021-02-24 13:38:31 -0800
commitf05842cfb9ae25b5e78c618429c4716d9e4d5fc8 (patch)
tree903a626a0cf734d328721455ef8e8b49b9ceb47e /lib/Kconfig.kasan
parent573a48092313dec7b254d9dbcc2db62167f00456 (diff)
kasan, arm64: allow using KUnit tests with HW_TAGS mode
On a high level, this patch allows running KUnit KASAN tests with the hardware tag-based KASAN mode. Internally, this change reenables tag checking at the end of each KASAN test that triggers a tag fault and leads to tag checking being disabled. Also simplify is_write calculation in report_tag_fault. With this patch KASAN tests are still failing for the hardware tag-based mode; fixes come in the next few patches. [ export HW_TAGS symbols for KUnit tests] Link: Link: Link: Signed-off-by: Andrey Konovalov <> Reviewed-by: Catalin Marinas <> Reviewed-by: Vincenzo Frascino <> Cc: Alexander Potapenko <> Cc: Andrey Ryabinin <> Cc: Branislav Rankov <> Cc: Dmitry Vyukov <> Cc: Evgenii Stepanov <> Cc: Kevin Brodsky <> Cc: Marco Elver <> Cc: Peter Collingbourne <> Cc: Will Deacon <> Signed-off-by: Andrew Morton <> Signed-off-by: Linus Torvalds <>
Diffstat (limited to 'lib/Kconfig.kasan')
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Kconfig.kasan b/lib/Kconfig.kasan
index f5fa4ba126bf..3091432acb0a 100644
--- a/lib/Kconfig.kasan
+++ b/lib/Kconfig.kasan
@@ -190,11 +190,11 @@ config KASAN_KUNIT_TEST
kernel debugging features like KASAN.
For more information on KUnit and unit tests in general, please refer
- to the KUnit documentation in Documentation/dev-tools/kunit
+ to the KUnit documentation in Documentation/dev-tools/kunit.
tristate "KUnit-incompatible tests of KASAN bug detection capabilities"
- depends on m && KASAN
+ depends on m && KASAN && !KASAN_HW_TAGS
This is a part of the KASAN test suite that is incompatible with
KUnit. Currently includes tests that do bad copy_from/to_user