From: Ibrahim Jirdeh <ibrahimjirdeh@meta.com>
To: <ibrahimjirdeh@meta.com>
Cc: <jack@suse.cz>, <amir73il@gmail.com>, <josef@toxicpanda.com>,
<lesha@meta.com>, <linux-fsdevel@vger.kernel.org>,
<sargun@meta.com>
Subject: [PATCH v3 0/3] fanotify: introduce response identifier
Date: Thu, 10 Jul 2025 19:36:01 -0700 [thread overview]
Message-ID: <20250711023604.593885-1-ibrahimjirdeh@meta.com> (raw)
These patches are in order to add an identifier other than fd which
can be used to respond to fanotify permission events. This is useful
for HSM use cases which are backed by a daemon to respond reliably
[1] and also for reporting pre-dir-content events without an event->fd [2]
The first few patches in the series are pulled in from Amir's work to
add support for pre-dir-content events.
In terms of testing, there are some additional LTP test cases to go with
these patches which exercise responding to events via response identifier
[3]
v2: https://lore.kernel.org/linux-fsdevel/20250710042049.3705747-1-ibrahimjirdeh@meta.com/
v1: https://lore.kernel.org/linux-fsdevel/20250623193631.2780278-1-ibrahimjirdeh@meta.com/
Changes v2 => v3:
- Add build assertions on new id fields and use union fields interchangeably
Changes v1 => v2:
- Moved away from adding a unique event identifier, and instead overload
event->fd to support a response identifier for now for FAN_REPORT_FID
setting.
[1] https://lore.kernel.org/all/CAMp4zn8aXNPzq1i8KYmbRfwDBvO5Qefa4isSyS1bwYuvkuBsHg@mail.gmail.com/
[2] https://lore.kernel.org/linux-fsdevel/2dx3pbcnv5w75fxb2ghqtsk6gzl6cuxmd2rinzwbq7xxfjf5z7@3nqidi3mno46/
[3] https://github.com/ibrahim-jirdeh/ltp/commit/91c963eb6758b12ce70b87ec060308017bf08ccb
Amir Goldstein (2):
fanotify: add support for a variable length permission event
fanotify: allow pre-content events with fid info
Ibrahim Jirdeh (1):
fanotify: introduce event response identifier
fs/notify/fanotify/fanotify.c | 71 +++++++++++----
fs/notify/fanotify/fanotify.h | 30 +++++--
fs/notify/fanotify/fanotify_user.c | 133 +++++++++++++++++++++-------
include/linux/fanotify.h | 1 +
include/linux/fsnotify_backend.h | 2 +
include/uapi/linux/fanotify.h | 14 ++-
tools/include/uapi/linux/fanotify.h | 11 ++-
7 files changed, 203 insertions(+), 59 deletions(-)
--
2.47.1
next reply other threads:[~2025-07-11 2:36 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-11 2:36 Ibrahim Jirdeh [this message]
2025-07-11 2:36 ` [PATCH v3 1/3] fanotify: add support for a variable length permission event Ibrahim Jirdeh
2025-07-11 2:36 ` [PATCH v3 2/3] fanotify: allow pre-content events with fid info Ibrahim Jirdeh
2025-07-11 2:36 ` [PATCH v3 3/3] fanotify: introduce event response identifier Ibrahim Jirdeh
2025-07-11 6:33 ` Amir Goldstein
2025-07-11 12:47 ` kernel test robot
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=20250711023604.593885-1-ibrahimjirdeh@meta.com \
--to=ibrahimjirdeh@meta.com \
--cc=amir73il@gmail.com \
--cc=jack@suse.cz \
--cc=josef@toxicpanda.com \
--cc=lesha@meta.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=sargun@meta.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 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.