summaryrefslogtreecommitdiff
path: root/fs/fuse/fuse_i.h
diff options
context:
space:
mode:
authorMiklos Szeredi <mszeredi@redhat.com>2024-03-06 16:20:58 +0100
committerMiklos Szeredi <mszeredi@redhat.com>2024-03-06 16:20:58 +0100
commitcdf6ac2a03d253f05d3e798f60f23dea1b176b92 (patch)
tree5851952559f7f82741a7a951f2b4de18f6eb6437 /fs/fuse/fuse_i.h
parentefc4105a4cf9e300b8e9150147415fa235059293 (diff)
fuse: get rid of ff->readdir.lock
The same protection is provided by file->f_pos_lock. Note, this relies on the fact that file->f_mode has FMODE_ATOMIC_POS. This flag is cleared by stream_open(), which would prevent locking of f_pos_lock. Prior to commit 7de64d521bf9 ("fuse: break up fuse_open_common()") FOPEN_STREAM on a directory would cause stream_open() to be called. After this commit this is not done anymore, so f_pos_lock will always be locked. Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Diffstat (limited to 'fs/fuse/fuse_i.h')
-rw-r--r--fs/fuse/fuse_i.h6
1 files changed, 0 insertions, 6 deletions
diff --git a/fs/fuse/fuse_i.h b/fs/fuse/fuse_i.h
index 0f3521449bb4..3658a70ae414 100644
--- a/fs/fuse/fuse_i.h
+++ b/fs/fuse/fuse_i.h
@@ -243,12 +243,6 @@ struct fuse_file {
/* Readdir related */
struct {
- /*
- * Protects below fields against (crazy) parallel readdir on
- * same open file. Uncontended in the normal case.
- */
- struct mutex lock;
-
/* Dir stream position */
loff_t pos;