diff options
author | Lorenzo Stoakes <[email protected]> | 2023-07-31 22:50:21 +0100 |
---|---|---|
committer | Andrew Morton <[email protected]> | 2023-08-04 13:03:42 -0700 |
commit | 17457784004c84178798432a029ab20e14f728b1 (patch) | |
tree | cd82f1bd5543b7e3357b21d9db840a10d1f85693 /scripts/generate_rust_analyzer.py | |
parent | d1ef9dba07bf637995202d0efd29c2fea19e809c (diff) |
fs/proc/kcore: reinstate bounce buffer for KCORE_TEXT regions
Some architectures do not populate the entire range categorised by
KCORE_TEXT, so we must ensure that the kernel address we read from is
valid.
Unfortunately there is no solution currently available to do so with a
purely iterator solution so reinstate the bounce buffer in this instance
so we can use copy_from_kernel_nofault() in order to avoid page faults
when regions are unmapped.
This change partly reverts commit 2e1c0170771e ("fs/proc/kcore: avoid
bounce buffer for ktext data"), reinstating the bounce buffer, but adapts
the code to continue to use an iterator.
[[email protected]: correct comment to be strictly correct about reasoning]
Link: https://lkml.kernel.org/r/[email protected]
Link: https://lkml.kernel.org/r/[email protected]
Fixes: 2e1c0170771e ("fs/proc/kcore: avoid bounce buffer for ktext data")
Signed-off-by: Lorenzo Stoakes <[email protected]>
Reported-by: Jiri Olsa <[email protected]>
Closes: https://lore.kernel.org/all/ZHc2fm+9daF6cgCE@krava
Tested-by: Jiri Olsa <[email protected]>
Tested-by: Will Deacon <[email protected]>
Cc: Alexander Viro <[email protected]>
Cc: Ard Biesheuvel <[email protected]>
Cc: Baoquan He <[email protected]>
Cc: Catalin Marinas <[email protected]>
Cc: David Hildenbrand <[email protected]>
Cc: Jens Axboe <[email protected]>
Cc: Kefeng Wang <[email protected]>
Cc: Liu Shixin <[email protected]>
Cc: Matthew Wilcox <[email protected]>
Cc: Mike Galbraith <[email protected]>
Cc: Thorsten Leemhuis <[email protected]>
Cc: Uladzislau Rezki (Sony) <[email protected]>
Cc: <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Diffstat (limited to 'scripts/generate_rust_analyzer.py')
0 files changed, 0 insertions, 0 deletions