diff options
| author | Michal Hocko <[email protected]> | 2020-06-25 20:29:21 -0700 |
|---|---|---|
| committer | Linus Torvalds <[email protected]> | 2020-06-26 00:27:36 -0700 |
| commit | 545b1b077ca6b359820436af097bc65e3f6f6cc9 (patch) | |
| tree | 44fcc50aabcaf951cf99b64c10035a73fcb24960 /tools/perf/scripts/python/flamegraph.py | |
| parent | 313a5257b84c26b7f080c5d294aabe7d38ca439c (diff) | |
mm: do_swap_page(): fix up the error code
do_swap_page() returns error codes from the VM_FAULT* space. try_charge()
might return -ENOMEM, though, and then do_swap_page() simply returns 0
which means a success.
We almost never return ENOMEM for GFP_KERNEL single page charge. Except
for async OOM handling (oom_disabled v1). So this needs translation to
VM_FAULT_OOM otherwise the the page fault path will not notify the
userspace and wait for an action.
Link: http://lkml.kernel.org/r/[email protected]
Fixes: 4c6355b25e8b ("mm: memcontrol: charge swapin pages on instantiation")
Signed-off-by: Michal Hocko <[email protected]>
Acked-by: Johannes Weiner <[email protected]>
Cc: Alex Shi <[email protected]>
Cc: Joonsoo Kim <[email protected]>
Cc: Shakeel Butt <[email protected]>
Cc: Hugh Dickins <[email protected]>
Cc: "Kirill A. Shutemov" <[email protected]>
Cc: Roman Gushchin <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/flamegraph.py')
0 files changed, 0 insertions, 0 deletions