Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755357AbYBYRcU (ORCPT ); Mon, 25 Feb 2008 12:32:20 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751161AbYBYRcG (ORCPT ); Mon, 25 Feb 2008 12:32:06 -0500 Received: from smtp-out.google.com ([216.239.33.17]:4669 "EHLO smtp-out.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750735AbYBYRcF (ORCPT ); Mon, 25 Feb 2008 12:32:05 -0500 DomainKey-Signature: a=rsa-sha1; s=beta; d=google.com; c=nofws; q=dns; h=received:message-id:date:from:to:subject:cc:in-reply-to: mime-version:content-type:content-transfer-encoding: content-disposition:references; b=tg64XJ3glFUQfpygZkbZyOUGkjIjrLmzH0IlMXAIrpJYX/KjOMM+h8YI7Nq9sjE7v HEmVuaGHn05Nk+u3g2zwA== Message-ID: <6599ad830802250932s5eaa3bcchbfc49fe0e76d3f7d@mail.gmail.com> Date: Mon, 25 Feb 2008 09:32:00 -0800 From: "Paul Menage" To: balbir@linux.vnet.ibm.com Subject: Re: [PATCH] Memory Resource Controller Add Boot Option Cc: "Andrew Morton" , "Hugh Dickins" , "Sudhir Kumar" , "YAMAMOTO Takashi" , lizf@cn.fujitsu.com, linux-kernel@vger.kernel.org, taka@valinux.co.jp, linux-mm@kvack.org, "David Rientjes" , "Pavel Emelianov" , "KAMEZAWA Hiroyuki" In-Reply-To: <47C2F86A.9010709@linux.vnet.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20080225115509.23920.66231.sendpatchset@localhost.localdomain> <20080225115550.23920.43199.sendpatchset@localhost.localdomain> <6599ad830802250816m1f83dbeekbe919a60d4b51157@mail.gmail.com> <47C2F86A.9010709@linux.vnet.ibm.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 844 Lines: 22 On Mon, Feb 25, 2008 at 9:18 AM, Balbir Singh wrote: > > I thought about it, but it did not work out all that well. The reason being, > that the memory controller is called in from places besides cgroup. > mem_cgroup_charge_common() for example is called from several places in mm. > Calling into cgroups to check, enabled/disabled did not seem right. You wouldn't need to call into cgroups - if it's a flag in the subsys object (which is defined in memcontrol.c) you'd just say if (mem_cgroup_subsys.disabled) { ... } I'll send out a prototype for comment. Paul -- 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/