[CRIU] [PATCH 10/17] fsnotify: Add fanotify restore

Cyrill Gorcunov gorcunov at openvz.org
Mon Dec 24 08:50:58 EST 2012


On Mon, Dec 24, 2012 at 05:32:12PM +0400, Pavel Emelyanov wrote:
> On 12/11/2012 01:34 AM, Cyrill Gorcunov wrote:
> > 
> > The idea is the same as for inotify -- just open
> > notification descriptor and hook paths on.
> > 
> > Signed-off-by: Cyrill Gorcunov <gorcunov at openvz.org>
> > ---
> >  fsnotify.c | 91 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++--
> >  1 file changed, 89 insertions(+), 2 deletions(-)
> > 
> > +	/*
> > +	 * Note we use OR'ed iwe->wd here, since for fanotify it
> > +	 * provides additional flags for the mark.
> > +	 */
> > +	flags |= iwe->wd;
> 
> I don't understand this. Kernel denies putting any flags but known into
> sys_fanotify_mark.

wd consist of additional flags associated with mark, ie "mflags" field
from kernel output. Unfortunately protobuf doesn't support unions or
names aliasing that's why I've had to re-use wd field.

Or you mean something else here?


More information about the CRIU mailing list