diff options
author | Pavel Shilovsky <pshilovsky@etersoft.ru> | 2012-09-19 17:22:44 +0400 |
---|---|---|
committer | Steve French <smfrench@gmail.com> | 2012-09-25 06:46:33 +0400 |
commit | 579f9053236c796d718162c37c72bb3bd32d008c (patch) | |
tree | 4de2901dcba0a49b782068b70b5b28df90b20f4b /fs/cifs/cifsproto.h | |
parent | 1b4b55a1d9404f51aacf1ff19887eb911484057d (diff) | |
download | linux-579f9053236c796d718162c37c72bb3bd32d008c.tar.xz |
CIFS: Check for mandatory brlocks on read/write
Currently CIFS code accept read/write ops on mandatory locked area
when two processes use the same file descriptor - it's wrong.
Fix this by serializing io and brlock operations on the inode.
Signed-off-by: Pavel Shilovsky <pshilovsky@etersoft.ru>
Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs/cifs/cifsproto.h')
-rw-r--r-- | fs/cifs/cifsproto.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/cifs/cifsproto.h b/fs/cifs/cifsproto.h index 15e38dc389fc..c758ee7b0307 100644 --- a/fs/cifs/cifsproto.h +++ b/fs/cifs/cifsproto.h @@ -180,6 +180,10 @@ extern struct smb_vol *cifs_get_volume_info(char *mount_data, extern int cifs_mount(struct cifs_sb_info *, struct smb_vol *); extern void cifs_umount(struct cifs_sb_info *); extern void cifs_mark_open_files_invalid(struct cifs_tcon *tcon); +extern bool cifs_find_lock_conflict(struct cifsFileInfo *cfile, __u64 offset, + __u64 length, __u8 type, + struct cifsLockInfo **conf_lock, + bool rw_check); #if IS_ENABLED(CONFIG_CIFS_DFS_UPCALL) extern void cifs_dfs_release_automount_timer(void); |