Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754175Ab2B2FmK (ORCPT ); Wed, 29 Feb 2012 00:42:10 -0500 Received: from fgwmail6.fujitsu.co.jp ([192.51.44.36]:41091 "EHLO fgwmail6.fujitsu.co.jp" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753075Ab2B2FmI (ORCPT ); Wed, 29 Feb 2012 00:42:08 -0500 X-SecurityPolicyCheck-FJ: OK by FujitsuOutboundMailChecker v1.3.1 Date: Wed, 29 Feb 2012 14:40:37 +0900 From: KAMEZAWA Hiroyuki To: Hugh Dickins Cc: Andrew Morton , Johannes Weiner , Konstantin Khlebnikov , linux-kernel@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCH next] memcg: remove PCG_FILE_MAPPED fix cosmetic fix Message-Id: <20120229144037.19ec6efa.kamezawa.hiroyu@jp.fujitsu.com> In-Reply-To: References: Organization: FUJITSU Co. LTD. X-Mailer: Sylpheed 3.1.1 (GTK+ 2.10.14; i686-pc-mingw32) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1229 Lines: 36 On Tue, 28 Feb 2012 21:28:40 -0800 (PST) Hugh Dickins wrote: > mem_cgroup_move_account() begins with "anon = PageAnon(page)", and > then anon is used thereafter: testing PageAnon(page) in the middle > makes the reader wonder if there's some race to guard against - no. > > Signed-off-by: Hugh Dickins Thanks. Acked-by: KAMEZAWA Hiroyuki > --- > > mm/memcontrol.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > --- 3.3-rc5-next/mm/memcontrol.c 2012-02-27 09:56:59.072001463 -0800 > +++ linux/mm/memcontrol.c 2012-02-28 20:45:43.488100423 -0800 > @@ -2560,7 +2560,7 @@ static int mem_cgroup_move_account(struc > > move_lock_mem_cgroup(from, &flags); > > - if (!PageAnon(page) && page_mapped(page)) { > + if (!anon && page_mapped(page)) { > /* Update mapped_file data for mem_cgroup */ > preempt_disable(); > __this_cpu_dec(from->stat->count[MEM_CGROUP_STAT_FILE_MAPPED]); > -- 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/