summaryrefslogtreecommitdiff
path: root/fs/fuse/fuse_i.h
diff options
context:
space:
mode:
authorMiklos Szeredi <mszeredi@redhat.com>2018-10-01 10:07:05 +0200
committerMiklos Szeredi <mszeredi@redhat.com>2018-10-01 10:07:05 +0200
commit261aaba72fdba17b74a3a434d9f925b43d90e958 (patch)
tree88700d029d1bdf476b8f23e6adb46e3acb2c4b2b /fs/fuse/fuse_i.h
parent7118883b44b8edfea732aadeb0d4424da3f152b2 (diff)
downloadlwn-261aaba72fdba17b74a3a434d9f925b43d90e958.tar.gz
lwn-261aaba72fdba17b74a3a434d9f925b43d90e958.zip
fuse: use iversion for readdir cache verification
Use the internal iversion counter to make sure modifications of the directory through this filesystem are not missed by the mtime check (due to mtime granularity). Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Diffstat (limited to 'fs/fuse/fuse_i.h')
-rw-r--r--fs/fuse/fuse_i.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/fuse/fuse_i.h b/fs/fuse/fuse_i.h
index 3deb013a289e..d9d1ea78efa6 100644
--- a/fs/fuse/fuse_i.h
+++ b/fs/fuse/fuse_i.h
@@ -120,6 +120,9 @@ struct fuse_inode {
/* modification time of directory when cache was started */
struct timespec64 mtime;
+ /* iversion of directory when cache was started */
+ u64 iversion;
+
/* protects above fields */
spinlock_t lock;
} rdc;