Re: [PATCH -V3 1/1] cgroup: Add inotify event on change tasks file (fork, exit, move pid from file)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, May 04, 2012 at 10:04:12AM -0700, Tejun Heo wrote:
> On Fri, May 04, 2012 at 09:24:40AM +0400, Alexander Nikiforov wrote:
> > Hi Eric,
> > 
> > I had try to implement with FSNOTIFY_EVENT_PATH. But it's pretty
> > hard to obtain struct path without full chain of the sys_open()
> > or may be I don't know some simple way. I'll spend some more time on
> > this, but for now I have no idea how to do it. If you have some
> > please share them.
> 
> Hmm... we have dentry from cfe->dentry and we can either use the first
> vfsmount from sb->s_mounts or all of them (ie. generate event on each
> vfsmount).

	No, you can not.  There are damn good reasons why that list does not
go through a field of struct vfsmount and preventing that kind of idiocy
is pretty high on the list.

	Consider that preemptively NAKed.  Eric, would you mind explaining
WTF would fsnotify *do* with vfsmount(s) here, seeing that they might very
well be not mounted in anyone's namespace?  And as for generating an event
for each, they might appear and disappear at zero notice.

	*notify: Racy By Design...
--
To unsubscribe from this list: send the line "unsubscribe cgroups" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]     [Monitors]

  Powered by Linux