Thread (6 messages) 6 messages, 2 authors, 2014-09-17

Re: [PATCH 4/4] cgroup: reuse css->destroy_work for release agent

From: Tejun Heo <hidden>
Date: 2014-09-17 21:37:42
Also in: lkml

On Wed, Sep 17, 2014 at 06:20:29PM +0800, Li Zefan wrote:
Currently we use a global work to schedule release agent on removable
cgroups. We can change to reuse css->destroy_work to do this, which
saves a few lines of code.

Signed-off-by: Zefan Li <redacted>
...
quoted hunk ↗ jump to hunk
@@ -1587,6 +1581,7 @@ static void init_cgroup_housekeeping(struct cgroup *cgrp)
 		INIT_LIST_HEAD(&cgrp->e_csets[ssid]);
 
 	init_waitqueue_head(&cgrp->offline_waitq);
+	INIT_WORK(&cgrp->self.destroy_work, cgroup_release_agent);
It's weird to overload destroy_work like this as invoking
release_agent isn't necessarily related to destruction.  I like the
change overall but can we please just use a separate work item?

Thanks.

-- 
tejun
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help