Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758222Ab1EMJXO (ORCPT ); Fri, 13 May 2011 05:23:14 -0400 Received: from cantor.suse.de ([195.135.220.2]:35502 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757935Ab1EMJXM (ORCPT ); Fri, 13 May 2011 05:23:12 -0400 Date: Fri, 13 May 2011 11:23:09 +0200 From: Michal Hocko To: Johannes Weiner Cc: KAMEZAWA Hiroyuki , Daisuke Nishimura , Balbir Singh , Ying Han , Andrew Morton , Rik van Riel , Minchan Kim , KOSAKI Motohiro , Mel Gorman , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [rfc patch 1/6] memcg: remove unused retry signal from reclaim Message-ID: <20110513092308.GC25304@tiehlicka.suse.cz> References: <1305212038-15445-1-git-send-email-hannes@cmpxchg.org> <1305212038-15445-2-git-send-email-hannes@cmpxchg.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1305212038-15445-2-git-send-email-hannes@cmpxchg.org> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1430 Lines: 49 On Thu 12-05-11 16:53:53, Johannes Weiner wrote: > 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 Makes sense Reviewed-by: Michal Hocko > --- > mm/memcontrol.c | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > diff --git a/mm/memcontrol.c b/mm/memcontrol.c > index 010f916..bf5ab87 100644 > --- a/mm/memcontrol.c > +++ b/mm/memcontrol.c > @@ -1503,7 +1503,7 @@ static int mem_cgroup_hierarchical_reclaim(struct mem_cgroup *root_mem, > if (!res_counter_soft_limit_excess(&root_mem->res)) > return total; > } else if (mem_cgroup_margin(root_mem)) > - return 1 + total; > + return total; > } > return total; > } > -- > 1.7.5.1 > -- Michal Hocko SUSE Labs SUSE LINUX s.r.o. Lihovarska 1060/12 190 00 Praha 9 Czech Republic -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/