diff options
author | Steve French <stfrench@microsoft.com> | 2019-07-17 01:55:38 +0200 |
---|---|---|
committer | Steve French <stfrench@microsoft.com> | 2019-11-25 08:14:14 +0100 |
commit | d0677992d2af3d65f1c1c21de3323d09d4891537 (patch) | |
tree | 77c2daf3008dd03a3b0f8af179119cb26dc1f5ec /fs/cifs/cifsfs.h | |
parent | cifs: remove unused variable 'sid_user' (diff) | |
download | linux-d0677992d2af3d65f1c1c21de3323d09d4891537.tar.xz linux-d0677992d2af3d65f1c1c21de3323d09d4891537.zip |
cifs: add support for flock
The flock system call locks the whole file rather than a byte
range and so is currently emulated by various other file systems
by simply sending a byte range lock for the whole file.
Add flock handling for cifs.ko in similar way.
xfstest generic/504 passes with this as well
Signed-off-by: Steve French <stfrench@microsoft.com>
Reviewed-by: Pavel Shilovsky <pshilov@microsoft.com>
Reviewed-by: Ronnie Sahlberg <lsahlber@redhat.com>
Diffstat (limited to 'fs/cifs/cifsfs.h')
-rw-r--r-- | fs/cifs/cifsfs.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/cifs/cifsfs.h b/fs/cifs/cifsfs.h index bc4ca94137f2..93c757265105 100644 --- a/fs/cifs/cifsfs.h +++ b/fs/cifs/cifsfs.h @@ -108,6 +108,7 @@ extern ssize_t cifs_strict_readv(struct kiocb *iocb, struct iov_iter *to); extern ssize_t cifs_user_writev(struct kiocb *iocb, struct iov_iter *from); extern ssize_t cifs_direct_writev(struct kiocb *iocb, struct iov_iter *from); extern ssize_t cifs_strict_writev(struct kiocb *iocb, struct iov_iter *from); +extern int cifs_flock(struct file *pfile, int cmd, struct file_lock *plock); extern int cifs_lock(struct file *, int, struct file_lock *); extern int cifs_fsync(struct file *, loff_t, loff_t, int); extern int cifs_strict_fsync(struct file *, loff_t, loff_t, int); |