aboutsummaryrefslogtreecommitdiffstats
path: root/mm/vmscan.c
diff options
context:
space:
mode:
authorVladimir Davydov <vdavydov@parallels.com>2014-04-03 17:47:19 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2014-04-03 19:20:58 -0400
commit99120b772b52853f9a2b829a21dd44d9b20558f1 (patch)
tree74046a072f579357e6d4e4f3f60fff46e55e2e12 /mm/vmscan.c
parent62572e29bc530b38921ef6059088b4788a9832a5 (diff)
mm: vmscan: respect NUMA policy mask when shrinking slab on direct reclaim
When direct reclaim is executed by a process bound to a set of NUMA nodes, we should scan only those nodes when possible, but currently we will scan kmem from all online nodes even if the kmem shrinker is NUMA aware. That said, binding a process to a particular NUMA node won't prevent it from shrinking inode/dentry caches from other nodes, which is not good. Fix this. Signed-off-by: Vladimir Davydov <vdavydov@parallels.com> Cc: Mel Gorman <mgorman@suse.de> Cc: Michal Hocko <mhocko@suse.cz> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Rik van Riel <riel@redhat.com> Cc: Dave Chinner <dchinner@redhat.com> Cc: Glauber Costa <glommer@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/vmscan.c')
-rw-r--r--mm/vmscan.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/mm/vmscan.c b/mm/vmscan.c
index a9c74b409681..4acee0fe65e7 100644
--- a/mm/vmscan.c
+++ b/mm/vmscan.c
@@ -2425,8 +2425,8 @@ static unsigned long do_try_to_free_pages(struct zonelist *zonelist,
2425 unsigned long lru_pages = 0; 2425 unsigned long lru_pages = 0;
2426 2426
2427 nodes_clear(shrink->nodes_to_scan); 2427 nodes_clear(shrink->nodes_to_scan);
2428 for_each_zone_zonelist(zone, z, zonelist, 2428 for_each_zone_zonelist_nodemask(zone, z, zonelist,
2429 gfp_zone(sc->gfp_mask)) { 2429 gfp_zone(sc->gfp_mask), sc->nodemask) {
2430 if (!cpuset_zone_allowed_hardwall(zone, GFP_KERNEL)) 2430 if (!cpuset_zone_allowed_hardwall(zone, GFP_KERNEL))
2431 continue; 2431 continue;
2432 2432