diff options
author | Catalin Marinas <[email protected]> | 2022-12-22 18:12:51 +0000 |
---|---|---|
committer | Will Deacon <[email protected]> | 2023-01-05 15:12:12 +0000 |
commit | 4f4c549feb4ecca95ae9abb88887b941d196f83a (patch) | |
tree | 5b413e7758916b5f3c7ac6d9e3ddf0b9fae0884c /tools/testing/selftests/bpf/progs/test_autoload.c | |
parent | 19e183b54528f11fafeca60fc6d0821e29ff281e (diff) |
arm64: mte: Avoid the racy walk of the vma list during core dump
The MTE coredump code in arch/arm64/kernel/elfcore.c iterates over the
vma list without the mmap_lock held. This can race with another process
or userfaultfd concurrently modifying the vma list. Change the
for_each_mte_vma macro and its callers to instead use the vma snapshot
taken by dump_vma_snapshot() and stored in the cprm object.
Fixes: 6dd8b1a0b6cb ("arm64: mte: Dump the MTE tags in the core file")
Cc: <[email protected]> # 5.18.x
Signed-off-by: Catalin Marinas <[email protected]>
Reported-by: Seth Jenkins <[email protected]>
Suggested-by: Seth Jenkins <[email protected]>
Cc: Will Deacon <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Will Deacon <[email protected]>
Diffstat (limited to 'tools/testing/selftests/bpf/progs/test_autoload.c')
0 files changed, 0 insertions, 0 deletions