* [PATCH 6.12.y] fs: move FMODE_NONOTIFY back to bit 26
@ 2026-11-24 14:30 Sasha Levin
0 siblings, 0 replies; only message in thread
From: Sasha Levin @ 2026-11-24 14:30 UTC (permalink / raw)
To: stable
Cc: Sasha Levin, Greg Kroah-Hartman, Jan Kara, Amir Goldstein,
Christian Brauner, Alexander Viro, Guenter Roeck, Iulian Vaideanu,
Thorsten Leemhuis, David S. Miller, Andreas Larsson, regressions,
sparclinux, linux-fsdevel
The backport of commit a94204f4d48e ("fsnotify: opt-in for permission
events at file open time") moved FMODE_NONOTIFY to bit 25, which is
__O_TMPFILE on sparc. 6.12.y still passes FMODE_NONOTIFY in open flags, so
the BUILD_BUG_ON() in fcntl_init() has broken sparc builds since v6.12.105.
Swap it with FMODE_NONOTIFY_PERM, which never ends up in open flags.
Upstream avoided this with commit ebe559609d78 ("fs: get rid of
__FMODE_NONOTIFY kludge"), but overlayfs in 6.12.y still uses
__FMODE_NONOTIFY.
Fixes: 07ee6057f92a ("fsnotify: opt-in for permission events at file open time")
Reported-by: Guenter Roeck <linux@roeck-us.net>
Closes: https://lore.kernel.org/all/7701ab76-4761-4596-b6a5-92c74e03ce5f@roeck-us.net/
Reported-by: Iulian Vaideanu <iulian.vaideanu@gmail.com>
Closes: https://lore.kernel.org/all/CAPK=yVMe1Ro=aw_daLCOM9cBATsp6crdgB4wd0ty4vrnxtVKkQ@mail.gmail.com/
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
include/linux/fs.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 67b57ce46b203..d696a21b69ee2 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -178,13 +178,13 @@ typedef int (dio_iodone_t)(struct kiocb *iocb, loff_t offset,
* Together with FMODE_NONOTIFY_PERM defines which fsnotify events shouldn't be
* generated (see below)
*/
-#define FMODE_NONOTIFY ((__force fmode_t)(1 << 25))
+#define FMODE_NONOTIFY ((__force fmode_t)(1 << 26))
/*
* Together with FMODE_NONOTIFY defines which fsnotify events shouldn't be
* generated (see below)
*/
-#define FMODE_NONOTIFY_PERM ((__force fmode_t)(1 << 26))
+#define FMODE_NONOTIFY_PERM ((__force fmode_t)(1 << 25))
/* File is capable of returning -EAGAIN if I/O will block */
#define FMODE_NOWAIT ((__force fmode_t)(1 << 27))
base-commit: e2e4b92c2b2a3ae78423cb343951cb5d2241b405
--
2.53.0
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-11-24 14:30 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-24 14:30 [PATCH 6.12.y] fs: move FMODE_NONOTIFY back to bit 26 Sasha Levin
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.