Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750975Ab2HMI55 (ORCPT ); Mon, 13 Aug 2012 04:57:57 -0400 Received: from cantor2.suse.de ([195.135.220.15]:41516 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750834Ab2HMI54 (ORCPT ); Mon, 13 Aug 2012 04:57:56 -0400 Date: Mon, 13 Aug 2012 09:57:49 +0100 From: Mel Gorman To: Glauber Costa Cc: Kamezawa Hiroyuki , linux-kernel@vger.kernel.org, linux-mm@kvack.org, cgroups@vger.kernel.org, devel@openvz.org, Michal Hocko , Johannes Weiner , Andrew Morton , Christoph Lameter , David Rientjes , Pekka Enberg , Pekka Enberg , Suleiman Souhlal Subject: Re: [PATCH v2 07/11] mm: Allocate kernel pages to the right memcg Message-ID: <20120813085749.GB4177@suse.de> References: <1344517279-30646-1-git-send-email-glommer@parallels.com> <1344517279-30646-8-git-send-email-glommer@parallels.com> <502545D2.80708@jp.fujitsu.com> <5028B4DA.6000507@parallels.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: <5028B4DA.6000507@parallels.com> 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: 1860 Lines: 49 On Mon, Aug 13, 2012 at 12:03:38PM +0400, Glauber Costa wrote: > On 08/10/2012 09:33 PM, Kamezawa Hiroyuki wrote: > > (2012/08/09 22:01), Glauber Costa wrote: > >> When a process tries to allocate a page with the __GFP_KMEMCG flag, the > >> page allocator will call the corresponding memcg functions to validate > >> the allocation. Tasks in the root memcg can always proceed. > >> > >> To avoid adding markers to the page - and a kmem flag that would > >> necessarily follow, as much as doing page_cgroup lookups for no reason, > >> whoever is marking its allocations with __GFP_KMEMCG flag is responsible > >> for telling the page allocator that this is such an allocation at > >> free_pages() time. This is done by the invocation of > >> __free_accounted_pages() and free_accounted_pages(). > >> > >> Signed-off-by: Glauber Costa > >> CC: Christoph Lameter > >> CC: Pekka Enberg > >> CC: Michal Hocko > >> CC: Kamezawa Hiroyuki > >> CC: Johannes Weiner > >> CC: Suleiman Souhlal > > > > Ah, ok. free_accounted_page() seems good. > > > > Acked-by: KAMEZAWA Hiroyuki > > > > I myself is okay with this. But... > > > > Because you add a new hook to alloc_pages(), please get Ack from Mel > > before requesting merge. > > > > Thanks, > > -Kame > > Absolutely. > > Mel, would you mind taking a look at this series and commenting on this? > It'll take me a few days but I'll get around to it. -- Mel Gorman SUSE Labs -- 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/