All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hiroyuki Kamezawa <kamezawa.hiroyuki@gmail.com>
To: balbir@linux.vnet.ibm.com
Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>,
	"linux-mm@kvack.org" <linux-mm@kvack.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"nishimura@mxp.nes.nec.co.jp" <nishimura@mxp.nes.nec.co.jp>,
	"akpm@linux-foundation.org" <akpm@linux-foundation.org>
Subject: Re: [PATCH][-mm] memcg : memory cgroup cpu hotplug support update.
Date: Fri, 17 Sep 2010 20:49:09 +0900	[thread overview]
Message-ID: <AANLkTikWqPf_SfYn7fzL7ROGqCY=ZZR5mUzr7sah+TOd@mail.gmail.com> (raw)
In-Reply-To: <20100917063537.GA4534@balbir.in.ibm.com>

2010/9/17 Balbir Singh <balbir@linux.vnet.ibm.com>:
> * KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> [2010-09-16 16:17:27]:
>
>> On Thu, 16 Sep 2010 15:22:04 +0900
>> KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> wrote:
>>
>> > This naming is from mem_cgroup_walk_tree(). Now we have
>> >
>> >   mem_cgroup_walk_tree();
>> >   mem_cgroup_walk_all();
>> >
>> > Rename both ? But it should be in separated patch.
>> >
>>
>> Considering a bit ...but..
>>
>> #define for_each_mem_cgroup(mem) \
>>       for (mem = mem_cgroup_get_first(); \
>>            mem; \
>>            mem = mem_cgroup_get_next(mem);) \
>>
>> seems to need some helper functions. I'll consider about this clean up
>> but it requires some amount of patch because css_get()/css_put()/rcu...etc..
>> are problematic.
>>
>
> Why does this need to be a macro (I know we use this for lists and
> other places), assuming for now we don't use the iterator pattern, we
> can rename mem_cgroup_walk_all() to for_each_mem_cgroup().
>

When I see for_each in the kernel source, I expect iterator and macro.
When I see "walk" in the kernel source, I expect callback and visit function.

Thanks,
-Kame

WARNING: multiple messages have this Message-ID (diff)
From: Hiroyuki Kamezawa <kamezawa.hiroyuki@gmail.com>
To: balbir@linux.vnet.ibm.com
Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>,
	"linux-mm@kvack.org" <linux-mm@kvack.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"nishimura@mxp.nes.nec.co.jp" <nishimura@mxp.nes.nec.co.jp>,
	"akpm@linux-foundation.org" <akpm@linux-foundation.org>
Subject: Re: [PATCH][-mm] memcg : memory cgroup cpu hotplug support update.
Date: Fri, 17 Sep 2010 20:49:09 +0900	[thread overview]
Message-ID: <AANLkTikWqPf_SfYn7fzL7ROGqCY=ZZR5mUzr7sah+TOd@mail.gmail.com> (raw)
In-Reply-To: <20100917063537.GA4534@balbir.in.ibm.com>

2010/9/17 Balbir Singh <balbir@linux.vnet.ibm.com>:
> * KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> [2010-09-16 16:17:27]:
>
>> On Thu, 16 Sep 2010 15:22:04 +0900
>> KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> wrote:
>>
>> > This naming is from mem_cgroup_walk_tree(). Now we have
>> >
>> >   mem_cgroup_walk_tree();
>> >   mem_cgroup_walk_all();
>> >
>> > Rename both ? But it should be in separated patch.
>> >
>>
>> Considering a bit ...but..
>>
>> #define for_each_mem_cgroup(mem) \
>>       for (mem = mem_cgroup_get_first(); \
>>            mem; \
>>            mem = mem_cgroup_get_next(mem);) \
>>
>> seems to need some helper functions. I'll consider about this clean up
>> but it requires some amount of patch because css_get()/css_put()/rcu...etc..
>> are problematic.
>>
>
> Why does this need to be a macro (I know we use this for lists and
> other places), assuming for now we don't use the iterator pattern, we
> can rename mem_cgroup_walk_all() to for_each_mem_cgroup().
>

When I see for_each in the kernel source, I expect iterator and macro.
When I see "walk" in the kernel source, I expect callback and visit function.

Thanks,
-Kame

--
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:[~2010-09-17 11:49 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-16  5:46 [PATCH][-mm] memcg : memory cgroup cpu hotplug support update KAMEZAWA Hiroyuki
2010-09-16  5:46 ` KAMEZAWA Hiroyuki
2010-09-16  6:21 ` Balbir Singh
2010-09-16  6:21   ` Balbir Singh
2010-09-16  6:22   ` KAMEZAWA Hiroyuki
2010-09-16  6:22     ` KAMEZAWA Hiroyuki
2010-09-16  7:17     ` KAMEZAWA Hiroyuki
2010-09-16  7:17       ` KAMEZAWA Hiroyuki
2010-09-16  7:28       ` KAMEZAWA Hiroyuki
2010-09-16  7:28         ` KAMEZAWA Hiroyuki
2010-09-17  6:35       ` Balbir Singh
2010-09-17  6:35         ` Balbir Singh
2010-09-17 11:49         ` Hiroyuki Kamezawa [this message]
2010-09-17 11:49           ` Hiroyuki Kamezawa
2010-09-20  7:54           ` Balbir Singh
2010-09-20  7:54             ` Balbir Singh
2010-09-16 20:14 ` Andrew Morton
2010-09-16 20:14   ` Andrew Morton
2010-09-17  6:32   ` Balbir Singh
2010-09-17  6:32     ` Balbir Singh
2010-09-17 11:47   ` Hiroyuki Kamezawa
2010-09-17 11:47     ` Hiroyuki Kamezawa

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='AANLkTikWqPf_SfYn7fzL7ROGqCY=ZZR5mUzr7sah+TOd@mail.gmail.com' \
    --to=kamezawa.hiroyuki@gmail.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=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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.