On Fri, Jul 15, 2016 at 06:35:51AM -0500, Eric W. Biederman wrote: > > In most code paths involving cgroup migration cgroup_threadgroup_rwsem > is taken. There are two exceptions: > > - remove_tasks_in_empty_cpuset calls cgroup_transfer_tasks > - vhost_attach_cgroups_work calls cgroup_attach_task_all > > With cgroup_threadgroup_rwsem held it is guaranteed that cgroup_post_fork > and copy_cgroup_ns will reference the same css_set from the process calling > fork. > > Without such an interlock there process after fork could reference one > css_set from it's new cgroup namespace and another css_set from > task->cgroups, which semantically is nonsensical. > > Cc: stable@xxxxxxxxxxxxxxx > Fixes: a79a908fd2b0 ("cgroup: introduce cgroup namespaces") > Signed-off-by: "Eric W. Biederman" <ebiederm@xxxxxxxxxxxx> Applied 1-2 to cgroup/for-4.7-fixes. Thanks. -- tejun -- To unsubscribe from this list: send the line "unsubscribe cgroups" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html