Messages in this thread | | | Date | Fri, 21 Nov 2008 09:59:05 -0800 | Subject | Re: [PATCH] cgroups: add lock for child->cgroups in cgroup_post_fork() | From | Paul Menage <> |
| |
On Fri, Nov 21, 2008 at 12:49 AM, Lai Jiangshan <laijs@cn.fujitsu.com> wrote: > when cgroup_post_fork() called, child is seen by find_task_by_vpid(), > so child->cgroups maybe be changed, It'll incorrect. > > child->cgroups<old>'s refcnt is decreased > child->cgroups<new>'s refcnt is increased > but child->cg_list is added to child->cgroups<old>'s list. > > Signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com>
Reviewed-by: Paul Menage <menage@google.com>
Yeah, I guess this was a place where I equated "holding css_set_lock" with "cgroups can't change". But in fact they can partially change.
Paul
| |