All of lore.kernel.org
 help / color / mirror / Atom feed
From: Amir Goldstein <amir73il@gmail.com>
To: Trond Myklebust <trond.myklebust@hammerspace.com>,
	Anna Schumaker <Anna.Schumaker@netapp.com>,
	"J. Bruce Fields" <bfields@fieldses.org>
Cc: David Sterba <dsterba@suse.com>, Christoph Hellwig <hch@lst.de>,
	Joel Becker <jlbec@evilplan.org>,
	John Johansen <john.johansen@canonical.com>,
	Steven Rostedt <rostedt@goodmis.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Al Viro <viro@zeniv.linux.org.uk>,
	linux-fsdevel <linux-fsdevel@vger.kernel.org>,
	Jan Kara <jack@suse.cz>
Subject: Re: [PATCH v3 03/10] rpc_pipefs: call fsnotify_{unlink,rmdir}() hooks
Date: Thu, 30 May 2019 08:43:43 +0300	[thread overview]
Message-ID: <CAOQ4uxh4q_ArSROkdUxFW9oezEYc4qqJNFS8oOULsVhx6-1Lig@mail.gmail.com> (raw)
In-Reply-To: <20190526143411.11244-4-amir73il@gmail.com>

Hi Trond,Anna,Bruce,

Seems that rpc_pipefs is co-maintained by client and server trees, so
not sure who is the best to ask for an ack.
We need to add those explicit fsnotify hooks to match the existing
fsnotify_create/mkdir hooks, because
the hook embedded inside d_delete() is going away [1].

Thanks,
Amir.

[1] https://lore.kernel.org/linux-fsdevel/20190526143411.11244-1-amir73il@gmail.com/

On Sun, May 26, 2019 at 5:34 PM Amir Goldstein <amir73il@gmail.com> wrote:
>
> This will allow generating fsnotify delete events after the
> fsnotify_nameremove() hook is removed from d_delete().
>
> Cc: Trond Myklebust <trond.myklebust@hammerspace.com>
> Cc: Anna Schumaker <anna.schumaker@netapp.com>
> Signed-off-by: Amir Goldstein <amir73il@gmail.com>
> ---
>  net/sunrpc/rpc_pipe.c | 4 ++++
>  1 file changed, 4 insertions(+)
>
> diff --git a/net/sunrpc/rpc_pipe.c b/net/sunrpc/rpc_pipe.c
> index 979d23646e33..917c85f15a0b 100644
> --- a/net/sunrpc/rpc_pipe.c
> +++ b/net/sunrpc/rpc_pipe.c
> @@ -597,6 +597,8 @@ static int __rpc_rmdir(struct inode *dir, struct dentry *dentry)
>
>         dget(dentry);
>         ret = simple_rmdir(dir, dentry);
> +       if (!ret)
> +               fsnotify_rmdir(dir, dentry);
>         d_delete(dentry);
>         dput(dentry);
>         return ret;
> @@ -608,6 +610,8 @@ static int __rpc_unlink(struct inode *dir, struct dentry *dentry)
>
>         dget(dentry);
>         ret = simple_unlink(dir, dentry);
> +       if (!ret)
> +               fsnotify_unlink(dir, dentry);
>         d_delete(dentry);
>         dput(dentry);
>         return ret;
> --
> 2.17.1
>

  parent reply	other threads:[~2019-05-30  5:43 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-26 14:34 [PATCH v3 00/10] Sort out fsnotify_nameremove() mess Amir Goldstein
2019-05-26 14:34 ` [PATCH v3 01/10] fsnotify: add empty fsnotify_{unlink,rmdir}() hooks Amir Goldstein
2019-05-26 14:34 ` [PATCH v3 02/10] btrfs: call fsnotify_rmdir() hook Amir Goldstein
2019-05-26 14:34 ` [PATCH v3 03/10] rpc_pipefs: call fsnotify_{unlink,rmdir}() hooks Amir Goldstein
2019-05-27 10:53   ` Jan Kara
2019-05-27 13:26     ` Amir Goldstein
2019-05-27 14:00       ` Jan Kara
2019-05-30  5:43   ` Amir Goldstein [this message]
2019-05-30 12:16     ` Trond Myklebust
2019-05-26 14:34 ` [PATCH v3 04/10] tracefs: " Amir Goldstein
2019-06-13 16:53   ` Amir Goldstein
2019-08-30 19:48     ` Steven Rostedt
2019-09-02  8:46       ` Jan Kara
2019-05-26 14:34 ` [PATCH v3 05/10] devpts: call fsnotify_unlink() hook Amir Goldstein
2019-05-26 14:34 ` [PATCH v3 06/10] debugfs: simplify __debugfs_remove_file() Amir Goldstein
2019-05-30  5:49   ` Amir Goldstein
2019-05-30 12:27     ` Greg KH
2019-06-03 13:31   ` Greg Kroah-Hartman
2019-05-26 14:34 ` [PATCH v3 07/10] debugfs: call fsnotify_{unlink,rmdir}() hooks Amir Goldstein
2019-06-03 13:31   ` Greg Kroah-Hartman
2019-05-26 14:34 ` [PATCH v3 08/10] configfs: call fsnotify_rmdir() hook Amir Goldstein
2019-05-30  6:06   ` Amir Goldstein
2019-06-13 16:57     ` Amir Goldstein
2019-05-26 14:34 ` [PATCH v3 09/10] fsnotify: move fsnotify_nameremove() hook out of d_delete() Amir Goldstein
2019-05-26 14:34 ` [PATCH v3 10/10] fsnotify: get rid of fsnotify_nameremove() Amir Goldstein
2019-05-27  8:24 ` [PATCH v3 00/10] Sort out fsnotify_nameremove() mess Greg Kroah-Hartman
2019-05-27  9:49   ` Amir Goldstein
2019-05-27 11:41     ` Greg Kroah-Hartman
2019-05-27 11:59 ` Jan Kara

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAOQ4uxh4q_ArSROkdUxFW9oezEYc4qqJNFS8oOULsVhx6-1Lig@mail.gmail.com \
    --to=amir73il@gmail.com \
    --cc=Anna.Schumaker@netapp.com \
    --cc=bfields@fieldses.org \
    --cc=dsterba@suse.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=hch@lst.de \
    --cc=jack@suse.cz \
    --cc=jlbec@evilplan.org \
    --cc=john.johansen@canonical.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=rostedt@goodmis.org \
    --cc=trond.myklebust@hammerspace.com \
    --cc=viro@zeniv.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.