The patch titled cpuset: hold callback_mutex in cpuset_clone() has been added to the -mm tree. Its filename is cpuset-hold-callback_mutex-in-cpuset_clone.patch Before you just go and hit "reply", please: a) Consider who else should be cc'ed b) Prefer to cc a suitable mailing list as well c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's *** Remember to use Documentation/SubmitChecklist when testing your code *** See http://userweb.kernel.org/~akpm/stuff/added-to-mm.txt to find out what to do about this The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/ ------------------------------------------------------ Subject: cpuset: hold callback_mutex in cpuset_clone() From: Li Zefan <lizf@xxxxxxxxxxxxxx> Chaning cpuset->mems/cpuset->cpus should be protected under callback_mutex. cpuset_clone() doesn't follow this rule. It's ok because it's called when creating and initializing a cgroup, but we'd better hold the lock to avoid subtil break in the future. Signed-off-by: Li Zefan <lizf@xxxxxxxxxxxxxx> Cc: Paul Menage <menage@xxxxxxxxxx> Cc: David Rientjes <rientjes@xxxxxxxxxx> Cc: Miao Xie <miaox@xxxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- kernel/cpuset.c | 2 ++ 1 file changed, 2 insertions(+) diff -puN kernel/cpuset.c~cpuset-hold-callback_mutex-in-cpuset_clone kernel/cpuset.c --- a/kernel/cpuset.c~cpuset-hold-callback_mutex-in-cpuset_clone +++ a/kernel/cpuset.c @@ -1840,8 +1840,10 @@ static void cpuset_post_clone(struct cgr cs = cgroup_cs(cgroup); parent_cs = cgroup_cs(parent); + mutex_lock(&callback_mutex); cs->mems_allowed = parent_cs->mems_allowed; cpumask_copy(cs->cpus_allowed, parent_cs->cpus_allowed); + mutex_unlock(&callback_mutex); return; } _ Patches currently in -mm which might be from lizf@xxxxxxxxxxxxxx are mm-notifier_from_errno-cleanup.patch cgroup-remove-the-ns_cgroup.patch cpuset-remove-unneeded-nodemask_alloc-in-cpuset_sprintf_memlist.patch cpuset-remove-unneeded-nodemask_alloc-in-cpuset_attch.patch cpuset-fix-unchecked-calls-to-nodemask_alloc.patch cpuset-fix-unchecked-calls-to-nodemask_alloc-fix.patch cpuset-hold-callback_mutex-in-cpuset_clone.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html