Commit 659db078 authored by Xiu Jianfeng's avatar Xiu Jianfeng Committed by Tejun Heo

cgroup: Update out-of-date comment in cgroup_migrate()

Commit 674b745e ("cgroup: remove rcu_read_lock()/rcu_read_unlock()
in critical section of spin_lock_irq()") has removed the rcu_read_lock,
which makes the comment out-of-date, so update it.

tj: Updated the comment a bit.
Signed-off-by: default avatarXiu Jianfeng <xiujianfeng@huawei.com>
Signed-off-by: default avatarTejun Heo <tj@kernel.org>
parent c33080cd
...@@ -2872,9 +2872,9 @@ int cgroup_migrate(struct task_struct *leader, bool threadgroup, ...@@ -2872,9 +2872,9 @@ int cgroup_migrate(struct task_struct *leader, bool threadgroup,
struct task_struct *task; struct task_struct *task;
/* /*
* Prevent freeing of tasks while we take a snapshot. Tasks that are * The following thread iteration should be inside an RCU critical
* already PF_EXITING could be freed from underneath us unless we * section to prevent tasks from being freed while taking the snapshot.
* take an rcu_read_lock. * spin_lock_irq() implies RCU critical section here.
*/ */
spin_lock_irq(&css_set_lock); spin_lock_irq(&css_set_lock);
task = leader; task = leader;
......
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