linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Li Zefan <lizf@cn.fujitsu.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linux-mm@kvack.org" <linux-mm@kvack.org>,
	"balbir@linux.vnet.ibm.com" <balbir@linux.vnet.ibm.com>,
	"mingo@elte.hu" <mingo@elte.hu>,
	"nishimura@mxp.nes.nec.co.jp" <nishimura@mxp.nes.nec.co.jp>
Subject: Re: [PATCH][BUGFIX] memcg: fix page_cgroup allocation
Date: Wed, 22 Oct 2008 09:42:41 +0800	[thread overview]
Message-ID: <48FE8511.1090903@cn.fujitsu.com> (raw)
In-Reply-To: <20081021183738.d3c995b9.akpm@linux-foundation.org>

>> --- linux-2.6.orig/mm/page_cgroup.c
>> +++ linux-2.6/mm/page_cgroup.c
>> @@ -4,7 +4,12 @@
>>  #include <linux/bit_spinlock.h>
>>  #include <linux/page_cgroup.h>
>>  #include <linux/hash.h>
>> +#include <linux/slab.h>
>>  #include <linux/memory.h>
>> +#include <linux/cgroup.h>
>> +
>> +extern struct cgroup_subsys	mem_cgroup_subsys;
> 
> no no bad! evil! unclean!
> 
> Didn't the linux/cgroup.h -> linux/cgroup_subsys..h inclusion already
> declare this for us?
> 

Yes, I think just include <linux/cgroup.h> is enough.

#define SUBSYS(_x) extern struct cgroup_subsys _x ## _subsys;
#include <linux/cgroup_subsys.h>
#undef SUBSYS

and will be expanded to:

extern struct cgroup_subsys cpu_subsys;
extern struct cgroup_subsys cpuset_subsys;
extern struct cgroup_subsys memory_cgroup_subsys;
...

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  reply	other threads:[~2008-10-22  1:42 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-22  1:24 KAMEZAWA Hiroyuki
2008-10-22  1:37 ` Andrew Morton
2008-10-22  1:42   ` Li Zefan [this message]
2008-10-22  1:42   ` KAMEZAWA Hiroyuki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=48FE8511.1090903@cn.fujitsu.com \
    --to=lizf@cn.fujitsu.com \
    --cc=akpm@linux-foundation.org \
    --cc=balbir@linux.vnet.ibm.com \
    --cc=kamezawa.hiroyu@jp.fujitsu.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mingo@elte.hu \
    --cc=nishimura@mxp.nes.nec.co.jp \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox