aboutsummaryrefslogtreecommitdiff
path: root/kernel/cgroup.c
diff options
context:
space:
mode:
authorLi Zefan <lizefan@huawei.com>2013-03-12 15:35:59 -0700
committerTejun Heo <tj@kernel.org>2013-03-12 15:35:59 -0700
commitd7eeac1913ff86a17f891cb4b73f03d4b94907d0 (patch)
tree1e44fde86b626dbeb7c27f007eeebce7d47ef206 /kernel/cgroup.c
parent6dc01181eac16192dc4a5d1b310b78e2e97c003c (diff)
downloadlinaro-lsk-d7eeac1913ff86a17f891cb4b73f03d4b94907d0.tar.gz
cgroup: hold cgroup_mutex before calling css_offline()
cpuset no longer nests cgroup_mutex inside cpu_hotplug lock, so we don't have to release cgroup_mutex before calling css_offline(). Signed-off-by: Li Zefan <lizefan@huawei.com> Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'kernel/cgroup.c')
-rw-r--r--kernel/cgroup.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/kernel/cgroup.c b/kernel/cgroup.c
index fd0b056d8da..49297cbc134 100644
--- a/kernel/cgroup.c
+++ b/kernel/cgroup.c
@@ -4169,17 +4169,8 @@ static void offline_css(struct cgroup_subsys *ss, struct cgroup *cgrp)
if (!(css->flags & CSS_ONLINE))
return;
- /*
- * css_offline() should be called with cgroup_mutex unlocked. See
- * 3fa59dfbc3 ("cgroup: fix potential deadlock in pre_destroy") for
- * details. This temporary unlocking should go away once
- * cgroup_mutex is unexported from controllers.
- */
- if (ss->css_offline) {
- mutex_unlock(&cgroup_mutex);
+ if (ss->css_offline)
ss->css_offline(cgrp);
- mutex_lock(&cgroup_mutex);
- }
cgrp->subsys[ss->subsys_id]->flags &= ~CSS_ONLINE;
}