[CRIU] [PATCH] fsnotify: Proceed dumping even if queue has data
Andrew Vagin
avagin at parallels.com
Fri Sep 5 04:16:21 PDT 2014
On Fri, Sep 05, 2014 at 03:13:43PM +0400, Cyrill Gorcunov wrote:
> On Fri, Sep 05, 2014 at 02:40:35PM +0400, Andrew Vagin wrote:
> > > + else if (ret > 0)
> > > + pr_warn("The 0x%08x inotify has queued events\n", id);
> >
> > We should say that all this events will be dropped.
>
> Thanks, attached.
Acked-by: Andrew Vagin <avagin at parallels.com>
> From 2ff5bdbd6e5e24f7cacfcbf6c4f5ed4a67893004 Mon Sep 17 00:00:00 2001
> From: Cyrill Gorcunov <gorcunov at openvz.org>
> Date: Fri, 5 Sep 2014 14:09:27 +0400
> Subject: [PATCH] fsnotify: Proceed dumping even if queue has data
>
> It turns out that we can't be too strict about
> queued events -- criu itself generates a number
> of them and there is no clear way yet how to resolve
> this situation. So defer "strict" mode for now
> but print a warning.
>
> Signed-off-by: Cyrill Gorcunov <gorcunov at openvz.org>
> ---
> fsnotify.c | 12 ++++--------
> 1 file changed, 4 insertions(+), 8 deletions(-)
>
> diff --git a/fsnotify.c b/fsnotify.c
> index 33563eba800b..ea58e8aa9d7b 100644
> --- a/fsnotify.c
> +++ b/fsnotify.c
> @@ -236,10 +236,8 @@ static int dump_one_inotify(int lfd, u32 id, const struct fd_parms *p)
> ret = fd_has_data(lfd);
> if (ret < 0)
> return -1;
> - else if (ret > 0) {
> - pr_err("The %d inotify has queued events\n", id);
> - return -1;
> - }
> + else if (ret > 0)
> + pr_warn("The 0x%08x inotify events will be dropped\n", id);
>
> ie.id = id;
> ie.flags = p->flags;
> @@ -348,10 +346,8 @@ static int dump_one_fanotify(int lfd, u32 id, const struct fd_parms *p)
> ret = fd_has_data(lfd);
> if (ret < 0)
> return -1;
> - else if (ret > 0) {
> - pr_err("The %d inotify has queued events\n", id);
> - return -1;
> - }
> + else if (ret > 0)
> + pr_warn("The 0x%08x fanotify events will be dropped\n", id);
> ret = -1;
>
> fe.id = id;
> --
> 1.9.3
>
More information about the CRIU
mailing list