[CRIU] Re: [PATCH 3/4] inotify: Add checkpoint/restore
Cyrill Gorcunov
gorcunov at openvz.org
Wed Apr 11 14:55:44 EDT 2012
On Wed, Apr 11, 2012 at 10:50:36PM +0400, Pavel Emelyanov wrote:
> Pre-question. Where are the required kernel patches?
>
> > +struct inotify_file_entry {
> > + u32 id;
> > + u16 flags;
> > + u64 i_ino;
> > + u32 mask;
> > + u32 s_dev;
> > + u32 r_dev;
> > + u32 wd;
> > + fh_t f_handle;
> > +} __packed;
> > +
>
> I asked to put two image entries in this file. One for
> inotify fd itself and an array of watches behind. Plz,
> do it right now, don't postpone. Even if the former image
> is one field (an ID) only. Flags and fownres can come later.
>
OK
> int dump_anon_inode()
> {
> readlink()
> if (strcmp(buf, "inotify")) {
> p->type = FDINFO_INOTIFY;
> return dump_gen_file();
> }
>
> ...
> }
>
OK
> > +static char *get_mnt_root(unsigned int s_dev,
> > + struct proc_mountinfo *mntinfo,
> > + int nr_mntinfo)
> > +{
>
> I asked to put this in another .c file. The util.c one is OK for now.
I thought to move it to mount.c or something, since util.c is already
oveloaded left and right, but then desided to not start doing that
since it's used in inotify only at moment.
But ok, I'll extract this helper into util.c.
Cyrill
More information about the CRIU
mailing list