From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751691Ab2KCHAM (ORCPT ); Sat, 3 Nov 2012 03:00:12 -0400 Received: from mail-ee0-f46.google.com ([74.125.83.46]:46966 "EHLO mail-ee0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750916Ab2KCHAJ (ORCPT ); Sat, 3 Nov 2012 03:00:09 -0400 Date: Sat, 3 Nov 2012 08:00:06 +0100 From: Michal Hocko To: Hugh Dickins Cc: Andrew Morton , Johannes Weiner , Wen Congyang , linux-kernel@vger.kernel.org, cgroups@vger.kernel.org, linux-mm@kvack.org, Jiang Liu , bsingharora@gmail.com, KAMEZAWA Hiroyuki , Konstantin Khlebnikov , paul.gortmaker@windriver.com, Tang Chen Subject: Re: [PATCH] memcg: fix hotplugged memory zone oops Message-ID: <20121103070006.GA12038@dhcp22.suse.cz> References: <505187D4.7070404@cn.fujitsu.com> <20120913205935.GK1560@cmpxchg.org> <507CF789.6050307@cn.fujitsu.com> <20121018220306.GA1739@cmpxchg.org> <20121102102159.GA24073@dhcp22.suse.cz> <20121102105420.GB24073@dhcp22.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: 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 On Fri 02-11-12 16:37:37, Hugh Dickins wrote: > On Fri, 2 Nov 2012, Michal Hocko wrote: > > On Fri 02-11-12 11:21:59, Michal Hocko wrote: > > > On Thu 01-11-12 18:28:02, Hugh Dickins wrote: > > [...] > > > > And I forgot to mention that the following hunk will clash with > > "memcg: Simplify mem_cgroup_force_empty_list error handling" which is in > > linux-next already (via Tejun's tree). > > Oh, via Tejun's tree. Right, when I checked mmotm there was no problem. Yeah, whole that thing goes through Tejun's tree because there are many follow up clean ups depending on that change. > > Would it be easier to split the patch into the real fix and the hunk > > bellow? That one doesn't have to go into stable anyway and we would save > > some merging conflicts. The updated fix on top of -mm tree is bellow for > > your convinience. > > I'd prefer to leave it as one patch, so even the "future proof" part > of the fix goes into 3.7 and stable. But your point is that you have > already seen the future, and it forks in a slightly different direction! > > Well, I don't want to be obstructive, but it doesn't look difficult > to resolve. True. > Perhaps if I hold off on splitting them, and see if akpm barks at me > or not :) > > Hugh > > > > > /** > > > > @@ -3688,17 +3712,17 @@ unsigned long mem_cgroup_soft_limit_recl > > > > static bool mem_cgroup_force_empty_list(struct mem_cgroup *memcg, > > > > int node, int zid, enum lru_list lru) > > > > { > > > > - struct mem_cgroup_per_zone *mz; > > > > + struct lruvec *lruvec; > > > > unsigned long flags, loop; > > > > struct list_head *list; > > > > struct page *busy; > > > > struct zone *zone; > > > > > > > > zone = &NODE_DATA(node)->node_zones[zid]; > > > > - mz = mem_cgroup_zoneinfo(memcg, node, zid); > > > > - list = &mz->lruvec.lists[lru]; > > > > + lruvec = mem_cgroup_zone_lruvec(zone, memcg); > > > > + list = &lruvec->lists[lru]; > > > > > > > > - loop = mz->lru_size[lru]; > > > > + loop = mem_cgroup_get_lru_size(lruvec, lru); > > > > /* give some margin against EBUSY etc...*/ > > > > loop += 256; > > > > busy = NULL; -- Michal Hocko SUSE Labs