linux-api.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Christian Brauner <brauner@kernel.org>
To: Amir Goldstein <amir73il@gmail.com>
Cc: Jan Kara <jack@suse.cz>, Matthew Bobrowski <repnop@google.com>,
	linux-fsdevel@vger.kernel.org, linux-api@vger.kernel.org
Subject: Re: [RFC][PATCH 1/2] fanotify: add support for FAN_UNMOUNT event
Date: Tue, 18 Apr 2023 15:43:10 +0200	[thread overview]
Message-ID: <20230418-gebacken-roben-610d78ee4e66@brauner> (raw)
In-Reply-To: <20230414182903.1852019-2-amir73il@gmail.com>

On Fri, Apr 14, 2023 at 09:29:02PM +0300, Amir Goldstein wrote:
> inotify generates unsolicited IN_UNMOUNT events for every inode
> mark before the filesystem containing the inode is shutdown.
> 
> Unlike IN_UNMOUNT, FAN_UNMOUNT is an opt-in event that can only be
> set on a mount mark and is generated when the mount is unmounted.
> 
> FAN_UNMOUNT requires FAN_REPORT_FID and reports an fid info record
> with fsid of the filesystem and an empty file handle.
> 
> Signed-off-by: Amir Goldstein <amir73il@gmail.com>
> ---

I think this is a useful addition to the fanotify api and more useful
than IN_UMOUNT.

Going back to your cover letter. Afaiu, IN_UMOUNT is generated when the
superblock in which a watched object resides goes away. That's roughly
what I had in mind with FAN_SB_SHUTDOWN (ignoring naming discusions for
now).

  reply	other threads:[~2023-04-18 13:43 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-14 18:29 [RFC][PATCH 0/2] Monitoring unmounted fs with fanotify Amir Goldstein
2023-04-14 18:29 ` [RFC][PATCH 1/2] fanotify: add support for FAN_UNMOUNT event Amir Goldstein
2023-04-18 13:43   ` Christian Brauner [this message]
2023-04-19 13:14   ` Jan Kara
2023-04-19 18:32     ` Amir Goldstein
2023-04-14 18:29 ` [RFC][PATCH 2/2] fanotify: report mntid info record with FAN_UNMOUNT events Amir Goldstein
2023-04-17  8:38   ` Amir Goldstein
2023-04-19 13:30   ` Jan Kara
2023-04-18 13:33 ` [RFC][PATCH 0/2] Monitoring unmounted fs with fanotify Christian Brauner
2023-04-18 13:56   ` Amir Goldstein
2023-04-18 14:12     ` Christian Brauner
2023-04-18 15:20       ` Amir Goldstein
2023-04-19 17:19         ` Christian Brauner
2023-04-20  6:12           ` Amir Goldstein
2023-04-20  7:46             ` Christian Brauner
2023-04-20  8:15               ` Amir Goldstein

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=20230418-gebacken-roben-610d78ee4e66@brauner \
    --to=brauner@kernel.org \
    --cc=amir73il@gmail.com \
    --cc=jack@suse.cz \
    --cc=linux-api@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=repnop@google.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).