Lines Matching refs:name_len
854 int name_len; in CIFSPOSIXDelFile() local
867 name_len = in CIFSPOSIXDelFile()
870 name_len++; /* trailing null */ in CIFSPOSIXDelFile()
871 name_len *= 2; in CIFSPOSIXDelFile()
873 name_len = copy_path_name(pSMB->FileName, fileName); in CIFSPOSIXDelFile()
876 params = 6 + name_len; in CIFSPOSIXDelFile()
928 int name_len; in CIFSSMBDelFile() local
938 name_len = cifsConvertToUTF16((__le16 *) pSMB->fileName, name, in CIFSSMBDelFile()
941 name_len++; /* trailing null */ in CIFSSMBDelFile()
942 name_len *= 2; in CIFSSMBDelFile()
944 name_len = copy_path_name(pSMB->fileName, name); in CIFSSMBDelFile()
949 inc_rfc1001_len(pSMB, name_len + 1); in CIFSSMBDelFile()
950 pSMB->ByteCount = cpu_to_le16(name_len + 1); in CIFSSMBDelFile()
972 int name_len; in CIFSSMBRmDir() local
983 name_len = cifsConvertToUTF16((__le16 *) pSMB->DirName, name, in CIFSSMBRmDir()
986 name_len++; /* trailing null */ in CIFSSMBRmDir()
987 name_len *= 2; in CIFSSMBRmDir()
989 name_len = copy_path_name(pSMB->DirName, name); in CIFSSMBRmDir()
993 inc_rfc1001_len(pSMB, name_len + 1); in CIFSSMBRmDir()
994 pSMB->ByteCount = cpu_to_le16(name_len + 1); in CIFSSMBRmDir()
1016 int name_len; in CIFSSMBMkDir() local
1027 name_len = cifsConvertToUTF16((__le16 *) pSMB->DirName, name, in CIFSSMBMkDir()
1030 name_len++; /* trailing null */ in CIFSSMBMkDir()
1031 name_len *= 2; in CIFSSMBMkDir()
1033 name_len = copy_path_name(pSMB->DirName, name); in CIFSSMBMkDir()
1037 inc_rfc1001_len(pSMB, name_len + 1); in CIFSSMBMkDir()
1038 pSMB->ByteCount = cpu_to_le16(name_len + 1); in CIFSSMBMkDir()
1060 int name_len; in CIFSPOSIXCreate() local
1075 name_len = in CIFSPOSIXCreate()
1078 name_len++; /* trailing null */ in CIFSPOSIXCreate()
1079 name_len *= 2; in CIFSPOSIXCreate()
1081 name_len = copy_path_name(pSMB->FileName, name); in CIFSPOSIXCreate()
1084 params = 6 + name_len; in CIFSPOSIXCreate()
1227 int name_len; in SMBLegacyOpen() local
1240 name_len = in SMBLegacyOpen()
1243 name_len++; /* trailing null */ in SMBLegacyOpen()
1244 name_len *= 2; in SMBLegacyOpen()
1247 name_len = copy_path_name(pSMB->fileName, fileName); in SMBLegacyOpen()
1276 count += name_len; in SMBLegacyOpen()
1328 int name_len; in CIFS_open() local
1351 name_len = cifsConvertToUTF16((__le16 *)(req->fileName + 1), in CIFS_open()
1354 name_len++; in CIFS_open()
1355 name_len *= 2; in CIFS_open()
1356 req->NameLength = cpu_to_le16(name_len); in CIFS_open()
1361 name_len = copy_path_name(req->fileName, path); in CIFS_open()
1362 req->NameLength = cpu_to_le16(name_len); in CIFS_open()
1400 count += name_len; in CIFS_open()
2697 int name_len, name_len2; in CIFSSMBRename() local
2714 name_len = cifsConvertToUTF16((__le16 *) pSMB->OldFileName, in CIFSSMBRename()
2717 name_len++; /* trailing null */ in CIFSSMBRename()
2718 name_len *= 2; in CIFSSMBRename()
2719 pSMB->OldFileName[name_len] = 0x04; /* pad */ in CIFSSMBRename()
2721 pSMB->OldFileName[name_len + 1] = 0x00; in CIFSSMBRename()
2723 cifsConvertToUTF16((__le16 *)&pSMB->OldFileName[name_len+2], in CIFSSMBRename()
2729 name_len = copy_path_name(pSMB->OldFileName, from_name); in CIFSSMBRename()
2730 name_len2 = copy_path_name(pSMB->OldFileName+name_len+1, to_name); in CIFSSMBRename()
2731 pSMB->OldFileName[name_len] = 0x04; /* 2nd buffer format */ in CIFSSMBRename()
2735 count = 1 /* 1st signature byte */ + name_len + name_len2; in CIFSSMBRename()
2844 int name_len, name_len2; in CIFSSMBCopy() local
2860 name_len = cifsConvertToUTF16((__le16 *) pSMB->OldFileName, in CIFSSMBCopy()
2863 name_len++; /* trailing null */ in CIFSSMBCopy()
2864 name_len *= 2; in CIFSSMBCopy()
2865 pSMB->OldFileName[name_len] = 0x04; /* pad */ in CIFSSMBCopy()
2867 pSMB->OldFileName[name_len + 1] = 0x00; in CIFSSMBCopy()
2869 cifsConvertToUTF16((__le16 *)&pSMB->OldFileName[name_len+2], in CIFSSMBCopy()
2874 name_len = copy_path_name(pSMB->OldFileName, fromName); in CIFSSMBCopy()
2875 pSMB->OldFileName[name_len] = 0x04; /* 2nd buffer format */ in CIFSSMBCopy()
2876 name_len2 = copy_path_name(pSMB->OldFileName+name_len+1, toName); in CIFSSMBCopy()
2880 count = 1 /* 1st signature byte */ + name_len + name_len2; in CIFSSMBCopy()
2906 int name_len; in CIFSUnixCreateSymLink() local
2920 name_len = in CIFSUnixCreateSymLink()
2924 name_len++; /* trailing null */ in CIFSUnixCreateSymLink()
2925 name_len *= 2; in CIFSUnixCreateSymLink()
2928 name_len = copy_path_name(pSMB->FileName, fromName); in CIFSUnixCreateSymLink()
2930 params = 6 + name_len; in CIFSUnixCreateSymLink()
2992 int name_len; in CIFSUnixCreateHardLink() local
3006 name_len = cifsConvertToUTF16((__le16 *) pSMB->FileName, toName, in CIFSUnixCreateHardLink()
3008 name_len++; /* trailing null */ in CIFSUnixCreateHardLink()
3009 name_len *= 2; in CIFSUnixCreateHardLink()
3012 name_len = copy_path_name(pSMB->FileName, toName); in CIFSUnixCreateHardLink()
3014 params = 6 + name_len; in CIFSUnixCreateHardLink()
3075 int name_len, name_len2; in CIFSCreateHardLink() local
3096 name_len = in CIFSCreateHardLink()
3099 name_len++; /* trailing null */ in CIFSCreateHardLink()
3100 name_len *= 2; in CIFSCreateHardLink()
3103 pSMB->OldFileName[name_len] = 0x04; in CIFSCreateHardLink()
3104 pSMB->OldFileName[name_len + 1] = 0x00; /* pad */ in CIFSCreateHardLink()
3106 cifsConvertToUTF16((__le16 *)&pSMB->OldFileName[name_len+2], in CIFSCreateHardLink()
3112 name_len = copy_path_name(pSMB->OldFileName, from_name); in CIFSCreateHardLink()
3113 pSMB->OldFileName[name_len] = 0x04; /* 2nd buffer format */ in CIFSCreateHardLink()
3114 name_len2 = copy_path_name(pSMB->OldFileName+name_len+1, to_name); in CIFSCreateHardLink()
3118 count = 1 /* string type byte */ + name_len + name_len2; in CIFSCreateHardLink()
3145 int name_len; in CIFSSMBUnixQuerySymLink() local
3158 name_len = in CIFSSMBUnixQuerySymLink()
3162 name_len++; /* trailing null */ in CIFSSMBUnixQuerySymLink()
3163 name_len *= 2; in CIFSSMBUnixQuerySymLink()
3165 name_len = copy_path_name(pSMB->FileName, searchName); in CIFSSMBUnixQuerySymLink()
3168 params = 2 /* level */ + 4 /* rsrvd */ + name_len /* incl null */ ; in CIFSSMBUnixQuerySymLink()
3562 int name_len; in CIFSSMBGetPosixACL() local
3574 name_len = in CIFSSMBGetPosixACL()
3578 name_len++; /* trailing null */ in CIFSSMBGetPosixACL()
3579 name_len *= 2; in CIFSSMBGetPosixACL()
3580 pSMB->FileName[name_len] = 0; in CIFSSMBGetPosixACL()
3581 pSMB->FileName[name_len+1] = 0; in CIFSSMBGetPosixACL()
3583 name_len = copy_path_name(pSMB->FileName, searchName); in CIFSSMBGetPosixACL()
3586 params = 2 /* level */ + 4 /* rsrvd */ + name_len /* incl null */ ; in CIFSSMBGetPosixACL()
3648 int name_len; in CIFSSMBSetPosixACL() local
3660 name_len = in CIFSSMBSetPosixACL()
3663 name_len++; /* trailing null */ in CIFSSMBSetPosixACL()
3664 name_len *= 2; in CIFSSMBSetPosixACL()
3666 name_len = copy_path_name(pSMB->FileName, fileName); in CIFSSMBSetPosixACL()
3668 params = 6 + name_len; in CIFSSMBSetPosixACL()
4054 int name_len; in SMBQueryInformation() local
4064 name_len = in SMBQueryInformation()
4068 name_len++; /* trailing null */ in SMBQueryInformation()
4069 name_len *= 2; in SMBQueryInformation()
4071 name_len = copy_path_name(pSMB->FileName, search_name); in SMBQueryInformation()
4074 name_len++; /* account for buffer type byte */ in SMBQueryInformation()
4075 inc_rfc1001_len(pSMB, (__u16)name_len); in SMBQueryInformation()
4076 pSMB->ByteCount = cpu_to_le16(name_len); in SMBQueryInformation()
4190 int name_len; in CIFSSMBQPathInfo() local
4201 name_len = in CIFSSMBQPathInfo()
4204 name_len++; /* trailing null */ in CIFSSMBQPathInfo()
4205 name_len *= 2; in CIFSSMBQPathInfo()
4207 name_len = copy_path_name(pSMB->FileName, search_name); in CIFSSMBQPathInfo()
4210 params = 2 /* level */ + 4 /* reserved */ + name_len /* includes NUL */; in CIFSSMBQPathInfo()
4357 int name_len; in CIFSSMBUnixQPathInfo() local
4368 name_len = in CIFSSMBUnixQPathInfo()
4371 name_len++; /* trailing null */ in CIFSSMBUnixQPathInfo()
4372 name_len *= 2; in CIFSSMBUnixQPathInfo()
4374 name_len = copy_path_name(pSMB->FileName, searchName); in CIFSSMBUnixQPathInfo()
4377 params = 2 /* level */ + 4 /* reserved */ + name_len /* includes NUL */; in CIFSSMBUnixQPathInfo()
4440 int name_len, remap; in CIFSFindFirst() local
4456 name_len = in CIFSFindFirst()
4462 name_len *= 2; in CIFSFindFirst()
4464 pSMB->FileName[name_len] = CIFS_DIR_SEP(cifs_sb); in CIFSFindFirst()
4465 pSMB->FileName[name_len+1] = 0; in CIFSFindFirst()
4466 pSMB->FileName[name_len+2] = '*'; in CIFSFindFirst()
4467 pSMB->FileName[name_len+3] = 0; in CIFSFindFirst()
4468 name_len += 4; /* now the trailing null */ in CIFSFindFirst()
4470 pSMB->FileName[name_len] = 0; in CIFSFindFirst()
4471 pSMB->FileName[name_len+1] = 0; in CIFSFindFirst()
4472 name_len += 2; in CIFSFindFirst()
4475 name_len = copy_path_name(pSMB->FileName, searchName); in CIFSFindFirst()
4477 if (WARN_ON_ONCE(name_len > PATH_MAX-2)) in CIFSFindFirst()
4478 name_len = PATH_MAX-2; in CIFSFindFirst()
4480 pSMB->FileName[name_len-1] = CIFS_DIR_SEP(cifs_sb); in CIFSFindFirst()
4481 pSMB->FileName[name_len] = '*'; in CIFSFindFirst()
4482 pSMB->FileName[name_len+1] = 0; in CIFSFindFirst()
4483 name_len += 2; in CIFSFindFirst()
4487 params = 12 + name_len /* includes null */ ; in CIFSFindFirst()
4592 unsigned int name_len; in CIFSFindNext() local
4629 name_len = psrch_inf->resume_name_len; in CIFSFindNext()
4630 params += name_len; in CIFSFindNext()
4631 if (name_len < PATH_MAX) { in CIFSFindNext()
4632 memcpy(pSMB->ResumeFileName, psrch_inf->presume_name, name_len); in CIFSFindNext()
4633 byte_count += name_len; in CIFSFindNext()
4635 pSMB->ResumeFileName[name_len] = 0; in CIFSFindNext()
4636 pSMB->ResumeFileName[name_len+1] = 0; in CIFSFindNext()
4758 int name_len, bytes_returned; in CIFSGetSrvInodeNumber() local
4772 name_len = in CIFSGetSrvInodeNumber()
4776 name_len++; /* trailing null */ in CIFSGetSrvInodeNumber()
4777 name_len *= 2; in CIFSGetSrvInodeNumber()
4779 name_len = copy_path_name(pSMB->FileName, search_name); in CIFSGetSrvInodeNumber()
4782 params = 2 /* level */ + 4 /* rsrvd */ + name_len /* incl null */ ; in CIFSGetSrvInodeNumber()
4852 int name_len; in CIFSGetDFSRefer() local
4879 name_len = in CIFSGetDFSRefer()
4883 name_len++; /* trailing null */ in CIFSGetDFSRefer()
4884 name_len *= 2; in CIFSGetDFSRefer()
4886 name_len = copy_path_name(pSMB->RequestFileName, search_name); in CIFSGetDFSRefer()
4894 params = 2 /* level */ + name_len /*includes null */ ; in CIFSGetDFSRefer()
5519 int name_len; in CIFSSMBSetEOF() local
5534 name_len = in CIFSSMBSetEOF()
5537 name_len++; /* trailing null */ in CIFSSMBSetEOF()
5538 name_len *= 2; in CIFSSMBSetEOF()
5540 name_len = copy_path_name(pSMB->FileName, file_name); in CIFSSMBSetEOF()
5542 params = 6 + name_len; in CIFSSMBSetEOF()
5845 int name_len; in CIFSSMBSetPathInfo() local
5861 name_len = in CIFSSMBSetPathInfo()
5864 name_len++; /* trailing null */ in CIFSSMBSetPathInfo()
5865 name_len *= 2; in CIFSSMBSetPathInfo()
5867 name_len = copy_path_name(pSMB->FileName, fileName); in CIFSSMBSetPathInfo()
5870 params = 6 + name_len; in CIFSSMBSetPathInfo()
5933 int name_len;
5944 name_len =
5947 name_len++; /* trailing null */
5948 name_len *= 2;
5950 name_len = copy_path_name(pSMB->fileName, fileName);
5954 inc_rfc1001_len(pSMB, name_len + 1);
5955 pSMB->ByteCount = cpu_to_le16(name_len + 1);
6091 int name_len; in CIFSSMBUnixSetPathInfo() local
6105 name_len = in CIFSSMBUnixSetPathInfo()
6108 name_len++; /* trailing null */ in CIFSSMBUnixSetPathInfo()
6109 name_len *= 2; in CIFSSMBUnixSetPathInfo()
6111 name_len = copy_path_name(pSMB->FileName, file_name); in CIFSSMBUnixSetPathInfo()
6114 params = 6 + name_len; in CIFSSMBUnixSetPathInfo()
6285 unsigned int name_len; in CIFSSMBQAllEAs() local
6297 name_len = temp_fea->name_len; in CIFSSMBQAllEAs()
6299 list_len -= name_len + 1 + value_len; in CIFSSMBQAllEAs()
6307 if (ea_name_len == name_len && in CIFSSMBQAllEAs()
6308 memcmp(ea_name, temp_ptr, name_len) == 0) { in CIFSSMBQAllEAs()
6309 temp_ptr += name_len + 1; in CIFSSMBQAllEAs()
6322 rc += (5 + 1 + name_len); in CIFSSMBQAllEAs()
6326 memcpy(EAData, temp_ptr, name_len); in CIFSSMBQAllEAs()
6327 EAData += name_len; in CIFSSMBQAllEAs()
6339 temp_ptr += name_len + 1 + value_len; in CIFSSMBQAllEAs()
6364 int name_len; in CIFSSMBSetEA() local
6378 name_len = in CIFSSMBSetEA()
6381 name_len++; /* trailing null */ in CIFSSMBSetEA()
6382 name_len *= 2; in CIFSSMBSetEA()
6384 name_len = copy_path_name(pSMB->FileName, fileName); in CIFSSMBSetEA()
6387 params = 6 + name_len; in CIFSSMBSetEA()
6393 name_len = 0; in CIFSSMBSetEA()
6395 name_len = strnlen(ea_name, 255); in CIFSSMBSetEA()
6397 count = sizeof(*parm_data) + ea_value_len + name_len; in CIFSSMBSetEA()
6423 parm_data->list[0].name_len = (__u8)name_len; in CIFSSMBSetEA()
6426 strncpy(parm_data->list[0].name, ea_name, name_len); in CIFSSMBSetEA()
6427 parm_data->list[0].name[name_len] = 0; in CIFSSMBSetEA()
6436 memcpy(parm_data->list[0].name+name_len+1, in CIFSSMBSetEA()