summaryrefslogtreecommitdiffstats
path: root/fs/cifs/smb1ops.c
diff options
context:
space:
mode:
authorPavel Shilovsky <pshilovsky@samba.org>2013-09-05 08:11:28 -0400
committerSteve French <smfrench@gmail.com>2013-09-09 23:52:05 -0400
commit53ef1016fd0e4bab128a24f7fe06b9cdb2afdc31 (patch)
treeed65cd590e0b813a3643f20e752483c48c95fa11 /fs/cifs/smb1ops.c
parent18cceb6a78f46b65df654e8348fa2093b91b30f6 (diff)
CIFS: Store lease state itself rather than a mapped oplock value
and separate smb20_operations struct. Signed-off-by: Pavel Shilovsky <pshilovsky@samba.org> Signed-off-by: Steve French <smfrench@gmail.com>
Diffstat (limited to 'fs/cifs/smb1ops.c')
-rw-r--r--fs/cifs/smb1ops.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/fs/cifs/smb1ops.c b/fs/cifs/smb1ops.c
index 6fd0677915a0..8233b174de3d 100644
--- a/fs/cifs/smb1ops.c
+++ b/fs/cifs/smb1ops.c
@@ -912,6 +912,12 @@ cifs_query_symlink(const unsigned int xid, struct cifs_tcon *tcon,
912 return rc; 912 return rc;
913} 913}
914 914
915static bool
916cifs_is_read_op(__u32 oplock)
917{
918 return oplock == OPLOCK_READ;
919}
920
915struct smb_version_operations smb1_operations = { 921struct smb_version_operations smb1_operations = {
916 .send_cancel = send_nt_cancel, 922 .send_cancel = send_nt_cancel,
917 .compare_fids = cifs_compare_fids, 923 .compare_fids = cifs_compare_fids,
@@ -977,6 +983,7 @@ struct smb_version_operations smb1_operations = {
977 .mand_unlock_range = cifs_unlock_range, 983 .mand_unlock_range = cifs_unlock_range,
978 .push_mand_locks = cifs_push_mandatory_locks, 984 .push_mand_locks = cifs_push_mandatory_locks,
979 .query_mf_symlink = open_query_close_cifs_symlink, 985 .query_mf_symlink = open_query_close_cifs_symlink,
986 .is_read_op = cifs_is_read_op,
980}; 987};
981 988
982struct smb_version_values smb1_values = { 989struct smb_version_values smb1_values = {
@@ -992,7 +999,6 @@ struct smb_version_values smb1_values = {
992 .cap_unix = CAP_UNIX, 999 .cap_unix = CAP_UNIX,
993 .cap_nt_find = CAP_NT_SMBS | CAP_NT_FIND, 1000 .cap_nt_find = CAP_NT_SMBS | CAP_NT_FIND,
994 .cap_large_files = CAP_LARGE_FILES, 1001 .cap_large_files = CAP_LARGE_FILES,
995 .oplock_read = OPLOCK_READ,
996 .signing_enabled = SECMODE_SIGN_ENABLED, 1002 .signing_enabled = SECMODE_SIGN_ENABLED,
997 .signing_required = SECMODE_SIGN_REQUIRED, 1003 .signing_required = SECMODE_SIGN_REQUIRED,
998}; 1004};