diff options
author | Walter Wu <[email protected]> | 2020-08-06 23:24:54 -0700 |
---|---|---|
committer | Linus Torvalds <[email protected]> | 2020-08-07 11:33:28 -0700 |
commit | f33a01492a24a276e0bc1c932bcefdb8c1125159 (patch) | |
tree | d1219d827b66e395056ddcdcc8ac6e0f45f6a7c0 /tools/perf/scripts/python/export-to-sqlite.py | |
parent | c0e16ab3b5887e86cd45b95e28cf66498b161ee1 (diff) |
lib/test_kasan.c: fix KASAN unit tests for tag-based KASAN
We use tag-based KASAN, then KASAN unit tests don't detect out-of-bounds
memory access. They need to be fixed.
With tag-based KASAN, the state of each 16 aligned bytes of memory is
encoded in one shadow byte and the shadow value is tag of pointer, so
we need to read next shadow byte, the shadow value is not equal to tag
value of pointer, so that tag-based KASAN will detect out-of-bounds
memory access.
[[email protected]: use KASAN_SHADOW_SCALE_SIZE instead of 13]
Link: http://lkml.kernel.org/r/[email protected]
Suggested-by: Dmitry Vyukov <[email protected]>
Signed-off-by: Walter Wu <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Reviewed-by: Andrey Konovalov <[email protected]>
Acked-by: Dmitry Vyukov <[email protected]>
Cc: Andrey Ryabinin <[email protected]>
Cc: Alexander Potapenko <[email protected]>
Cc: Matthias Brugger <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/export-to-sqlite.py')
0 files changed, 0 insertions, 0 deletions