aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/net_dropmonitor.py
diff options
context:
space:
mode:
authorSimon Guo <[email protected]>2016-10-07 16:59:36 -0700
committerLinus Torvalds <[email protected]>2016-10-07 18:46:28 -0700
commit0cf2f6f6dc605e587d2c1120f295934c77e810e8 (patch)
tree9c8bdb773bf8edafab427f42f4c649b41048a9f7 /tools/perf/scripts/python/net_dropmonitor.py
parent9254990fb9f0f15f25605748da20cfbeced7c816 (diff)
mm: mlock: check against vma for actual mlock() size
In do_mlock(), the check against locked memory limitation has a hole which will fail following cases at step 3): 1) User has a memory chunk from addressA with 50k, and user mem lock rlimit is 64k. 2) mlock(addressA, 30k) 3) mlock(addressA, 40k) The 3rd step should have been allowed since the 40k request is intersected with the previous 30k at step 2), and the 3rd step is actually for mlock on the extra 10k memory. This patch checks vma to caculate the actual "new" mlock size, if necessary, and ajust the logic to fix this issue. [[email protected]: clean up comment layout] [[email protected]: correct a typo in count_mm_mlocked_page_nr()] Link: http://lkml.kernel.org/r/[email protected] Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Simon Guo <[email protected]> Cc: Alexey Klimov <[email protected]> Cc: Eric B Munson <[email protected]> Cc: Geert Uytterhoeven <[email protected]> Cc: "Kirill A. Shutemov" <[email protected]> Cc: Mel Gorman <[email protected]> Cc: Michal Hocko <[email protected]> Cc: Shuah Khan <[email protected]> Cc: Simon Guo <[email protected]> Cc: Thierry Reding <[email protected]> Cc: Vlastimil Babka <[email protected]> Cc: David Rientjes <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/net_dropmonitor.py')
0 files changed, 0 insertions, 0 deletions