Messages in this thread | | | Date | Fri, 8 May 2009 20:16:25 +0530 | From | Balbir Singh <> | Subject | Re: [PATCH 1/2] add mem cgroup is activated check |
| |
* KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> [2009-05-08 14:07:13]:
> From: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> > > There is a function "mem_cgroup_disabled()" which returns > - memcg is configured ? > - disabled by boot option ? > This is check is useful to confirm whether we have to call memcg's hook or not. > > But, even when memcg is configured (and not disabled), it's not really used > until mounted. This patch adds mem_cgroup_activated() to check memcg is > mounted or not at least once. > (Will be used in later patch.) > > IIUC, only very careful users set boot option of memcg to be disabled and > most of people will not be aware of that memcg is enabled at default. > So, if memcg wants to affect to global VM behavior or to add some overheads, > there are cases that this check is better than mem_cgroup_disabled(). >
Agreed
> > Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> Acked-by: Balbir Singh <balbir@linux.vnet.ibm.com>
-- Balbir
| |