aboutsummaryrefslogtreecommitdiffstats
path: root/fs/cifs/cifssmb.c
diff options
context:
space:
mode:
authorSteve French <sfrench@us.ibm.com>2007-07-18 19:21:09 -0400
committerSteve French <sfrench@us.ibm.com>2007-07-18 19:21:09 -0400
commitc18c842b1fdf527717303a4e173cbece7ab2deb8 (patch)
treeb400ad6d711b8474a0516220c98d390d56c508de /fs/cifs/cifssmb.c
parent63135e088a604b955746c51964c195c8d3ebac11 (diff)
[CIFS] Allow disabling CIFS Unix Extensions as mount option
Previously the only way to do this was to umount all mounts to that server, turn off a proc setting (/proc/fs/cifs/LinuxExtensionsEnabled). Fixes Samba bugzilla bug number: 4582 (and also 2008) Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs/cifs/cifssmb.c')
-rw-r--r--fs/cifs/cifssmb.c21
1 files changed, 6 insertions, 15 deletions
diff --git a/fs/cifs/cifssmb.c b/fs/cifs/cifssmb.c
index a6ff406ac6b4..8eb102f940d4 100644
--- a/fs/cifs/cifssmb.c
+++ b/fs/cifs/cifssmb.c
@@ -132,10 +132,10 @@ small_smb_init(int smb_command, int wct, struct cifsTconInfo *tcon,
132 /* Give Demultiplex thread up to 10 seconds to 132 /* Give Demultiplex thread up to 10 seconds to
133 reconnect, should be greater than cifs socket 133 reconnect, should be greater than cifs socket
134 timeout which is 7 seconds */ 134 timeout which is 7 seconds */
135 while(tcon->ses->server->tcpStatus == 135 while (tcon->ses->server->tcpStatus ==
136 CifsNeedReconnect) { 136 CifsNeedReconnect) {
137 wait_event_interruptible_timeout(tcon->ses->server->response_q, 137 wait_event_interruptible_timeout(tcon->ses->server->response_q,
138 (tcon->ses->server->tcpStatus == 138 (tcon->ses->server->tcpStatus ==
139 CifsGood), 10 * HZ); 139 CifsGood), 10 * HZ);
140 if (tcon->ses->server->tcpStatus == 140 if (tcon->ses->server->tcpStatus ==
141 CifsNeedReconnect) { 141 CifsNeedReconnect) {
@@ -213,7 +213,7 @@ small_smb_init(int smb_command, int wct, struct cifsTconInfo *tcon,
213 } 213 }
214 214
215 header_assemble((struct smb_hdr *) *request_buf, smb_command, 215 header_assemble((struct smb_hdr *) *request_buf, smb_command,
216 tcon,wct); 216 tcon, wct);
217 217
218 if (tcon != NULL) 218 if (tcon != NULL)
219 cifs_stats_inc(&tcon->num_smbs_sent); 219 cifs_stats_inc(&tcon->num_smbs_sent);
@@ -387,7 +387,7 @@ static int validate_t2(struct smb_t2_rsp *pSMB)
387 /* check that bcc is less than negotiated smb buffer */ 387 /* check that bcc is less than negotiated smb buffer */
388 total_size = le16_to_cpu(pSMB->t2_rsp.ParameterCount); 388 total_size = le16_to_cpu(pSMB->t2_rsp.ParameterCount);
389 if (total_size < 512) { 389 if (total_size < 512) {
390 total_size += 390 total_size +=
391 le16_to_cpu(pSMB->t2_rsp.DataCount); 391 le16_to_cpu(pSMB->t2_rsp.DataCount);
392 /* BCC le converted in SendReceive */ 392 /* BCC le converted in SendReceive */
393 pBCC = (pSMB->hdr.WordCount * 2) + 393 pBCC = (pSMB->hdr.WordCount * 2) +
@@ -2758,7 +2758,7 @@ static __u16 ACL_to_cifs_posix(char *parm_data, const char *pACL,
2758 return 0; 2758 return 0;
2759 2759
2760 count = posix_acl_xattr_count((size_t)buflen); 2760 count = posix_acl_xattr_count((size_t)buflen);
2761 cFYI(1,("setting acl with %d entries from buf of length %d and " 2761 cFYI(1, ("setting acl with %d entries from buf of length %d and "
2762 "version of %d", 2762 "version of %d",
2763 count, buflen, le32_to_cpu(local_acl->a_version))); 2763 count, buflen, le32_to_cpu(local_acl->a_version)));
2764 if (le32_to_cpu(local_acl->a_version) != 2) { 2764 if (le32_to_cpu(local_acl->a_version) != 2) {
@@ -3638,15 +3638,6 @@ int CIFSFindNext(const int xid, struct cifsTconInfo *tcon,
3638 pSMB->SearchHandle = searchHandle; /* always kept as le */ 3638 pSMB->SearchHandle = searchHandle; /* always kept as le */
3639 pSMB->SearchCount = 3639 pSMB->SearchCount =
3640 cpu_to_le16(CIFSMaxBufSize / sizeof (FILE_UNIX_INFO)); 3640 cpu_to_le16(CIFSMaxBufSize / sizeof (FILE_UNIX_INFO));
3641 /* test for Unix extensions */
3642/* if (tcon->ses->capabilities & CAP_UNIX) {
3643 pSMB->InformationLevel = cpu_to_le16(SMB_FIND_FILE_UNIX);
3644 psrch_inf->info_level = SMB_FIND_FILE_UNIX;
3645 } else {
3646 pSMB->InformationLevel =
3647 cpu_to_le16(SMB_FIND_FILE_DIRECTORY_INFO);
3648 psrch_inf->info_level = SMB_FIND_FILE_DIRECTORY_INFO;
3649 } */
3650 pSMB->InformationLevel = cpu_to_le16(psrch_inf->info_level); 3641 pSMB->InformationLevel = cpu_to_le16(psrch_inf->info_level);
3651 pSMB->ResumeKey = psrch_inf->resume_key; 3642 pSMB->ResumeKey = psrch_inf->resume_key;
3652 pSMB->SearchFlags = 3643 pSMB->SearchFlags =
@@ -3966,7 +3957,7 @@ getDFSRetry:
3966 (8 /* sizeof start of data block */ + 3957 (8 /* sizeof start of data block */ +
3967 data_offset + 3958 data_offset +
3968 (char *) &pSMBr->hdr.Protocol); 3959 (char *) &pSMBr->hdr.Protocol);
3969 cFYI(1,("num_referrals: %d dfs flags: 0x%x ... \n" 3960 cFYI(1, ("num_referrals: %d dfs flags: 0x%x ... \n"
3970 "for referral one refer size: 0x%x srv " 3961 "for referral one refer size: 0x%x srv "
3971 "type: 0x%x refer flags: 0x%x ttl: 0x%x", 3962 "type: 0x%x refer flags: 0x%x ttl: 0x%x",
3972 le16_to_cpu(pSMBr->NumberOfReferrals), 3963 le16_to_cpu(pSMBr->NumberOfReferrals),