On Tue 03-09-13 17:56:46, Tejun Heo wrote: > Hello, Michal. > > On Fri, Aug 30, 2013 at 01:08:46PM +0200, Michal Hocko wrote: > > On Thu 15-08-13 12:02:26, Tejun Heo wrote: > > [...] > > > @@ -6030,12 +6050,13 @@ static void cgroup_event_ptable_queue_proc(struct file *file, > > > static int cgroup_write_event_control(struct cgroup_subsys_state *css, > > > struct cftype *cft, const char *buffer) > > > { > > > - struct cgroup *cgrp = css->cgroup; > > > + struct mem_cgroup *memcg = mem_cgroup_from_css(css); > > > struct cgroup_event *event; > > > struct cgroup_subsys_state *cfile_css; > > > unsigned int efd, cfd; > > > struct file *efile; > > > struct file *cfile; > > > + const char *name; > > > char *endp; > > > int ret; > > > > AFAICS nothing prevents from registering a new event after css_offline > > is done already which would lead to a mem leak. The we would need to do > > css_tryget somewhere in the beginning. Or is there anything that would > > prevent from that? > > An earlier patch titled "cgroup: make cgroup_event hold onto > cgroup_subsys_state instead of cgroup" updates cgroup_event such that > each cgroup_event acquires a css reference using css_tryget(), so if a > css has already been offlined, no new event will be created. Right you are. Sorry I have missed/forgot about the patch. The patch is ok then and you can add my acked-by. Thanks and sorry about the noise. -- Michal Hocko SUSE Labs _______________________________________________ Containers mailing list Containers@xxxxxxxxxxxxxxxxxxxxxxxxxx https://lists.linuxfoundation.org/mailman/listinfo/containers