diff options
author | 2023-08-06 10:43:52 -0700 | |
---|---|---|
committer | 2023-08-06 10:43:52 -0700 | |
commit | 0108963f14e96abcfae0c4d1186c237cfb1a7fad (patch) | |
tree | 588a9b83f8feb2e8fdf120d6b537babd4689c7f1 /fs/file.c | |
parent | Merge tag 'rust-fixes-6.5-rc5' of https://github.com/Rust-for-Linux/linux (diff) | |
parent | fs: rely on ->iterate_shared to determine f_pos locking (diff) | |
download | wireguard-linux-0108963f14e96abcfae0c4d1186c237cfb1a7fad.tar.xz wireguard-linux-0108963f14e96abcfae0c4d1186c237cfb1a7fad.zip |
Merge tag 'v6.5-rc5.vfs.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/vfs/vfs
Pull vfs fixes from Christian Brauner:
- Fix a wrong check for O_TMPFILE during RESOLVE_CACHED lookup
- Clean up directory iterators and clarify file_needs_f_pos_lock()
* tag 'v6.5-rc5.vfs.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/vfs/vfs:
fs: rely on ->iterate_shared to determine f_pos locking
vfs: get rid of old '->iterate' directory operation
proc: fix missing conversion to 'iterate_shared'
open: make RESOLVE_CACHED correctly test for O_TMPFILE
Diffstat (limited to 'fs/file.c')
-rw-r--r-- | fs/file.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/file.c b/fs/file.c index dbca26ef7a01..3fd003a8604f 100644 --- a/fs/file.c +++ b/fs/file.c @@ -1049,7 +1049,7 @@ unsigned long __fdget_raw(unsigned int fd) static inline bool file_needs_f_pos_lock(struct file *file) { return (file->f_mode & FMODE_ATOMIC_POS) && - (file_count(file) > 1 || S_ISDIR(file_inode(file)->i_mode)); + (file_count(file) > 1 || file->f_op->iterate_shared); } unsigned long __fdget_pos(unsigned int fd) |