aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/fs.h
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2018-07-09 02:35:08 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2018-07-12 10:04:16 -0400
commitf5d11409e61dadf1f9af91b22bbedc28a60a2e2c (patch)
tree5d965549f3a50f712e6b6fc3e2e908dda385493d /include/linux/fs.h
parent->file_open(): lose cred argument (diff)
downloadlinux-dev-f5d11409e61dadf1f9af91b22bbedc28a60a2e2c.tar.xz
linux-dev-f5d11409e61dadf1f9af91b22bbedc28a60a2e2c.zip
introduce FMODE_OPENED
basically, "is that instance set up enough for regular fput(), or do we want put_filp() for that one". NOTE: the only alloc_file() caller that could be followed by put_filp() is in arch/ia64/kernel/perfmon.c, which is (Kconfig-level) broken. Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to '')
-rw-r--r--include/linux/fs.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/fs.h b/include/linux/fs.h
index c4ca4c9c1130..05f34726e29c 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -148,6 +148,8 @@ typedef int (dio_iodone_t)(struct kiocb *iocb, loff_t offset,
/* Has write method(s) */
#define FMODE_CAN_WRITE ((__force fmode_t)0x40000)
+#define FMODE_OPENED ((__force fmode_t)0x80000)
+
/* File was opened by fanotify and shouldn't generate fanotify events */
#define FMODE_NONOTIFY ((__force fmode_t)0x4000000)