Commit 674b745e authored by Ran Tian's avatar Ran Tian Committed by Tejun Heo

cgroup: remove rcu_read_lock()/rcu_read_unlock() in critical section of spin_lock_irq()

spin_lock_irq() already disable preempt, so remove rcu_read_lock().
Signed-off-by: default avatarRan Tian <tianran_trtr@163.com>
Signed-off-by: default avatarTejun Heo <tj@kernel.org>
parent 0a2cafe6
......@@ -2866,14 +2866,12 @@ int cgroup_migrate(struct task_struct *leader, bool threadgroup,
* take an rcu_read_lock.
*/
spin_lock_irq(&css_set_lock);
rcu_read_lock();
task = leader;
do {
cgroup_migrate_add_task(task, mgctx);
if (!threadgroup)
break;
} while_each_thread(leader, task);
rcu_read_unlock();
spin_unlock_irq(&css_set_lock);
return cgroup_migrate_execute(mgctx);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment