From 971ff49355387fef41d1327434d8939721a4eb35 Mon Sep 17 00:00:00 2001 From: Zefan Li Date: Thu, 18 Sep 2014 16:06:19 +0800 Subject: cgroup: use a per-cgroup work for release agent Instead of using a global work to schedule release agent on removable cgroups, we change to use a per-cgroup work to do this, which makes the code much simpler. v2: use a dedicated work instead of reusing css->destroy_work. (Tejun) Signed-off-by: Zefan Li Signed-off-by: Tejun Heo --- include/linux/cgroup.h | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'include/linux/cgroup.h') diff --git a/include/linux/cgroup.h b/include/linux/cgroup.h index f7898e0bce1e..51958d0fb88f 100644 --- a/include/linux/cgroup.h +++ b/include/linux/cgroup.h @@ -233,13 +233,6 @@ struct cgroup { */ struct list_head e_csets[CGROUP_SUBSYS_COUNT]; - /* - * Linked list running through all cgroups that can - * potentially be reaped by the release agent. Protected by - * release_list_lock - */ - struct list_head release_list; - /* * list of pidlists, up to two for each namespace (one for procs, one * for tasks); created on demand. @@ -249,6 +242,9 @@ struct cgroup { /* used to wait for offlining of csses */ wait_queue_head_t offline_waitq; + + /* used to schedule release agent */ + struct work_struct release_agent_work; }; #define MAX_CGROUP_ROOT_NAMELEN 64 -- cgit v1.2.3