> @@ -5046,8 +5049,8 @@ static const struct file_operations proc > void cgroup_fork(struct task_struct *child) > { > task_lock(current); > + get_css_set(task_css_set(current)); > child->cgroups = current->cgroups; While we use RCU_INIT_POINTER() in cgroup_exit(), we don't need to use it here? > - get_css_set(child->cgroups); > task_unlock(current); > INIT_LIST_HEAD(&child->cg_list); > } > @@ -5081,7 +5084,7 @@ void cgroup_post_fork(struct task_struct > write_lock(&css_set_lock); > task_lock(child); > if (list_empty(&child->cg_list)) > - list_add(&child->cg_list, &child->cgroups->tasks); > + list_add(&child->cg_list, &task_css_set(child)->tasks); > task_unlock(child); > write_unlock(&css_set_lock); > } > @@ -5163,8 +5166,8 @@ void cgroup_exit(struct task_struct *tsk > > /* Reassign the task to the init_css_set. */ > task_lock(tsk); > - cset = tsk->cgroups; > - tsk->cgroups = &init_css_set; > + cset = task_css_set(tsk); > + RCU_INIT_POINTER(tsk->cgroups, &init_css_set); > > if (run_callbacks && need_forkexit_callback) { > /* _______________________________________________ Containers mailing list Containers@xxxxxxxxxxxxxxxxxxxxxxxxxx https://lists.linuxfoundation.org/mailman/listinfo/containers