summaryrefslogtreecommitdiffstats
path: root/security/apparmor
diff options
context:
space:
mode:
authorMichal Hocko <mhocko@suse.com>2016-03-15 14:57:01 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2016-03-15 16:55:16 -0700
commit0db2cb8da89d991762ec2aece45e55ceaee34664 (patch)
treeb8821119e212ee45266cc73ba36a04a84247b6f6 /security/apparmor
parentd7206a70af5c094446927b5dea8704f0f96303e3 (diff)
downloadlinux-stable-0db2cb8da89d991762ec2aece45e55ceaee34664.tar.gz
linux-stable-0db2cb8da89d991762ec2aece45e55ceaee34664.tar.bz2
linux-stable-0db2cb8da89d991762ec2aece45e55ceaee34664.zip
mm, vmscan: make zone_reclaimable_pages more precise
zone_reclaimable_pages() is used in should_reclaim_retry() which uses it to calculate the target for the watermark check. This means that precise numbers are important for the correct decision. zone_reclaimable_pages uses zone_page_state which can contain stale data with per-cpu diffs not synced yet (the last vmstat_update might have run 1s in the past). Use zone_page_state_snapshot() in zone_reclaimable_pages() instead. None of the current callers is in a hot path where getting the precise value (which involves per-cpu iteration) would cause an unreasonable overhead. Signed-off-by: Michal Hocko <mhocko@suse.com> Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Suggested-by: David Rientjes <rientjes@google.com> Acked-by: David Rientjes <rientjes@google.com> Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'security/apparmor')
0 files changed, 0 insertions, 0 deletions