aboutsummaryrefslogtreecommitdiffstats
path: root/mm/memcontrol.c
diff options
context:
space:
mode:
authorJohannes Weiner <hannes@cmpxchg.org>2011-05-26 19:25:35 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2011-05-26 20:12:35 -0400
commit4fd14ebf6e3b66423dfac2bc9defda7b83ee07b3 (patch)
tree38fb451bf2e480091bf88540139378b68cdd2494 /mm/memcontrol.c
parent246e87a9393448c20873bc5dee64be68ed559e24 (diff)
memcg: remove unused retry signal from reclaim
If the memcg reclaim code detects the target memcg below its limit it exits and returns a guaranteed non-zero value so that the charge is retried. Nowadays, the charge side checks the memcg limit itself and does not rely on this non-zero return value trick. This patch removes it. The reclaim code will now always return the true number of pages it reclaimed on its own. Signed-off-by: Johannes Weiner <hannes@cmpxchg.org> Acked-by: Rik van Riel<riel@redhat.com> Acked-by: Ying Han<yinghan@google.com> Acked-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> Reviewed-by: Michal Hocko <mhocko@suse.cz> Cc: Balbir Singh <balbir@linux.vnet.ibm.com> Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Cc: Mel Gorman <mgorman@suse.de> Cc: Daisuke Nishimura <nishimura@mxp.nes.nec.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/memcontrol.c')
-rw-r--r--mm/memcontrol.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/memcontrol.c b/mm/memcontrol.c
index 1520efd1c7c4..bcb0a0bee1fc 100644
--- a/mm/memcontrol.c
+++ b/mm/memcontrol.c
@@ -1596,7 +1596,7 @@ static int mem_cgroup_hierarchical_reclaim(struct mem_cgroup *root_mem,
1596 if (!res_counter_soft_limit_excess(&root_mem->res)) 1596 if (!res_counter_soft_limit_excess(&root_mem->res))
1597 return total; 1597 return total;
1598 } else if (mem_cgroup_margin(root_mem)) 1598 } else if (mem_cgroup_margin(root_mem))
1599 return 1 + total; 1599 return total;
1600 } 1600 }
1601 return total; 1601 return total;
1602} 1602}