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.c25
1 files changed, 13 insertions, 12 deletions
diff --git a/fs/cifs/connect.c b/fs/cifs/connect.c
index 3d036bf689d8..1f22b85324cf 100644
--- a/fs/cifs/connect.c
+++ b/fs/cifs/connect.c
@@ -924,14 +924,15 @@ find_unc(__be32 new_target_ip_addr, char *uncName, char *userName)
924 924
925int 925int
926connect_to_dfs_path(int xid, struct cifsSesInfo *pSesInfo, 926connect_to_dfs_path(int xid, struct cifsSesInfo *pSesInfo,
927 const char *old_path, const struct nls_table *nls_codepage) 927 const char *old_path, const struct nls_table *nls_codepage,
928 int remap)
928{ 929{
929 unsigned char *referrals = NULL; 930 unsigned char *referrals = NULL;
930 unsigned int num_referrals; 931 unsigned int num_referrals;
931 int rc = 0; 932 int rc = 0;
932 933
933 rc = get_dfs_path(xid, pSesInfo,old_path, nls_codepage, 934 rc = get_dfs_path(xid, pSesInfo,old_path, nls_codepage,
934 &num_referrals, &referrals); 935 &num_referrals, &referrals, remap);
935 936
936 /* BB Add in code to: if valid refrl, if not ip address contact 937 /* BB Add in code to: if valid refrl, if not ip address contact
937 the helper that resolves tcp names, mount to it, try to 938 the helper that resolves tcp names, mount to it, try to
@@ -946,7 +947,8 @@ connect_to_dfs_path(int xid, struct cifsSesInfo *pSesInfo,
946int 947int
947get_dfs_path(int xid, struct cifsSesInfo *pSesInfo, 948get_dfs_path(int xid, struct cifsSesInfo *pSesInfo,
948 const char *old_path, const struct nls_table *nls_codepage, 949 const char *old_path, const struct nls_table *nls_codepage,
949 unsigned int *pnum_referrals, unsigned char ** preferrals) 950 unsigned int *pnum_referrals,
951 unsigned char ** preferrals, int remap)
950{ 952{
951 char *temp_unc; 953 char *temp_unc;
952 int rc = 0; 954 int rc = 0;
@@ -971,7 +973,7 @@ get_dfs_path(int xid, struct cifsSesInfo *pSesInfo,
971 } 973 }
972 if (rc == 0) 974 if (rc == 0)
973 rc = CIFSGetDFSRefer(xid, pSesInfo, old_path, preferrals, 975 rc = CIFSGetDFSRefer(xid, pSesInfo, old_path, preferrals,
974 pnum_referrals, nls_codepage); 976 pnum_referrals, nls_codepage, remap);
975 977
976 return rc; 978 return rc;
977} 979}
@@ -1456,11 +1458,10 @@ cifs_mount(struct super_block *sb, struct cifs_sb_info *cifs_sb,
1456 if ((strchr(volume_info.UNC + 3, '\\') == NULL) 1458 if ((strchr(volume_info.UNC + 3, '\\') == NULL)
1457 && (strchr(volume_info.UNC + 3, '/') == 1459 && (strchr(volume_info.UNC + 3, '/') ==
1458 NULL)) { 1460 NULL)) {
1459 rc = connect_to_dfs_path(xid, 1461 rc = connect_to_dfs_path(xid, pSesInfo,
1460 pSesInfo, 1462 "", cifs_sb->local_nls,
1461 "", 1463 cifs_sb->mnt_cifs_flags &
1462 cifs_sb-> 1464 CIFS_MOUNT_MAP_SPECIAL_CHR);
1463 local_nls);
1464 if(volume_info.UNC) 1465 if(volume_info.UNC)
1465 kfree(volume_info.UNC); 1466 kfree(volume_info.UNC);
1466 FreeXid(xid); 1467 FreeXid(xid);
@@ -1523,10 +1524,10 @@ cifs_mount(struct super_block *sb, struct cifs_sb_info *cifs_sb,
1523 tcon->ses = pSesInfo; 1524 tcon->ses = pSesInfo;
1524 1525
1525 /* do not care if following two calls succeed - informational only */ 1526 /* do not care if following two calls succeed - informational only */
1526 CIFSSMBQFSDeviceInfo(xid, tcon, cifs_sb->local_nls); 1527 CIFSSMBQFSDeviceInfo(xid, tcon);
1527 CIFSSMBQFSAttributeInfo(xid, tcon, cifs_sb->local_nls); 1528 CIFSSMBQFSAttributeInfo(xid, tcon);
1528 if (tcon->ses->capabilities & CAP_UNIX) { 1529 if (tcon->ses->capabilities & CAP_UNIX) {
1529 if(!CIFSSMBQFSUnixInfo(xid, tcon, cifs_sb->local_nls)) { 1530 if(!CIFSSMBQFSUnixInfo(xid, tcon)) {
1530 if(!volume_info.no_psx_acl) { 1531 if(!volume_info.no_psx_acl) {
1531 if(CIFS_UNIX_POSIX_ACL_CAP & 1532 if(CIFS_UNIX_POSIX_ACL_CAP &
1532 le64_to_cpu(tcon->fsUnixInfo.Capability)) 1533 le64_to_cpu(tcon->fsUnixInfo.Capability))