aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/fs.h
diff options
context:
space:
mode:
authorAmir Goldstein <amir73il@gmail.com>2021-08-10 18:12:19 +0300
committerJan Kara <jack@suse.cz>2021-08-11 13:50:48 +0200
commitec44610fe2b86daef70f3f53f47d2a2542d7094f (patch)
treee12dfdbde1050af24b6c30a9ea36fb9dfa690b63 /include/linux/fs.h
parentfsnotify: count s_fsnotify_inode_refs for attached connectors (diff)
downloadlinux-dev-ec44610fe2b86daef70f3f53f47d2a2542d7094f.tar.xz
linux-dev-ec44610fe2b86daef70f3f53f47d2a2542d7094f.zip
fsnotify: count all objects with attached connectors
Rename s_fsnotify_inode_refs to s_fsnotify_connectors and count all objects with attached connectors, not only inodes with attached connectors. This will be used to optimize fsnotify() calls on sb without any type of marks. Link: https://lore.kernel.org/r/20210810151220.285179-4-amir73il@gmail.com Signed-off-by: Amir Goldstein <amir73il@gmail.com> Reviewed-by: Matthew Bobrowski <repnop@google.com> Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'include/linux/fs.h')
-rw-r--r--include/linux/fs.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 640574294216..bea8ec5c726c 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -1507,8 +1507,11 @@ struct super_block {
/* Number of inodes with nlink == 0 but still referenced */
atomic_long_t s_remove_count;
- /* Pending fsnotify inode refs */
- atomic_long_t s_fsnotify_inode_refs;
+ /*
+ * Number of inode/mount/sb objects that are being watched, note that
+ * inodes objects are currently double-accounted.
+ */
+ atomic_long_t s_fsnotify_connectors;
/* Being remounted read-only */
int s_readonly_remount;