summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorSteve French <stfrench@microsoft.com>2024-05-14 01:02:05 +0300
committerSteve French <stfrench@microsoft.com>2024-05-14 01:02:05 +0300
commit14b1cd25346b1d615616a9c2dfdad9b4e6581e0d (patch)
tree509f7d1f8107d435be4e1991f63c3bec152c8c2b /include
parent29b4c7bb8565118e2c7e08709fce0dbe8bf61011 (diff)
downloadlinux-14b1cd25346b1d615616a9c2dfdad9b4e6581e0d.tar.xz
cifs: Fix locking in cifs_strict_readv()
Fix to take the i_rwsem (through the netfs locking wrappers) before taking cinode->lock_sem. Fixes: 3ee1a1fc3981 ("cifs: Cut over to using netfslib") Reported-by: Enzo Matsumiya <ematsumiya@suse.de> Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: Steve French <stfrench@microsoft.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/netfs.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/netfs.h b/include/linux/netfs.h
index f45d06284f2f..ca56a4428043 100644
--- a/include/linux/netfs.h
+++ b/include/linux/netfs.h
@@ -389,6 +389,7 @@ struct netfs_cache_ops {
};
/* High-level read API. */
+ssize_t netfs_unbuffered_read_iter_locked(struct kiocb *iocb, struct iov_iter *iter);
ssize_t netfs_unbuffered_read_iter(struct kiocb *iocb, struct iov_iter *iter);
ssize_t netfs_buffered_read_iter(struct kiocb *iocb, struct iov_iter *iter);
ssize_t netfs_file_read_iter(struct kiocb *iocb, struct iov_iter *iter);