aboutsummaryrefslogtreecommitdiffstats
path: root/fs/cifs/connect.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/cifs/connect.c')
-rw-r--r--fs/cifs/connect.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/fs/cifs/connect.c b/fs/cifs/connect.c
index b706b4f48b10..5d394c726860 100644
--- a/fs/cifs/connect.c
+++ b/fs/cifs/connect.c
@@ -1271,33 +1271,35 @@ find_unc(__be32 new_target_ip_addr, char *uncName, char *userName)
1271 1271
1272 read_lock(&GlobalSMBSeslock); 1272 read_lock(&GlobalSMBSeslock);
1273 list_for_each(tmp, &GlobalTreeConnectionList) { 1273 list_for_each(tmp, &GlobalTreeConnectionList) {
1274 cFYI(1, ("Next tcon - ")); 1274 cFYI(1, ("Next tcon"));
1275 tcon = list_entry(tmp, struct cifsTconInfo, cifsConnectionList); 1275 tcon = list_entry(tmp, struct cifsTconInfo, cifsConnectionList);
1276 if (tcon->ses) { 1276 if (tcon->ses) {
1277 if (tcon->ses->server) { 1277 if (tcon->ses->server) {
1278 cFYI(1, 1278 cFYI(1,
1279 (" old ip addr: %x == new ip %x ?", 1279 ("old ip addr: %x == new ip %x ?",
1280 tcon->ses->server->addr.sockAddr.sin_addr. 1280 tcon->ses->server->addr.sockAddr.sin_addr.
1281 s_addr, new_target_ip_addr)); 1281 s_addr, new_target_ip_addr));
1282 if (tcon->ses->server->addr.sockAddr.sin_addr. 1282 if (tcon->ses->server->addr.sockAddr.sin_addr.
1283 s_addr == new_target_ip_addr) { 1283 s_addr == new_target_ip_addr) {
1284 /* BB lock tcon and server and tcp session and increment use count here? */ 1284 /* BB lock tcon, server and tcp session and increment use count here? */
1285 /* found a match on the TCP session */ 1285 /* found a match on the TCP session */
1286 /* BB check if reconnection needed */ 1286 /* BB check if reconnection needed */
1287 cFYI(1,("Matched ip, old UNC: %s == new: %s ?", 1287 cFYI(1,("IP match, old UNC: %s new: %s",
1288 tcon->treeName, uncName)); 1288 tcon->treeName, uncName));
1289 if (strncmp 1289 if (strncmp
1290 (tcon->treeName, uncName, 1290 (tcon->treeName, uncName,
1291 MAX_TREE_SIZE) == 0) { 1291 MAX_TREE_SIZE) == 0) {
1292 cFYI(1, 1292 cFYI(1,
1293 ("Matched UNC, old user: %s == new: %s ?", 1293 ("and old usr: %s new: %s",
1294 tcon->treeName, uncName)); 1294 tcon->treeName, uncName));
1295 if (strncmp 1295 if (strncmp
1296 (tcon->ses->userName, 1296 (tcon->ses->userName,
1297 userName, 1297 userName,
1298 MAX_USERNAME_SIZE) == 0) { 1298 MAX_USERNAME_SIZE) == 0) {
1299 read_unlock(&GlobalSMBSeslock); 1299 read_unlock(&GlobalSMBSeslock);
1300 return tcon;/* also matched user (smb session)*/ 1300 /* matched smb session
1301 (user name */
1302 return tcon;
1301 } 1303 }
1302 } 1304 }
1303 } 1305 }