aboutsummaryrefslogtreecommitdiff
path: root/arch/csky/mm/init.c
diff options
context:
space:
mode:
authorAndrey Konovalov <[email protected]>2021-04-29 23:00:49 -0700
committerLinus Torvalds <[email protected]>2021-04-30 11:20:42 -0700
commit99734b535d9bf8d5826be8f8f3719dfc586c3452 (patch)
treeb6830f839757840e1b9d26474e9e4549498026f7 /arch/csky/mm/init.c
parent23f61f0fe106da8c9f6a883965439ecc2838f116 (diff)
kasan: detect false-positives in tests
Currently, KASAN-KUnit tests can check that a particular annotated part of code causes a KASAN report. However, they do not check that no unwanted reports happen between the annotated parts. This patch implements these checks. It is done by setting report_data.report_found to false in kasan_test_init() and at the end of KUNIT_EXPECT_KASAN_FAIL() and then checking that it remains false at the beginning of KUNIT_EXPECT_KASAN_FAIL() and in kasan_test_exit(). kunit_add_named_resource() call is moved to kasan_test_init(), and the value of fail_data.report_expected is kept as false in between KUNIT_EXPECT_KASAN_FAIL() annotations for consistency. Link: https://lkml.kernel.org/r/48079c52cc329fbc52f4386996598d58022fb872.1617207873.git.andreyknvl@google.com Signed-off-by: Andrey Konovalov <[email protected]> Reviewed-by: Marco Elver <[email protected]> Cc: Alexander Potapenko <[email protected]> Cc: Dmitry Vyukov <[email protected]> Cc: Andrey Ryabinin <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'arch/csky/mm/init.c')
0 files changed, 0 insertions, 0 deletions