diff options
author | Daniel Axtens <[email protected]> | 2019-12-17 20:51:49 -0800 |
---|---|---|
committer | Linus Torvalds <[email protected]> | 2019-12-17 20:59:59 -0800 |
commit | 253a496d8e57275d458eb3c988470525b0b2c545 (patch) | |
tree | 13cb1452959d971018c4db8d7d0a7659884d7c2e /tools/perf/scripts/python/export-to-sqlite.py | |
parent | e218f1ca3971e5bcaae1fe8e6f007f9a206e32e9 (diff) |
kasan: don't assume percpu shadow allocations will succeed
syzkaller and the fault injector showed that I was wrong to assume that
we could ignore percpu shadow allocation failures.
Handle failures properly. Merge all the allocated areas back into the
free list and release the shadow, then clean up and return NULL. The
shadow is released unconditionally, which relies upon the fact that the
release function is able to tolerate pages not being present.
Also clean up shadows in the recovery path - currently they are not
released, which leaks a bit of memory.
Link: http://lkml.kernel.org/r/[email protected]
Fixes: 3c5c3cfb9ef4 ("kasan: support backing vmalloc space with real shadow memory")
Signed-off-by: Daniel Axtens <[email protected]>
Reported-by: [email protected]
Reported-by: [email protected]
Reviewed-by: Andrey Ryabinin <[email protected]>
Cc: Dmitry Vyukov <[email protected]>
Cc: Alexander Potapenko <[email protected]>
Cc: Qian Cai <[email protected]>
Cc: Uladzislau Rezki (Sony) <[email protected]>
Signed-off-by: Andrew Morton <[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