[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20110826131359.096a8131.kamezawa.hiroyu@jp.fujitsu.com>
Date: Fri, 26 Aug 2011 13:13:59 +0900
From: KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com>
To: Tejun Heo <tj@...nel.org>
Cc: rjw@...k.pl, paul@...lmenage.org, lizf@...fujitsu.com,
linux-pm@...ts.linux-foundation.org, linux-kernel@...r.kernel.org,
containers@...ts.linux-foundation.org, fweisbec@...il.com,
matthltc@...ibm.com
Subject: Re: [PATCH 2/6] cgroup: improve old cgroup handling in
cgroup_attach_proc()
On Fri, 26 Aug 2011 00:43:08 +0200
Tejun Heo <tj@...nel.org> wrote:
> cgroup_attach_proc() behaves differently from cgroup_attach_task() in
> the following aspects.
>
> * All hooks are invoked even if no task is actually being moved.
>
> * ->can_attach_task() is called for all tasks in the group whether the
> new cgrp is different from the current cgrp or not; however,
> ->attach_task() is skipped if new equals new. This makes the calls
> asymmetric.
>
> This patch improves old cgroup handling in cgroup_attach_proc() by
> looking up the current cgroup at the head, recording it in the flex
> array along with the task itself, and using it to remove the above two
> differences. This will also ease further changes.
>
> -v2: nr_todo renamed to nr_migrating_tasks as per Paul Menage's
> suggestion.
>
> Signed-off-by: Tejun Heo <tj@...nel.org>
> Acked-by: Paul Menage <paul@...lmenage.org>
> Cc: Li Zefan <lizf@...fujitsu.com>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists