Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[CIFS] Rename three structures to avoid camel case

secMode to sec_mode
and
cifsTconInfo to cifs_tcon
and
cifsSesInfo to cifs_ses

Signed-off-by: Steve French <sfrench@us.ibm.com>

+353 -353
+3 -3
fs/cifs/cache.c
··· 146 146 static uint16_t cifs_super_get_key(const void *cookie_netfs_data, void *buffer, 147 147 uint16_t maxbuf) 148 148 { 149 - const struct cifsTconInfo *tcon = cookie_netfs_data; 149 + const struct cifs_tcon *tcon = cookie_netfs_data; 150 150 char *sharename; 151 151 uint16_t len; 152 152 ··· 173 173 uint16_t maxbuf) 174 174 { 175 175 struct cifs_fscache_super_auxdata auxdata; 176 - const struct cifsTconInfo *tcon = cookie_netfs_data; 176 + const struct cifs_tcon *tcon = cookie_netfs_data; 177 177 178 178 memset(&auxdata, 0, sizeof(auxdata)); 179 179 auxdata.resource_id = tcon->resource_id; ··· 192 192 uint16_t datalen) 193 193 { 194 194 struct cifs_fscache_super_auxdata auxdata; 195 - const struct cifsTconInfo *tcon = cookie_netfs_data; 195 + const struct cifs_tcon *tcon = cookie_netfs_data; 196 196 197 197 if (datalen != sizeof(auxdata)) 198 198 return FSCACHE_CHECKAUX_OBSOLETE;
+13 -13
fs/cifs/cifs_debug.c
··· 110 110 struct list_head *tmp1, *tmp2, *tmp3; 111 111 struct mid_q_entry *mid_entry; 112 112 struct TCP_Server_Info *server; 113 - struct cifsSesInfo *ses; 114 - struct cifsTconInfo *tcon; 113 + struct cifs_ses *ses; 114 + struct cifs_tcon *tcon; 115 115 int i, j; 116 116 __u32 dev_type; 117 117 ··· 152 152 tcp_ses_list); 153 153 i++; 154 154 list_for_each(tmp2, &server->smb_ses_list) { 155 - ses = list_entry(tmp2, struct cifsSesInfo, 155 + ses = list_entry(tmp2, struct cifs_ses, 156 156 smb_ses_list); 157 157 if ((ses->serverDomain == NULL) || 158 158 (ses->serverOS == NULL) || ··· 171 171 seq_printf(m, "TCP status: %d\n\tLocal Users To " 172 172 "Server: %d SecMode: 0x%x Req On Wire: %d", 173 173 server->tcpStatus, server->srv_count, 174 - server->secMode, 174 + server->sec_mode, 175 175 atomic_read(&server->inFlight)); 176 176 177 177 #ifdef CONFIG_CIFS_STATS2 ··· 183 183 seq_puts(m, "\n\tShares:"); 184 184 j = 0; 185 185 list_for_each(tmp3, &ses->tcon_list) { 186 - tcon = list_entry(tmp3, struct cifsTconInfo, 186 + tcon = list_entry(tmp3, struct cifs_tcon, 187 187 tcon_list); 188 188 ++j; 189 189 dev_type = le32_to_cpu(tcon->fsDevInfo.DeviceType); ··· 256 256 int rc; 257 257 struct list_head *tmp1, *tmp2, *tmp3; 258 258 struct TCP_Server_Info *server; 259 - struct cifsSesInfo *ses; 260 - struct cifsTconInfo *tcon; 259 + struct cifs_ses *ses; 260 + struct cifs_tcon *tcon; 261 261 262 262 rc = get_user(c, buffer); 263 263 if (rc) ··· 273 273 server = list_entry(tmp1, struct TCP_Server_Info, 274 274 tcp_ses_list); 275 275 list_for_each(tmp2, &server->smb_ses_list) { 276 - ses = list_entry(tmp2, struct cifsSesInfo, 276 + ses = list_entry(tmp2, struct cifs_ses, 277 277 smb_ses_list); 278 278 list_for_each(tmp3, &ses->tcon_list) { 279 279 tcon = list_entry(tmp3, 280 - struct cifsTconInfo, 280 + struct cifs_tcon, 281 281 tcon_list); 282 282 atomic_set(&tcon->num_smbs_sent, 0); 283 283 atomic_set(&tcon->num_writes, 0); ··· 312 312 int i; 313 313 struct list_head *tmp1, *tmp2, *tmp3; 314 314 struct TCP_Server_Info *server; 315 - struct cifsSesInfo *ses; 316 - struct cifsTconInfo *tcon; 315 + struct cifs_ses *ses; 316 + struct cifs_tcon *tcon; 317 317 318 318 seq_printf(m, 319 319 "Resources in use\nCIFS Session: %d\n", ··· 346 346 server = list_entry(tmp1, struct TCP_Server_Info, 347 347 tcp_ses_list); 348 348 list_for_each(tmp2, &server->smb_ses_list) { 349 - ses = list_entry(tmp2, struct cifsSesInfo, 349 + ses = list_entry(tmp2, struct cifs_ses, 350 350 smb_ses_list); 351 351 list_for_each(tmp3, &ses->tcon_list) { 352 352 tcon = list_entry(tmp3, 353 - struct cifsTconInfo, 353 + struct cifs_tcon, 354 354 tcon_list); 355 355 i++; 356 356 seq_printf(m, "\n%d) %s", i, tcon->treeName);
+1 -1
fs/cifs/cifs_dfs_ref.c
··· 272 272 struct dfs_info3_param *referrals = NULL; 273 273 unsigned int num_referrals = 0; 274 274 struct cifs_sb_info *cifs_sb; 275 - struct cifsSesInfo *ses; 275 + struct cifs_ses *ses; 276 276 char *full_path; 277 277 int xid, i; 278 278 int rc;
+1 -1
fs/cifs/cifs_spnego.c
··· 95 95 96 96 /* get a key struct with a SPNEGO security blob, suitable for session setup */ 97 97 struct key * 98 - cifs_get_spnego_key(struct cifsSesInfo *sesInfo) 98 + cifs_get_spnego_key(struct cifs_ses *sesInfo) 99 99 { 100 100 struct TCP_Server_Info *server = sesInfo->server; 101 101 struct sockaddr_in *sa = (struct sockaddr_in *) &server->dstaddr;
+1 -1
fs/cifs/cifs_spnego.h
··· 41 41 42 42 #ifdef __KERNEL__ 43 43 extern struct key_type cifs_spnego_key_type; 44 - extern struct key *cifs_get_spnego_key(struct cifsSesInfo *sesInfo); 44 + extern struct key *cifs_get_spnego_key(struct cifs_ses *sesInfo); 45 45 #endif /* KERNEL */ 46 46 47 47 #endif /* _CIFS_SPNEGO_H */
+2 -2
fs/cifs/cifsacl.c
··· 945 945 int oplock = 0; 946 946 int xid, rc; 947 947 __u16 fid; 948 - struct cifsTconInfo *tcon; 948 + struct cifs_tcon *tcon; 949 949 struct tcon_link *tlink = cifs_sb_tlink(cifs_sb); 950 950 951 951 if (IS_ERR(tlink)) ··· 1013 1013 int oplock = 0; 1014 1014 int xid, rc; 1015 1015 __u16 fid; 1016 - struct cifsTconInfo *tcon; 1016 + struct cifs_tcon *tcon; 1017 1017 struct tcon_link *tlink = cifs_sb_tlink(cifs_sb); 1018 1018 1019 1019 if (IS_ERR(tlink))
+7 -7
fs/cifs/cifsencrypt.c
··· 229 229 } 230 230 231 231 /* first calculate 24 bytes ntlm response and then 16 byte session key */ 232 - int setup_ntlm_response(struct cifsSesInfo *ses) 232 + int setup_ntlm_response(struct cifs_ses *ses) 233 233 { 234 234 int rc = 0; 235 235 unsigned int temp_len = CIFS_SESS_KEY_SIZE + CIFS_AUTH_RESP_SIZE; ··· 312 312 * Allocate domain name which gets freed when session struct is deallocated. 313 313 */ 314 314 static int 315 - build_avpair_blob(struct cifsSesInfo *ses, const struct nls_table *nls_cp) 315 + build_avpair_blob(struct cifs_ses *ses, const struct nls_table *nls_cp) 316 316 { 317 317 unsigned int dlen; 318 318 unsigned int wlen; ··· 400 400 * about target string i.e. for some, just user name might suffice. 401 401 */ 402 402 static int 403 - find_domain_name(struct cifsSesInfo *ses, const struct nls_table *nls_cp) 403 + find_domain_name(struct cifs_ses *ses, const struct nls_table *nls_cp) 404 404 { 405 405 unsigned int attrsize; 406 406 unsigned int type; ··· 445 445 return 0; 446 446 } 447 447 448 - static int calc_ntlmv2_hash(struct cifsSesInfo *ses, char *ntlmv2_hash, 448 + static int calc_ntlmv2_hash(struct cifs_ses *ses, char *ntlmv2_hash, 449 449 const struct nls_table *nls_cp) 450 450 { 451 451 int rc = 0; ··· 527 527 } 528 528 529 529 static int 530 - CalcNTLMv2_response(const struct cifsSesInfo *ses, char *ntlmv2_hash) 530 + CalcNTLMv2_response(const struct cifs_ses *ses, char *ntlmv2_hash) 531 531 { 532 532 int rc; 533 533 unsigned int offset = CIFS_SESS_KEY_SIZE + 8; ··· 563 563 564 564 565 565 int 566 - setup_ntlmv2_rsp(struct cifsSesInfo *ses, const struct nls_table *nls_cp) 566 + setup_ntlmv2_rsp(struct cifs_ses *ses, const struct nls_table *nls_cp) 567 567 { 568 568 int rc; 569 569 int baselen; ··· 649 649 } 650 650 651 651 int 652 - calc_seckey(struct cifsSesInfo *ses) 652 + calc_seckey(struct cifs_ses *ses) 653 653 { 654 654 int rc; 655 655 struct crypto_blkcipher *tfm_arc4;
+3 -3
fs/cifs/cifsfs.c
··· 208 208 { 209 209 struct super_block *sb = dentry->d_sb; 210 210 struct cifs_sb_info *cifs_sb = CIFS_SB(sb); 211 - struct cifsTconInfo *tcon = cifs_sb_master_tcon(cifs_sb); 211 + struct cifs_tcon *tcon = cifs_sb_master_tcon(cifs_sb); 212 212 int rc = -EOPNOTSUPP; 213 213 int xid; 214 214 ··· 361 361 cifs_show_options(struct seq_file *s, struct vfsmount *m) 362 362 { 363 363 struct cifs_sb_info *cifs_sb = CIFS_SB(m->mnt_sb); 364 - struct cifsTconInfo *tcon = cifs_sb_master_tcon(cifs_sb); 364 + struct cifs_tcon *tcon = cifs_sb_master_tcon(cifs_sb); 365 365 struct sockaddr *srcaddr; 366 366 srcaddr = (struct sockaddr *)&tcon->ses->server->srcaddr; 367 367 ··· 461 461 static void cifs_umount_begin(struct super_block *sb) 462 462 { 463 463 struct cifs_sb_info *cifs_sb = CIFS_SB(sb); 464 - struct cifsTconInfo *tcon; 464 + struct cifs_tcon *tcon; 465 465 466 466 if (cifs_sb == NULL) 467 467 return;
+11 -11
fs/cifs/cifsglob.h
··· 254 254 struct mutex srv_mutex; 255 255 struct task_struct *tsk; 256 256 char server_GUID[16]; 257 - char secMode; 257 + char sec_mode; 258 258 bool session_estab; /* mark when very first sess is established */ 259 259 u16 dialect; /* dialect index that server chose */ 260 260 enum securityEnum secType; ··· 329 329 /* 330 330 * Session structure. One of these for each uid session with a particular host 331 331 */ 332 - struct cifsSesInfo { 332 + struct cifs_ses { 333 333 struct list_head smb_ses_list; 334 334 struct list_head tcon_list; 335 335 struct mutex session_mutex; ··· 369 369 * there is one of these for each connection to a resource on a particular 370 370 * session 371 371 */ 372 - struct cifsTconInfo { 372 + struct cifs_tcon { 373 373 struct list_head tcon_list; 374 374 int tc_count; 375 375 struct list_head openFileList; 376 - struct cifsSesInfo *ses; /* pointer to session associated with */ 376 + struct cifs_ses *ses; /* pointer to session associated with */ 377 377 char treeName[MAX_TREE_SIZE + 1]; /* UNC name of resource in ASCII */ 378 378 char *nativeFileSystem; 379 379 char *password; /* for share-level security */ ··· 455 455 #define TCON_LINK_IN_TREE 2 456 456 unsigned long tl_time; 457 457 atomic_t tl_count; 458 - struct cifsTconInfo *tl_tcon; 458 + struct cifs_tcon *tl_tcon; 459 459 }; 460 460 461 461 extern struct tcon_link *cifs_sb_tlink(struct cifs_sb_info *cifs_sb); 462 462 463 - static inline struct cifsTconInfo * 463 + static inline struct cifs_tcon * 464 464 tlink_tcon(struct tcon_link *tlink) 465 465 { 466 466 return tlink->tl_tcon; ··· 477 477 } 478 478 479 479 /* This function is always expected to succeed */ 480 - extern struct cifsTconInfo *cifs_sb_master_tcon(struct cifs_sb_info *cifs_sb); 480 + extern struct cifs_tcon *cifs_sb_master_tcon(struct cifs_sb_info *cifs_sb); 481 481 482 482 /* 483 483 * This info hangs off the cifsFileInfo structure, pointed to by llist. ··· 535 535 __u32 pid; 536 536 __u64 offset; 537 537 unsigned int length; 538 - struct cifsTconInfo *tcon; 538 + struct cifs_tcon *tcon; 539 539 }; 540 540 541 541 /* ··· 615 615 #ifdef CONFIG_CIFS_STATS 616 616 #define cifs_stats_inc atomic_inc 617 617 618 - static inline void cifs_stats_bytes_written(struct cifsTconInfo *tcon, 618 + static inline void cifs_stats_bytes_written(struct cifs_tcon *tcon, 619 619 unsigned int bytes) 620 620 { 621 621 if (bytes) { ··· 625 625 } 626 626 } 627 627 628 - static inline void cifs_stats_bytes_read(struct cifsTconInfo *tcon, 628 + static inline void cifs_stats_bytes_read(struct cifs_tcon *tcon, 629 629 unsigned int bytes) 630 630 { 631 631 spin_lock(&tcon->stat_lock); ··· 675 675 struct oplock_q_entry { 676 676 struct list_head qhead; 677 677 struct inode *pinode; 678 - struct cifsTconInfo *tcon; 678 + struct cifs_tcon *tcon; 679 679 __u16 netfid; 680 680 }; 681 681
+76 -76
fs/cifs/cifsproto.h
··· 59 59 extern char *build_path_from_dentry(struct dentry *); 60 60 extern char *cifs_build_path_to_root(struct smb_vol *vol, 61 61 struct cifs_sb_info *cifs_sb, 62 - struct cifsTconInfo *tcon); 62 + struct cifs_tcon *tcon); 63 63 extern char *build_wildcard_path_from_dentry(struct dentry *direntry); 64 64 extern char *cifs_compose_mount_options(const char *sb_mountdata, 65 65 const char *fullpath, const struct dfs_info3_param *ref, ··· 71 71 extern int cifs_call_async(struct TCP_Server_Info *server, struct kvec *iov, 72 72 unsigned int nvec, mid_callback_t *callback, 73 73 void *cbdata, bool ignore_pend); 74 - extern int SendReceive(const unsigned int /* xid */ , struct cifsSesInfo *, 74 + extern int SendReceive(const unsigned int /* xid */ , struct cifs_ses *, 75 75 struct smb_hdr * /* input */ , 76 76 struct smb_hdr * /* out */ , 77 77 int * /* bytes returned */ , const int long_op); 78 - extern int SendReceiveNoRsp(const unsigned int xid, struct cifsSesInfo *ses, 78 + extern int SendReceiveNoRsp(const unsigned int xid, struct cifs_ses *ses, 79 79 struct smb_hdr *in_buf, int flags); 80 80 extern int cifs_check_receive(struct mid_q_entry *mid, 81 81 struct TCP_Server_Info *server, bool log_error); 82 - extern int SendReceive2(const unsigned int /* xid */ , struct cifsSesInfo *, 82 + extern int SendReceive2(const unsigned int /* xid */ , struct cifs_ses *, 83 83 struct kvec *, int /* nvec to send */, 84 84 int * /* type of buf returned */ , const int flags); 85 85 extern int SendReceiveBlockingLock(const unsigned int xid, 86 - struct cifsTconInfo *ptcon, 86 + struct cifs_tcon *ptcon, 87 87 struct smb_hdr *in_buf , 88 88 struct smb_hdr *out_buf, 89 89 int *bytes_returned); ··· 104 104 const unsigned short int port); 105 105 extern int map_smb_to_linux_error(struct smb_hdr *smb, bool logErr); 106 106 extern void header_assemble(struct smb_hdr *, char /* command */ , 107 - const struct cifsTconInfo *, int /* length of 107 + const struct cifs_tcon *, int /* length of 108 108 fixed section (word count) in two byte units */); 109 109 extern int small_smb_init_no_tc(const int smb_cmd, const int wct, 110 - struct cifsSesInfo *ses, 110 + struct cifs_ses *ses, 111 111 void **request_buf); 112 - extern int CIFS_SessSetup(unsigned int xid, struct cifsSesInfo *ses, 112 + extern int CIFS_SessSetup(unsigned int xid, struct cifs_ses *ses, 113 113 const struct nls_table *nls_cp); 114 114 extern __u16 GetNextMid(struct TCP_Server_Info *server); 115 115 extern struct timespec cifs_NTtimeToUnix(__le64 utc_nanoseconds_since_1601); ··· 165 165 void cifs_proc_clean(void); 166 166 167 167 extern int cifs_negotiate_protocol(unsigned int xid, 168 - struct cifsSesInfo *ses); 169 - extern int cifs_setup_session(unsigned int xid, struct cifsSesInfo *ses, 168 + struct cifs_ses *ses); 169 + extern int cifs_setup_session(unsigned int xid, struct cifs_ses *ses, 170 170 struct nls_table *nls_info); 171 - extern int CIFSSMBNegotiate(unsigned int xid, struct cifsSesInfo *ses); 171 + extern int CIFSSMBNegotiate(unsigned int xid, struct cifs_ses *ses); 172 172 173 - extern int CIFSTCon(unsigned int xid, struct cifsSesInfo *ses, 174 - const char *tree, struct cifsTconInfo *tcon, 173 + extern int CIFSTCon(unsigned int xid, struct cifs_ses *ses, 174 + const char *tree, struct cifs_tcon *tcon, 175 175 const struct nls_table *); 176 176 177 - extern int CIFSFindFirst(const int xid, struct cifsTconInfo *tcon, 177 + extern int CIFSFindFirst(const int xid, struct cifs_tcon *tcon, 178 178 const char *searchName, const struct nls_table *nls_codepage, 179 179 __u16 *searchHandle, struct cifs_search_info *psrch_inf, 180 180 int map, const char dirsep); 181 181 182 - extern int CIFSFindNext(const int xid, struct cifsTconInfo *tcon, 182 + extern int CIFSFindNext(const int xid, struct cifs_tcon *tcon, 183 183 __u16 searchHandle, struct cifs_search_info *psrch_inf); 184 184 185 - extern int CIFSFindClose(const int, struct cifsTconInfo *tcon, 185 + extern int CIFSFindClose(const int, struct cifs_tcon *tcon, 186 186 const __u16 search_handle); 187 187 188 - extern int CIFSSMBQFileInfo(const int xid, struct cifsTconInfo *tcon, 188 + extern int CIFSSMBQFileInfo(const int xid, struct cifs_tcon *tcon, 189 189 u16 netfid, FILE_ALL_INFO *pFindData); 190 - extern int CIFSSMBQPathInfo(const int xid, struct cifsTconInfo *tcon, 190 + extern int CIFSSMBQPathInfo(const int xid, struct cifs_tcon *tcon, 191 191 const unsigned char *searchName, 192 192 FILE_ALL_INFO *findData, 193 193 int legacy /* whether to use old info level */, 194 194 const struct nls_table *nls_codepage, int remap); 195 - extern int SMBQueryInformation(const int xid, struct cifsTconInfo *tcon, 195 + extern int SMBQueryInformation(const int xid, struct cifs_tcon *tcon, 196 196 const unsigned char *searchName, 197 197 FILE_ALL_INFO *findData, 198 198 const struct nls_table *nls_codepage, int remap); 199 199 200 - extern int CIFSSMBUnixQFileInfo(const int xid, struct cifsTconInfo *tcon, 200 + extern int CIFSSMBUnixQFileInfo(const int xid, struct cifs_tcon *tcon, 201 201 u16 netfid, FILE_UNIX_BASIC_INFO *pFindData); 202 202 extern int CIFSSMBUnixQPathInfo(const int xid, 203 - struct cifsTconInfo *tcon, 203 + struct cifs_tcon *tcon, 204 204 const unsigned char *searchName, 205 205 FILE_UNIX_BASIC_INFO *pFindData, 206 206 const struct nls_table *nls_codepage, int remap); 207 207 208 - extern int CIFSGetDFSRefer(const int xid, struct cifsSesInfo *ses, 208 + extern int CIFSGetDFSRefer(const int xid, struct cifs_ses *ses, 209 209 const unsigned char *searchName, 210 210 struct dfs_info3_param **target_nodes, 211 211 unsigned int *number_of_nodes_in_array, 212 212 const struct nls_table *nls_codepage, int remap); 213 213 214 - extern int get_dfs_path(int xid, struct cifsSesInfo *pSesInfo, 214 + extern int get_dfs_path(int xid, struct cifs_ses *pSesInfo, 215 215 const char *old_path, 216 216 const struct nls_table *nls_codepage, 217 217 unsigned int *pnum_referrals, 218 218 struct dfs_info3_param **preferrals, 219 219 int remap); 220 - extern void reset_cifs_unix_caps(int xid, struct cifsTconInfo *tcon, 220 + extern void reset_cifs_unix_caps(int xid, struct cifs_tcon *tcon, 221 221 struct super_block *sb, struct smb_vol *vol); 222 - extern int CIFSSMBQFSInfo(const int xid, struct cifsTconInfo *tcon, 222 + extern int CIFSSMBQFSInfo(const int xid, struct cifs_tcon *tcon, 223 223 struct kstatfs *FSData); 224 - extern int SMBOldQFSInfo(const int xid, struct cifsTconInfo *tcon, 224 + extern int SMBOldQFSInfo(const int xid, struct cifs_tcon *tcon, 225 225 struct kstatfs *FSData); 226 - extern int CIFSSMBSetFSUnixInfo(const int xid, struct cifsTconInfo *tcon, 226 + extern int CIFSSMBSetFSUnixInfo(const int xid, struct cifs_tcon *tcon, 227 227 __u64 cap); 228 228 229 229 extern int CIFSSMBQFSAttributeInfo(const int xid, 230 - struct cifsTconInfo *tcon); 231 - extern int CIFSSMBQFSDeviceInfo(const int xid, struct cifsTconInfo *tcon); 232 - extern int CIFSSMBQFSUnixInfo(const int xid, struct cifsTconInfo *tcon); 233 - extern int CIFSSMBQFSPosixInfo(const int xid, struct cifsTconInfo *tcon, 230 + struct cifs_tcon *tcon); 231 + extern int CIFSSMBQFSDeviceInfo(const int xid, struct cifs_tcon *tcon); 232 + extern int CIFSSMBQFSUnixInfo(const int xid, struct cifs_tcon *tcon); 233 + extern int CIFSSMBQFSPosixInfo(const int xid, struct cifs_tcon *tcon, 234 234 struct kstatfs *FSData); 235 235 236 - extern int CIFSSMBSetPathInfo(const int xid, struct cifsTconInfo *tcon, 236 + extern int CIFSSMBSetPathInfo(const int xid, struct cifs_tcon *tcon, 237 237 const char *fileName, const FILE_BASIC_INFO *data, 238 238 const struct nls_table *nls_codepage, 239 239 int remap_special_chars); 240 - extern int CIFSSMBSetFileInfo(const int xid, struct cifsTconInfo *tcon, 240 + extern int CIFSSMBSetFileInfo(const int xid, struct cifs_tcon *tcon, 241 241 const FILE_BASIC_INFO *data, __u16 fid, 242 242 __u32 pid_of_opener); 243 - extern int CIFSSMBSetFileDisposition(const int xid, struct cifsTconInfo *tcon, 243 + extern int CIFSSMBSetFileDisposition(const int xid, struct cifs_tcon *tcon, 244 244 bool delete_file, __u16 fid, __u32 pid_of_opener); 245 245 #if 0 246 - extern int CIFSSMBSetAttrLegacy(int xid, struct cifsTconInfo *tcon, 246 + extern int CIFSSMBSetAttrLegacy(int xid, struct cifs_tcon *tcon, 247 247 char *fileName, __u16 dos_attributes, 248 248 const struct nls_table *nls_codepage); 249 249 #endif /* possibly unneeded function */ 250 - extern int CIFSSMBSetEOF(const int xid, struct cifsTconInfo *tcon, 250 + extern int CIFSSMBSetEOF(const int xid, struct cifs_tcon *tcon, 251 251 const char *fileName, __u64 size, 252 252 bool setAllocationSizeFlag, 253 253 const struct nls_table *nls_codepage, 254 254 int remap_special_chars); 255 - extern int CIFSSMBSetFileSize(const int xid, struct cifsTconInfo *tcon, 255 + extern int CIFSSMBSetFileSize(const int xid, struct cifs_tcon *tcon, 256 256 __u64 size, __u16 fileHandle, __u32 opener_pid, 257 257 bool AllocSizeFlag); 258 258 ··· 266 266 dev_t device; 267 267 }; 268 268 269 - extern int CIFSSMBUnixSetFileInfo(const int xid, struct cifsTconInfo *tcon, 269 + extern int CIFSSMBUnixSetFileInfo(const int xid, struct cifs_tcon *tcon, 270 270 const struct cifs_unix_set_info_args *args, 271 271 u16 fid, u32 pid_of_opener); 272 272 273 - extern int CIFSSMBUnixSetPathInfo(const int xid, struct cifsTconInfo *pTcon, 273 + extern int CIFSSMBUnixSetPathInfo(const int xid, struct cifs_tcon *pTcon, 274 274 char *fileName, 275 275 const struct cifs_unix_set_info_args *args, 276 276 const struct nls_table *nls_codepage, 277 277 int remap_special_chars); 278 278 279 - extern int CIFSSMBMkDir(const int xid, struct cifsTconInfo *tcon, 279 + extern int CIFSSMBMkDir(const int xid, struct cifs_tcon *tcon, 280 280 const char *newName, 281 281 const struct nls_table *nls_codepage, 282 282 int remap_special_chars); 283 - extern int CIFSSMBRmDir(const int xid, struct cifsTconInfo *tcon, 283 + extern int CIFSSMBRmDir(const int xid, struct cifs_tcon *tcon, 284 284 const char *name, const struct nls_table *nls_codepage, 285 285 int remap_special_chars); 286 - extern int CIFSPOSIXDelFile(const int xid, struct cifsTconInfo *tcon, 286 + extern int CIFSPOSIXDelFile(const int xid, struct cifs_tcon *tcon, 287 287 const char *name, __u16 type, 288 288 const struct nls_table *nls_codepage, 289 289 int remap_special_chars); 290 - extern int CIFSSMBDelFile(const int xid, struct cifsTconInfo *tcon, 290 + extern int CIFSSMBDelFile(const int xid, struct cifs_tcon *tcon, 291 291 const char *name, 292 292 const struct nls_table *nls_codepage, 293 293 int remap_special_chars); 294 - extern int CIFSSMBRename(const int xid, struct cifsTconInfo *tcon, 294 + extern int CIFSSMBRename(const int xid, struct cifs_tcon *tcon, 295 295 const char *fromName, const char *toName, 296 296 const struct nls_table *nls_codepage, 297 297 int remap_special_chars); 298 - extern int CIFSSMBRenameOpenFile(const int xid, struct cifsTconInfo *pTcon, 298 + extern int CIFSSMBRenameOpenFile(const int xid, struct cifs_tcon *pTcon, 299 299 int netfid, const char *target_name, 300 300 const struct nls_table *nls_codepage, 301 301 int remap_special_chars); 302 302 extern int CIFSCreateHardLink(const int xid, 303 - struct cifsTconInfo *tcon, 303 + struct cifs_tcon *tcon, 304 304 const char *fromName, const char *toName, 305 305 const struct nls_table *nls_codepage, 306 306 int remap_special_chars); 307 307 extern int CIFSUnixCreateHardLink(const int xid, 308 - struct cifsTconInfo *tcon, 308 + struct cifs_tcon *tcon, 309 309 const char *fromName, const char *toName, 310 310 const struct nls_table *nls_codepage, 311 311 int remap_special_chars); 312 312 extern int CIFSUnixCreateSymLink(const int xid, 313 - struct cifsTconInfo *tcon, 313 + struct cifs_tcon *tcon, 314 314 const char *fromName, const char *toName, 315 315 const struct nls_table *nls_codepage); 316 316 extern int CIFSSMBUnixQuerySymLink(const int xid, 317 - struct cifsTconInfo *tcon, 317 + struct cifs_tcon *tcon, 318 318 const unsigned char *searchName, char **syminfo, 319 319 const struct nls_table *nls_codepage); 320 320 #ifdef CONFIG_CIFS_SYMLINK_EXPERIMENTAL 321 321 extern int CIFSSMBQueryReparseLinkInfo(const int xid, 322 - struct cifsTconInfo *tcon, 322 + struct cifs_tcon *tcon, 323 323 const unsigned char *searchName, 324 324 char *symlinkinfo, const int buflen, __u16 fid, 325 325 const struct nls_table *nls_codepage); 326 326 #endif /* temporarily unused until cifs_symlink fixed */ 327 - extern int CIFSSMBOpen(const int xid, struct cifsTconInfo *tcon, 327 + extern int CIFSSMBOpen(const int xid, struct cifs_tcon *tcon, 328 328 const char *fileName, const int disposition, 329 329 const int access_flags, const int omode, 330 330 __u16 *netfid, int *pOplock, FILE_ALL_INFO *, 331 331 const struct nls_table *nls_codepage, int remap); 332 - extern int SMBLegacyOpen(const int xid, struct cifsTconInfo *tcon, 332 + extern int SMBLegacyOpen(const int xid, struct cifs_tcon *tcon, 333 333 const char *fileName, const int disposition, 334 334 const int access_flags, const int omode, 335 335 __u16 *netfid, int *pOplock, FILE_ALL_INFO *, 336 336 const struct nls_table *nls_codepage, int remap); 337 - extern int CIFSPOSIXCreate(const int xid, struct cifsTconInfo *tcon, 337 + extern int CIFSPOSIXCreate(const int xid, struct cifs_tcon *tcon, 338 338 u32 posix_flags, __u64 mode, __u16 *netfid, 339 339 FILE_UNIX_BASIC_INFO *pRetData, 340 340 __u32 *pOplock, const char *name, 341 341 const struct nls_table *nls_codepage, int remap); 342 - extern int CIFSSMBClose(const int xid, struct cifsTconInfo *tcon, 342 + extern int CIFSSMBClose(const int xid, struct cifs_tcon *tcon, 343 343 const int smb_file_id); 344 344 345 - extern int CIFSSMBFlush(const int xid, struct cifsTconInfo *tcon, 345 + extern int CIFSSMBFlush(const int xid, struct cifs_tcon *tcon, 346 346 const int smb_file_id); 347 347 348 348 extern int CIFSSMBRead(const int xid, struct cifs_io_parms *io_parms, ··· 354 354 extern int CIFSSMBWrite2(const int xid, struct cifs_io_parms *io_parms, 355 355 unsigned int *nbytes, struct kvec *iov, const int nvec, 356 356 const int long_op); 357 - extern int CIFSGetSrvInodeNumber(const int xid, struct cifsTconInfo *tcon, 357 + extern int CIFSGetSrvInodeNumber(const int xid, struct cifs_tcon *tcon, 358 358 const unsigned char *searchName, __u64 *inode_number, 359 359 const struct nls_table *nls_codepage, 360 360 int remap_special_chars); 361 361 362 - extern int CIFSSMBLock(const int xid, struct cifsTconInfo *tcon, 362 + extern int CIFSSMBLock(const int xid, struct cifs_tcon *tcon, 363 363 const __u16 netfid, const __u64 len, 364 364 const __u64 offset, const __u32 numUnlock, 365 365 const __u32 numLock, const __u8 lockType, 366 366 const bool waitFlag, const __u8 oplock_level); 367 - extern int CIFSSMBPosixLock(const int xid, struct cifsTconInfo *tcon, 367 + extern int CIFSSMBPosixLock(const int xid, struct cifs_tcon *tcon, 368 368 const __u16 smb_file_id, const int get_flag, 369 369 const __u64 len, struct file_lock *, 370 370 const __u16 lock_type, const bool waitFlag); 371 - extern int CIFSSMBTDis(const int xid, struct cifsTconInfo *tcon); 371 + extern int CIFSSMBTDis(const int xid, struct cifs_tcon *tcon); 372 372 extern int CIFSSMBEcho(struct TCP_Server_Info *server); 373 - extern int CIFSSMBLogoff(const int xid, struct cifsSesInfo *ses); 373 + extern int CIFSSMBLogoff(const int xid, struct cifs_ses *ses); 374 374 375 - extern struct cifsSesInfo *sesInfoAlloc(void); 376 - extern void sesInfoFree(struct cifsSesInfo *); 377 - extern struct cifsTconInfo *tconInfoAlloc(void); 378 - extern void tconInfoFree(struct cifsTconInfo *); 375 + extern struct cifs_ses *sesInfoAlloc(void); 376 + extern void sesInfoFree(struct cifs_ses *); 377 + extern struct cifs_tcon *tconInfoAlloc(void); 378 + extern void tconInfoFree(struct cifs_tcon *); 379 379 380 380 extern int cifs_sign_smb(struct smb_hdr *, struct TCP_Server_Info *, __u32 *); 381 381 extern int cifs_sign_smb2(struct kvec *iov, int n_vec, struct TCP_Server_Info *, ··· 384 384 struct TCP_Server_Info *server, 385 385 __u32 expected_sequence_number); 386 386 extern int SMBNTencrypt(unsigned char *, unsigned char *, unsigned char *); 387 - extern int setup_ntlm_response(struct cifsSesInfo *); 388 - extern int setup_ntlmv2_rsp(struct cifsSesInfo *, const struct nls_table *); 387 + extern int setup_ntlm_response(struct cifs_ses *); 388 + extern int setup_ntlmv2_rsp(struct cifs_ses *, const struct nls_table *); 389 389 extern int cifs_crypto_shash_allocate(struct TCP_Server_Info *); 390 390 extern void cifs_crypto_shash_release(struct TCP_Server_Info *); 391 - extern int calc_seckey(struct cifsSesInfo *); 391 + extern int calc_seckey(struct cifs_ses *); 392 392 393 393 #ifdef CONFIG_CIFS_WEAK_PW_HASH 394 394 extern int calc_lanman_hash(const char *password, const char *cryptkey, 395 395 bool encrypt, char *lnm_session_key); 396 396 #endif /* CIFS_WEAK_PW_HASH */ 397 397 #ifdef CONFIG_CIFS_DNOTIFY_EXPERIMENTAL /* unused temporarily */ 398 - extern int CIFSSMBNotify(const int xid, struct cifsTconInfo *tcon, 398 + extern int CIFSSMBNotify(const int xid, struct cifs_tcon *tcon, 399 399 const int notify_subdirs, const __u16 netfid, 400 400 __u32 filter, struct file *file, int multishot, 401 401 const struct nls_table *nls_codepage); 402 402 #endif /* was needed for dnotify, and will be needed for inotify when VFS fix */ 403 403 extern int CIFSSMBCopy(int xid, 404 - struct cifsTconInfo *source_tcon, 404 + struct cifs_tcon *source_tcon, 405 405 const char *fromName, 406 406 const __u16 target_tid, 407 407 const char *toName, const int flags, 408 408 const struct nls_table *nls_codepage, 409 409 int remap_special_chars); 410 - extern ssize_t CIFSSMBQAllEAs(const int xid, struct cifsTconInfo *tcon, 410 + extern ssize_t CIFSSMBQAllEAs(const int xid, struct cifs_tcon *tcon, 411 411 const unsigned char *searchName, 412 412 const unsigned char *ea_name, char *EAData, 413 413 size_t bufsize, const struct nls_table *nls_codepage, 414 414 int remap_special_chars); 415 - extern int CIFSSMBSetEA(const int xid, struct cifsTconInfo *tcon, 415 + extern int CIFSSMBSetEA(const int xid, struct cifs_tcon *tcon, 416 416 const char *fileName, const char *ea_name, 417 417 const void *ea_value, const __u16 ea_value_len, 418 418 const struct nls_table *nls_codepage, int remap_special_chars); 419 - extern int CIFSSMBGetCIFSACL(const int xid, struct cifsTconInfo *tcon, 419 + extern int CIFSSMBGetCIFSACL(const int xid, struct cifs_tcon *tcon, 420 420 __u16 fid, struct cifs_ntsd **acl_inf, __u32 *buflen); 421 - extern int CIFSSMBSetCIFSACL(const int, struct cifsTconInfo *, __u16, 421 + extern int CIFSSMBSetCIFSACL(const int, struct cifs_tcon *, __u16, 422 422 struct cifs_ntsd *, __u32); 423 - extern int CIFSSMBGetPosixACL(const int xid, struct cifsTconInfo *tcon, 423 + extern int CIFSSMBGetPosixACL(const int xid, struct cifs_tcon *tcon, 424 424 const unsigned char *searchName, 425 425 char *acl_inf, const int buflen, const int acl_type, 426 426 const struct nls_table *nls_codepage, int remap_special_chars); 427 - extern int CIFSSMBSetPosixACL(const int xid, struct cifsTconInfo *tcon, 427 + extern int CIFSSMBSetPosixACL(const int xid, struct cifs_tcon *tcon, 428 428 const unsigned char *fileName, 429 429 const char *local_acl, const int buflen, const int acl_type, 430 430 const struct nls_table *nls_codepage, int remap_special_chars); 431 - extern int CIFSGetExtAttr(const int xid, struct cifsTconInfo *tcon, 431 + extern int CIFSGetExtAttr(const int xid, struct cifs_tcon *tcon, 432 432 const int netfid, __u64 *pExtAttrBits, __u64 *pMask); 433 433 extern void cifs_autodisable_serverino(struct cifs_sb_info *cifs_sb); 434 434 extern bool CIFSCouldBeMFSymlink(const struct cifs_fattr *fattr);
+83 -83
fs/cifs/cifssmb.c
··· 85 85 86 86 /* Mark as invalid, all open files on tree connections since they 87 87 were closed when session to server was lost */ 88 - static void mark_open_files_invalid(struct cifsTconInfo *pTcon) 88 + static void mark_open_files_invalid(struct cifs_tcon *pTcon) 89 89 { 90 90 struct cifsFileInfo *open_file = NULL; 91 91 struct list_head *tmp; ··· 105 105 106 106 /* reconnect the socket, tcon, and smb session if needed */ 107 107 static int 108 - cifs_reconnect_tcon(struct cifsTconInfo *tcon, int smb_command) 108 + cifs_reconnect_tcon(struct cifs_tcon *tcon, int smb_command) 109 109 { 110 110 int rc = 0; 111 - struct cifsSesInfo *ses; 111 + struct cifs_ses *ses; 112 112 struct TCP_Server_Info *server; 113 113 struct nls_table *nls_codepage; 114 114 ··· 227 227 SMB information in the SMB header. If the return code is zero, this 228 228 function must have filled in request_buf pointer */ 229 229 static int 230 - small_smb_init(int smb_command, int wct, struct cifsTconInfo *tcon, 230 + small_smb_init(int smb_command, int wct, struct cifs_tcon *tcon, 231 231 void **request_buf) 232 232 { 233 233 int rc; ··· 253 253 254 254 int 255 255 small_smb_init_no_tc(const int smb_command, const int wct, 256 - struct cifsSesInfo *ses, void **request_buf) 256 + struct cifs_ses *ses, void **request_buf) 257 257 { 258 258 int rc; 259 259 struct smb_hdr *buffer; ··· 279 279 280 280 /* If the return code is zero, this function must fill in request_buf pointer */ 281 281 static int 282 - __smb_init(int smb_command, int wct, struct cifsTconInfo *tcon, 282 + __smb_init(int smb_command, int wct, struct cifs_tcon *tcon, 283 283 void **request_buf, void **response_buf) 284 284 { 285 285 *request_buf = cifs_buf_get(); ··· 305 305 306 306 /* If the return code is zero, this function must fill in request_buf pointer */ 307 307 static int 308 - smb_init(int smb_command, int wct, struct cifsTconInfo *tcon, 308 + smb_init(int smb_command, int wct, struct cifs_tcon *tcon, 309 309 void **request_buf, void **response_buf) 310 310 { 311 311 int rc; ··· 318 318 } 319 319 320 320 static int 321 - smb_init_no_reconnect(int smb_command, int wct, struct cifsTconInfo *tcon, 321 + smb_init_no_reconnect(int smb_command, int wct, struct cifs_tcon *tcon, 322 322 void **request_buf, void **response_buf) 323 323 { 324 324 if (tcon->ses->need_reconnect || tcon->need_reconnect) ··· 367 367 } 368 368 369 369 int 370 - CIFSSMBNegotiate(unsigned int xid, struct cifsSesInfo *ses) 370 + CIFSSMBNegotiate(unsigned int xid, struct cifs_ses *ses) 371 371 { 372 372 NEGOTIATE_REQ *pSMB; 373 373 NEGOTIATE_RSP *pSMBr; ··· 451 451 rc = -EOPNOTSUPP; 452 452 goto neg_err_exit; 453 453 } 454 - server->secMode = (__u8)le16_to_cpu(rsp->SecurityMode); 454 + server->sec_mode = (__u8)le16_to_cpu(rsp->SecurityMode); 455 455 server->maxReq = le16_to_cpu(rsp->MaxMpxCount); 456 456 server->maxBuf = min((__u32)le16_to_cpu(rsp->MaxBufSize), 457 457 (__u32)CIFSMaxBufSize + MAX_CIFS_HDR_SIZE); ··· 505 505 cpu_to_le16(CIFS_CRYPTO_KEY_SIZE)) { 506 506 memcpy(ses->server->cryptkey, rsp->EncryptionKey, 507 507 CIFS_CRYPTO_KEY_SIZE); 508 - } else if (server->secMode & SECMODE_PW_ENCRYPT) { 508 + } else if (server->sec_mode & SECMODE_PW_ENCRYPT) { 509 509 rc = -EIO; /* need cryptkey unless plain text */ 510 510 goto neg_err_exit; 511 511 } ··· 527 527 goto neg_err_exit; 528 528 } 529 529 /* else wct == 17 NTLM */ 530 - server->secMode = pSMBr->SecurityMode; 531 - if ((server->secMode & SECMODE_USER) == 0) 530 + server->sec_mode = pSMBr->SecurityMode; 531 + if ((server->sec_mode & SECMODE_USER) == 0) 532 532 cFYI(1, "share mode security"); 533 533 534 - if ((server->secMode & SECMODE_PW_ENCRYPT) == 0) 534 + if ((server->sec_mode & SECMODE_PW_ENCRYPT) == 0) 535 535 #ifdef CONFIG_CIFS_WEAK_PW_HASH 536 536 if ((secFlags & CIFSSEC_MAY_PLNTXT) == 0) 537 537 #endif /* CIFS_WEAK_PW_HASH */ ··· 617 617 } else 618 618 rc = -EOPNOTSUPP; 619 619 } 620 - } else if (server->secMode & SECMODE_PW_ENCRYPT) { 620 + } else if (server->sec_mode & SECMODE_PW_ENCRYPT) { 621 621 rc = -EIO; /* no crypt key only if plain text pwd */ 622 622 goto neg_err_exit; 623 623 } else ··· 630 630 /* MUST_SIGN already includes the MAY_SIGN FLAG 631 631 so if this is zero it means that signing is disabled */ 632 632 cFYI(1, "Signing disabled"); 633 - if (server->secMode & SECMODE_SIGN_REQUIRED) { 633 + if (server->sec_mode & SECMODE_SIGN_REQUIRED) { 634 634 cERROR(1, "Server requires " 635 635 "packet signing to be enabled in " 636 636 "/proc/fs/cifs/SecurityFlags."); 637 637 rc = -EOPNOTSUPP; 638 638 } 639 - server->secMode &= 639 + server->sec_mode &= 640 640 ~(SECMODE_SIGN_ENABLED | SECMODE_SIGN_REQUIRED); 641 641 } else if ((secFlags & CIFSSEC_MUST_SIGN) == CIFSSEC_MUST_SIGN) { 642 642 /* signing required */ 643 643 cFYI(1, "Must sign - secFlags 0x%x", secFlags); 644 - if ((server->secMode & 644 + if ((server->sec_mode & 645 645 (SECMODE_SIGN_ENABLED | SECMODE_SIGN_REQUIRED)) == 0) { 646 646 cERROR(1, "signing required but server lacks support"); 647 647 rc = -EOPNOTSUPP; 648 648 } else 649 - server->secMode |= SECMODE_SIGN_REQUIRED; 649 + server->sec_mode |= SECMODE_SIGN_REQUIRED; 650 650 } else { 651 651 /* signing optional ie CIFSSEC_MAY_SIGN */ 652 - if ((server->secMode & SECMODE_SIGN_REQUIRED) == 0) 653 - server->secMode &= 652 + if ((server->sec_mode & SECMODE_SIGN_REQUIRED) == 0) 653 + server->sec_mode &= 654 654 ~(SECMODE_SIGN_ENABLED | SECMODE_SIGN_REQUIRED); 655 655 } 656 656 ··· 662 662 } 663 663 664 664 int 665 - CIFSSMBTDis(const int xid, struct cifsTconInfo *tcon) 665 + CIFSSMBTDis(const int xid, struct cifs_tcon *tcon) 666 666 { 667 667 struct smb_hdr *smb_buffer; 668 668 int rc = 0; ··· 749 749 } 750 750 751 751 int 752 - CIFSSMBLogoff(const int xid, struct cifsSesInfo *ses) 752 + CIFSSMBLogoff(const int xid, struct cifs_ses *ses) 753 753 { 754 754 LOGOFF_ANDX_REQ *pSMB; 755 755 int rc = 0; ··· 776 776 777 777 pSMB->hdr.Mid = GetNextMid(ses->server); 778 778 779 - if (ses->server->secMode & 779 + if (ses->server->sec_mode & 780 780 (SECMODE_SIGN_REQUIRED | SECMODE_SIGN_ENABLED)) 781 781 pSMB->hdr.Flags2 |= SMBFLG2_SECURITY_SIGNATURE; 782 782 ··· 796 796 } 797 797 798 798 int 799 - CIFSPOSIXDelFile(const int xid, struct cifsTconInfo *tcon, const char *fileName, 799 + CIFSPOSIXDelFile(const int xid, struct cifs_tcon *tcon, const char *fileName, 800 800 __u16 type, const struct nls_table *nls_codepage, int remap) 801 801 { 802 802 TRANSACTION2_SPI_REQ *pSMB = NULL; ··· 871 871 } 872 872 873 873 int 874 - CIFSSMBDelFile(const int xid, struct cifsTconInfo *tcon, const char *fileName, 874 + CIFSSMBDelFile(const int xid, struct cifs_tcon *tcon, const char *fileName, 875 875 const struct nls_table *nls_codepage, int remap) 876 876 { 877 877 DELETE_FILE_REQ *pSMB = NULL; ··· 916 916 } 917 917 918 918 int 919 - CIFSSMBRmDir(const int xid, struct cifsTconInfo *tcon, const char *dirName, 919 + CIFSSMBRmDir(const int xid, struct cifs_tcon *tcon, const char *dirName, 920 920 const struct nls_table *nls_codepage, int remap) 921 921 { 922 922 DELETE_DIRECTORY_REQ *pSMB = NULL; ··· 959 959 } 960 960 961 961 int 962 - CIFSSMBMkDir(const int xid, struct cifsTconInfo *tcon, 962 + CIFSSMBMkDir(const int xid, struct cifs_tcon *tcon, 963 963 const char *name, const struct nls_table *nls_codepage, int remap) 964 964 { 965 965 int rc = 0; ··· 1002 1002 } 1003 1003 1004 1004 int 1005 - CIFSPOSIXCreate(const int xid, struct cifsTconInfo *tcon, __u32 posix_flags, 1005 + CIFSPOSIXCreate(const int xid, struct cifs_tcon *tcon, __u32 posix_flags, 1006 1006 __u64 mode, __u16 *netfid, FILE_UNIX_BASIC_INFO *pRetData, 1007 1007 __u32 *pOplock, const char *name, 1008 1008 const struct nls_table *nls_codepage, int remap) ··· 1168 1168 } 1169 1169 1170 1170 int 1171 - SMBLegacyOpen(const int xid, struct cifsTconInfo *tcon, 1171 + SMBLegacyOpen(const int xid, struct cifs_tcon *tcon, 1172 1172 const char *fileName, const int openDisposition, 1173 1173 const int access_flags, const int create_options, __u16 *netfid, 1174 1174 int *pOplock, FILE_ALL_INFO *pfile_info, ··· 1275 1275 } 1276 1276 1277 1277 int 1278 - CIFSSMBOpen(const int xid, struct cifsTconInfo *tcon, 1278 + CIFSSMBOpen(const int xid, struct cifs_tcon *tcon, 1279 1279 const char *fileName, const int openDisposition, 1280 1280 const int access_flags, const int create_options, __u16 *netfid, 1281 1281 int *pOplock, FILE_ALL_INFO *pfile_info, ··· 1390 1390 __u32 pid = io_parms->pid; 1391 1391 __u16 netfid = io_parms->netfid; 1392 1392 __u64 offset = io_parms->offset; 1393 - struct cifsTconInfo *tcon = io_parms->tcon; 1393 + struct cifs_tcon *tcon = io_parms->tcon; 1394 1394 unsigned int count = io_parms->length; 1395 1395 1396 1396 cFYI(1, "Reading %d bytes on fid %d", count, netfid); ··· 1502 1502 __u32 pid = io_parms->pid; 1503 1503 __u16 netfid = io_parms->netfid; 1504 1504 __u64 offset = io_parms->offset; 1505 - struct cifsTconInfo *tcon = io_parms->tcon; 1505 + struct cifs_tcon *tcon = io_parms->tcon; 1506 1506 unsigned int count = io_parms->length; 1507 1507 1508 1508 *nbytes = 0; ··· 1714 1714 cifs_writev_callback(struct mid_q_entry *mid) 1715 1715 { 1716 1716 struct cifs_writedata *wdata = mid->callback_data; 1717 - struct cifsTconInfo *tcon = tlink_tcon(wdata->cfile->tlink); 1717 + struct cifs_tcon *tcon = tlink_tcon(wdata->cfile->tlink); 1718 1718 unsigned int written; 1719 1719 WRITE_RSP *smb = (WRITE_RSP *)mid->resp_buf; 1720 1720 ··· 1763 1763 int i, rc = -EACCES; 1764 1764 WRITE_REQ *smb = NULL; 1765 1765 int wct; 1766 - struct cifsTconInfo *tcon = tlink_tcon(wdata->cfile->tlink); 1766 + struct cifs_tcon *tcon = tlink_tcon(wdata->cfile->tlink); 1767 1767 struct inode *inode = wdata->cfile->dentry->d_inode; 1768 1768 struct kvec *iov = NULL; 1769 1769 ··· 1866 1866 __u32 pid = io_parms->pid; 1867 1867 __u16 netfid = io_parms->netfid; 1868 1868 __u64 offset = io_parms->offset; 1869 - struct cifsTconInfo *tcon = io_parms->tcon; 1869 + struct cifs_tcon *tcon = io_parms->tcon; 1870 1870 unsigned int count = io_parms->length; 1871 1871 1872 1872 *nbytes = 0; ··· 1964 1964 1965 1965 1966 1966 int 1967 - CIFSSMBLock(const int xid, struct cifsTconInfo *tcon, 1967 + CIFSSMBLock(const int xid, struct cifs_tcon *tcon, 1968 1968 const __u16 smb_file_id, const __u64 len, 1969 1969 const __u64 offset, const __u32 numUnlock, 1970 1970 const __u32 numLock, const __u8 lockType, ··· 2034 2034 } 2035 2035 2036 2036 int 2037 - CIFSSMBPosixLock(const int xid, struct cifsTconInfo *tcon, 2037 + CIFSSMBPosixLock(const int xid, struct cifs_tcon *tcon, 2038 2038 const __u16 smb_file_id, const int get_flag, const __u64 len, 2039 2039 struct file_lock *pLockData, const __u16 lock_type, 2040 2040 const bool waitFlag) ··· 2172 2172 2173 2173 2174 2174 int 2175 - CIFSSMBClose(const int xid, struct cifsTconInfo *tcon, int smb_file_id) 2175 + CIFSSMBClose(const int xid, struct cifs_tcon *tcon, int smb_file_id) 2176 2176 { 2177 2177 int rc = 0; 2178 2178 CLOSE_REQ *pSMB = NULL; ··· 2205 2205 } 2206 2206 2207 2207 int 2208 - CIFSSMBFlush(const int xid, struct cifsTconInfo *tcon, int smb_file_id) 2208 + CIFSSMBFlush(const int xid, struct cifs_tcon *tcon, int smb_file_id) 2209 2209 { 2210 2210 int rc = 0; 2211 2211 FLUSH_REQ *pSMB = NULL; ··· 2226 2226 } 2227 2227 2228 2228 int 2229 - CIFSSMBRename(const int xid, struct cifsTconInfo *tcon, 2229 + CIFSSMBRename(const int xid, struct cifs_tcon *tcon, 2230 2230 const char *fromName, const char *toName, 2231 2231 const struct nls_table *nls_codepage, int remap) 2232 2232 { ··· 2293 2293 return rc; 2294 2294 } 2295 2295 2296 - int CIFSSMBRenameOpenFile(const int xid, struct cifsTconInfo *pTcon, 2296 + int CIFSSMBRenameOpenFile(const int xid, struct cifs_tcon *pTcon, 2297 2297 int netfid, const char *target_name, 2298 2298 const struct nls_table *nls_codepage, int remap) 2299 2299 { ··· 2373 2373 } 2374 2374 2375 2375 int 2376 - CIFSSMBCopy(const int xid, struct cifsTconInfo *tcon, const char *fromName, 2376 + CIFSSMBCopy(const int xid, struct cifs_tcon *tcon, const char *fromName, 2377 2377 const __u16 target_tid, const char *toName, const int flags, 2378 2378 const struct nls_table *nls_codepage, int remap) 2379 2379 { ··· 2441 2441 } 2442 2442 2443 2443 int 2444 - CIFSUnixCreateSymLink(const int xid, struct cifsTconInfo *tcon, 2444 + CIFSUnixCreateSymLink(const int xid, struct cifs_tcon *tcon, 2445 2445 const char *fromName, const char *toName, 2446 2446 const struct nls_table *nls_codepage) 2447 2447 { ··· 2530 2530 } 2531 2531 2532 2532 int 2533 - CIFSUnixCreateHardLink(const int xid, struct cifsTconInfo *tcon, 2533 + CIFSUnixCreateHardLink(const int xid, struct cifs_tcon *tcon, 2534 2534 const char *fromName, const char *toName, 2535 2535 const struct nls_table *nls_codepage, int remap) 2536 2536 { ··· 2615 2615 } 2616 2616 2617 2617 int 2618 - CIFSCreateHardLink(const int xid, struct cifsTconInfo *tcon, 2618 + CIFSCreateHardLink(const int xid, struct cifs_tcon *tcon, 2619 2619 const char *fromName, const char *toName, 2620 2620 const struct nls_table *nls_codepage, int remap) 2621 2621 { ··· 2687 2687 } 2688 2688 2689 2689 int 2690 - CIFSSMBUnixQuerySymLink(const int xid, struct cifsTconInfo *tcon, 2690 + CIFSSMBUnixQuerySymLink(const int xid, struct cifs_tcon *tcon, 2691 2691 const unsigned char *searchName, char **symlinkinfo, 2692 2692 const struct nls_table *nls_codepage) 2693 2693 { ··· 2792 2792 * it is not compiled in by default until callers fixed up and more tested. 2793 2793 */ 2794 2794 int 2795 - CIFSSMBQueryReparseLinkInfo(const int xid, struct cifsTconInfo *tcon, 2795 + CIFSSMBQueryReparseLinkInfo(const int xid, struct cifs_tcon *tcon, 2796 2796 const unsigned char *searchName, 2797 2797 char *symlinkinfo, const int buflen, __u16 fid, 2798 2798 const struct nls_table *nls_codepage) ··· 3030 3030 } 3031 3031 3032 3032 int 3033 - CIFSSMBGetPosixACL(const int xid, struct cifsTconInfo *tcon, 3033 + CIFSSMBGetPosixACL(const int xid, struct cifs_tcon *tcon, 3034 3034 const unsigned char *searchName, 3035 3035 char *acl_inf, const int buflen, const int acl_type, 3036 3036 const struct nls_table *nls_codepage, int remap) ··· 3118 3118 } 3119 3119 3120 3120 int 3121 - CIFSSMBSetPosixACL(const int xid, struct cifsTconInfo *tcon, 3121 + CIFSSMBSetPosixACL(const int xid, struct cifs_tcon *tcon, 3122 3122 const unsigned char *fileName, 3123 3123 const char *local_acl, const int buflen, 3124 3124 const int acl_type, ··· 3198 3198 3199 3199 /* BB fix tabs in this function FIXME BB */ 3200 3200 int 3201 - CIFSGetExtAttr(const int xid, struct cifsTconInfo *tcon, 3201 + CIFSGetExtAttr(const int xid, struct cifs_tcon *tcon, 3202 3202 const int netfid, __u64 *pExtAttrBits, __u64 *pMask) 3203 3203 { 3204 3204 int rc = 0; ··· 3291 3291 */ 3292 3292 static int 3293 3293 smb_init_nttransact(const __u16 sub_command, const int setup_count, 3294 - const int parm_len, struct cifsTconInfo *tcon, 3294 + const int parm_len, struct cifs_tcon *tcon, 3295 3295 void **ret_buf) 3296 3296 { 3297 3297 int rc; ··· 3374 3374 3375 3375 /* Get Security Descriptor (by handle) from remote server for a file or dir */ 3376 3376 int 3377 - CIFSSMBGetCIFSACL(const int xid, struct cifsTconInfo *tcon, __u16 fid, 3377 + CIFSSMBGetCIFSACL(const int xid, struct cifs_tcon *tcon, __u16 fid, 3378 3378 struct cifs_ntsd **acl_inf, __u32 *pbuflen) 3379 3379 { 3380 3380 int rc = 0; ··· 3466 3466 } 3467 3467 3468 3468 int 3469 - CIFSSMBSetCIFSACL(const int xid, struct cifsTconInfo *tcon, __u16 fid, 3469 + CIFSSMBSetCIFSACL(const int xid, struct cifs_tcon *tcon, __u16 fid, 3470 3470 struct cifs_ntsd *pntsd, __u32 acllen) 3471 3471 { 3472 3472 __u16 byte_count, param_count, data_count, param_offset, data_offset; ··· 3532 3532 3533 3533 /* Legacy Query Path Information call for lookup to old servers such 3534 3534 as Win9x/WinME */ 3535 - int SMBQueryInformation(const int xid, struct cifsTconInfo *tcon, 3535 + int SMBQueryInformation(const int xid, struct cifs_tcon *tcon, 3536 3536 const unsigned char *searchName, 3537 3537 FILE_ALL_INFO *pFinfo, 3538 3538 const struct nls_table *nls_codepage, int remap) ··· 3600 3600 } 3601 3601 3602 3602 int 3603 - CIFSSMBQFileInfo(const int xid, struct cifsTconInfo *tcon, 3603 + CIFSSMBQFileInfo(const int xid, struct cifs_tcon *tcon, 3604 3604 u16 netfid, FILE_ALL_INFO *pFindData) 3605 3605 { 3606 3606 struct smb_t2_qfi_req *pSMB = NULL; ··· 3667 3667 } 3668 3668 3669 3669 int 3670 - CIFSSMBQPathInfo(const int xid, struct cifsTconInfo *tcon, 3670 + CIFSSMBQPathInfo(const int xid, struct cifs_tcon *tcon, 3671 3671 const unsigned char *searchName, 3672 3672 FILE_ALL_INFO *pFindData, 3673 3673 int legacy /* old style infolevel */, ··· 3768 3768 } 3769 3769 3770 3770 int 3771 - CIFSSMBUnixQFileInfo(const int xid, struct cifsTconInfo *tcon, 3771 + CIFSSMBUnixQFileInfo(const int xid, struct cifs_tcon *tcon, 3772 3772 u16 netfid, FILE_UNIX_BASIC_INFO *pFindData) 3773 3773 { 3774 3774 struct smb_t2_qfi_req *pSMB = NULL; ··· 3837 3837 } 3838 3838 3839 3839 int 3840 - CIFSSMBUnixQPathInfo(const int xid, struct cifsTconInfo *tcon, 3840 + CIFSSMBUnixQPathInfo(const int xid, struct cifs_tcon *tcon, 3841 3841 const unsigned char *searchName, 3842 3842 FILE_UNIX_BASIC_INFO *pFindData, 3843 3843 const struct nls_table *nls_codepage, int remap) ··· 3923 3923 3924 3924 /* xid, tcon, searchName and codepage are input parms, rest are returned */ 3925 3925 int 3926 - CIFSFindFirst(const int xid, struct cifsTconInfo *tcon, 3926 + CIFSFindFirst(const int xid, struct cifs_tcon *tcon, 3927 3927 const char *searchName, 3928 3928 const struct nls_table *nls_codepage, 3929 3929 __u16 *pnetfid, ··· 4071 4071 return rc; 4072 4072 } 4073 4073 4074 - int CIFSFindNext(const int xid, struct cifsTconInfo *tcon, 4074 + int CIFSFindNext(const int xid, struct cifs_tcon *tcon, 4075 4075 __u16 searchHandle, struct cifs_search_info *psrch_inf) 4076 4076 { 4077 4077 TRANSACTION2_FNEXT_REQ *pSMB = NULL; ··· 4209 4209 } 4210 4210 4211 4211 int 4212 - CIFSFindClose(const int xid, struct cifsTconInfo *tcon, 4212 + CIFSFindClose(const int xid, struct cifs_tcon *tcon, 4213 4213 const __u16 searchHandle) 4214 4214 { 4215 4215 int rc = 0; ··· 4241 4241 } 4242 4242 4243 4243 int 4244 - CIFSGetSrvInodeNumber(const int xid, struct cifsTconInfo *tcon, 4244 + CIFSGetSrvInodeNumber(const int xid, struct cifs_tcon *tcon, 4245 4245 const unsigned char *searchName, 4246 4246 __u64 *inode_number, 4247 4247 const struct nls_table *nls_codepage, int remap) ··· 4443 4443 } 4444 4444 4445 4445 int 4446 - CIFSGetDFSRefer(const int xid, struct cifsSesInfo *ses, 4446 + CIFSGetDFSRefer(const int xid, struct cifs_ses *ses, 4447 4447 const unsigned char *searchName, 4448 4448 struct dfs_info3_param **target_nodes, 4449 4449 unsigned int *num_of_nodes, ··· 4492 4492 } 4493 4493 4494 4494 if (ses->server) { 4495 - if (ses->server->secMode & 4495 + if (ses->server->sec_mode & 4496 4496 (SECMODE_SIGN_REQUIRED | SECMODE_SIGN_ENABLED)) 4497 4497 pSMB->hdr.Flags2 |= SMBFLG2_SECURITY_SIGNATURE; 4498 4498 } ··· 4557 4557 4558 4558 /* Query File System Info such as free space to old servers such as Win 9x */ 4559 4559 int 4560 - SMBOldQFSInfo(const int xid, struct cifsTconInfo *tcon, struct kstatfs *FSData) 4560 + SMBOldQFSInfo(const int xid, struct cifs_tcon *tcon, struct kstatfs *FSData) 4561 4561 { 4562 4562 /* level 0x01 SMB_QUERY_FILE_SYSTEM_INFO */ 4563 4563 TRANSACTION2_QFSI_REQ *pSMB = NULL; ··· 4636 4636 } 4637 4637 4638 4638 int 4639 - CIFSSMBQFSInfo(const int xid, struct cifsTconInfo *tcon, struct kstatfs *FSData) 4639 + CIFSSMBQFSInfo(const int xid, struct cifs_tcon *tcon, struct kstatfs *FSData) 4640 4640 { 4641 4641 /* level 0x103 SMB_QUERY_FILE_SYSTEM_INFO */ 4642 4642 TRANSACTION2_QFSI_REQ *pSMB = NULL; ··· 4715 4715 } 4716 4716 4717 4717 int 4718 - CIFSSMBQFSAttributeInfo(const int xid, struct cifsTconInfo *tcon) 4718 + CIFSSMBQFSAttributeInfo(const int xid, struct cifs_tcon *tcon) 4719 4719 { 4720 4720 /* level 0x105 SMB_QUERY_FILE_SYSTEM_INFO */ 4721 4721 TRANSACTION2_QFSI_REQ *pSMB = NULL; ··· 4785 4785 } 4786 4786 4787 4787 int 4788 - CIFSSMBQFSDeviceInfo(const int xid, struct cifsTconInfo *tcon) 4788 + CIFSSMBQFSDeviceInfo(const int xid, struct cifs_tcon *tcon) 4789 4789 { 4790 4790 /* level 0x104 SMB_QUERY_FILE_SYSTEM_INFO */ 4791 4791 TRANSACTION2_QFSI_REQ *pSMB = NULL; ··· 4856 4856 } 4857 4857 4858 4858 int 4859 - CIFSSMBQFSUnixInfo(const int xid, struct cifsTconInfo *tcon) 4859 + CIFSSMBQFSUnixInfo(const int xid, struct cifs_tcon *tcon) 4860 4860 { 4861 4861 /* level 0x200 SMB_QUERY_CIFS_UNIX_INFO */ 4862 4862 TRANSACTION2_QFSI_REQ *pSMB = NULL; ··· 4926 4926 } 4927 4927 4928 4928 int 4929 - CIFSSMBSetFSUnixInfo(const int xid, struct cifsTconInfo *tcon, __u64 cap) 4929 + CIFSSMBSetFSUnixInfo(const int xid, struct cifs_tcon *tcon, __u64 cap) 4930 4930 { 4931 4931 /* level 0x200 SMB_SET_CIFS_UNIX_INFO */ 4932 4932 TRANSACTION2_SETFSI_REQ *pSMB = NULL; ··· 5000 5000 5001 5001 5002 5002 int 5003 - CIFSSMBQFSPosixInfo(const int xid, struct cifsTconInfo *tcon, 5003 + CIFSSMBQFSPosixInfo(const int xid, struct cifs_tcon *tcon, 5004 5004 struct kstatfs *FSData) 5005 5005 { 5006 5006 /* level 0x201 SMB_QUERY_CIFS_POSIX_INFO */ ··· 5093 5093 in Samba which this routine can run into */ 5094 5094 5095 5095 int 5096 - CIFSSMBSetEOF(const int xid, struct cifsTconInfo *tcon, const char *fileName, 5096 + CIFSSMBSetEOF(const int xid, struct cifs_tcon *tcon, const char *fileName, 5097 5097 __u64 size, bool SetAllocation, 5098 5098 const struct nls_table *nls_codepage, int remap) 5099 5099 { ··· 5182 5182 } 5183 5183 5184 5184 int 5185 - CIFSSMBSetFileSize(const int xid, struct cifsTconInfo *tcon, __u64 size, 5185 + CIFSSMBSetFileSize(const int xid, struct cifs_tcon *tcon, __u64 size, 5186 5186 __u16 fid, __u32 pid_of_opener, bool SetAllocation) 5187 5187 { 5188 5188 struct smb_com_transaction2_sfi_req *pSMB = NULL; ··· 5264 5264 time and resort to the original setpathinfo level which takes the ancient 5265 5265 DOS time format with 2 second granularity */ 5266 5266 int 5267 - CIFSSMBSetFileInfo(const int xid, struct cifsTconInfo *tcon, 5267 + CIFSSMBSetFileInfo(const int xid, struct cifs_tcon *tcon, 5268 5268 const FILE_BASIC_INFO *data, __u16 fid, __u32 pid_of_opener) 5269 5269 { 5270 5270 struct smb_com_transaction2_sfi_req *pSMB = NULL; ··· 5326 5326 } 5327 5327 5328 5328 int 5329 - CIFSSMBSetFileDisposition(const int xid, struct cifsTconInfo *tcon, 5329 + CIFSSMBSetFileDisposition(const int xid, struct cifs_tcon *tcon, 5330 5330 bool delete_file, __u16 fid, __u32 pid_of_opener) 5331 5331 { 5332 5332 struct smb_com_transaction2_sfi_req *pSMB = NULL; ··· 5382 5382 } 5383 5383 5384 5384 int 5385 - CIFSSMBSetPathInfo(const int xid, struct cifsTconInfo *tcon, 5385 + CIFSSMBSetPathInfo(const int xid, struct cifs_tcon *tcon, 5386 5386 const char *fileName, const FILE_BASIC_INFO *data, 5387 5387 const struct nls_table *nls_codepage, int remap) 5388 5388 { ··· 5466 5466 handling it anyway and NT4 was what we thought it would be needed for 5467 5467 Do not delete it until we prove whether needed for Win9x though */ 5468 5468 int 5469 - CIFSSMBSetAttrLegacy(int xid, struct cifsTconInfo *tcon, char *fileName, 5469 + CIFSSMBSetAttrLegacy(int xid, struct cifs_tcon *tcon, char *fileName, 5470 5470 __u16 dos_attrs, const struct nls_table *nls_codepage) 5471 5471 { 5472 5472 SETATTR_REQ *pSMB = NULL; ··· 5554 5554 } 5555 5555 5556 5556 int 5557 - CIFSSMBUnixSetFileInfo(const int xid, struct cifsTconInfo *tcon, 5557 + CIFSSMBUnixSetFileInfo(const int xid, struct cifs_tcon *tcon, 5558 5558 const struct cifs_unix_set_info_args *args, 5559 5559 u16 fid, u32 pid_of_opener) 5560 5560 { ··· 5617 5617 } 5618 5618 5619 5619 int 5620 - CIFSSMBUnixSetPathInfo(const int xid, struct cifsTconInfo *tcon, char *fileName, 5620 + CIFSSMBUnixSetPathInfo(const int xid, struct cifs_tcon *tcon, char *fileName, 5621 5621 const struct cifs_unix_set_info_args *args, 5622 5622 const struct nls_table *nls_codepage, int remap) 5623 5623 { ··· 5704 5704 * the data isn't copied to it, but the length is returned. 5705 5705 */ 5706 5706 ssize_t 5707 - CIFSSMBQAllEAs(const int xid, struct cifsTconInfo *tcon, 5707 + CIFSSMBQAllEAs(const int xid, struct cifs_tcon *tcon, 5708 5708 const unsigned char *searchName, const unsigned char *ea_name, 5709 5709 char *EAData, size_t buf_size, 5710 5710 const struct nls_table *nls_codepage, int remap) ··· 5885 5885 } 5886 5886 5887 5887 int 5888 - CIFSSMBSetEA(const int xid, struct cifsTconInfo *tcon, const char *fileName, 5888 + CIFSSMBSetEA(const int xid, struct cifs_tcon *tcon, const char *fileName, 5889 5889 const char *ea_name, const void *ea_value, 5890 5890 const __u16 ea_value_len, const struct nls_table *nls_codepage, 5891 5891 int remap) ··· 6012 6012 * incompatible for network fs clients, we could instead simply 6013 6013 * expose this config flag by adding a future cifs (and smb2) notify ioctl. 6014 6014 */ 6015 - int CIFSSMBNotify(const int xid, struct cifsTconInfo *tcon, 6015 + int CIFSSMBNotify(const int xid, struct cifs_tcon *tcon, 6016 6016 const int notify_subdirs, const __u16 netfid, 6017 6017 __u32 filter, struct file *pfile, int multishot, 6018 6018 const struct nls_table *nls_codepage)
+45 -45
fs/cifs/connect.c
··· 79 79 { 80 80 int rc = 0; 81 81 struct list_head *tmp, *tmp2; 82 - struct cifsSesInfo *ses; 83 - struct cifsTconInfo *tcon; 82 + struct cifs_ses *ses; 83 + struct cifs_tcon *tcon; 84 84 struct mid_q_entry *mid_entry; 85 85 struct list_head retry_list; 86 86 ··· 102 102 cFYI(1, "%s: marking sessions and tcons for reconnect", __func__); 103 103 spin_lock(&cifs_tcp_ses_lock); 104 104 list_for_each(tmp, &server->smb_ses_list) { 105 - ses = list_entry(tmp, struct cifsSesInfo, smb_ses_list); 105 + ses = list_entry(tmp, struct cifs_ses, smb_ses_list); 106 106 ses->need_reconnect = true; 107 107 ses->ipc_tid = 0; 108 108 list_for_each(tmp2, &ses->tcon_list) { 109 - tcon = list_entry(tmp2, struct cifsTconInfo, tcon_list); 109 + tcon = list_entry(tmp2, struct cifs_tcon, tcon_list); 110 110 tcon->need_reconnect = true; 111 111 } 112 112 } ··· 1597 1597 1598 1598 /* now check if signing mode is acceptable */ 1599 1599 if ((secFlags & CIFSSEC_MAY_SIGN) == 0 && 1600 - (server->secMode & SECMODE_SIGN_REQUIRED)) 1600 + (server->sec_mode & SECMODE_SIGN_REQUIRED)) 1601 1601 return false; 1602 1602 else if (((secFlags & CIFSSEC_MUST_SIGN) == CIFSSEC_MUST_SIGN) && 1603 - (server->secMode & 1603 + (server->sec_mode & 1604 1604 (SECMODE_SIGN_ENABLED|SECMODE_SIGN_REQUIRED)) == 0) 1605 1605 return false; 1606 1606 ··· 1827 1827 return ERR_PTR(rc); 1828 1828 } 1829 1829 1830 - static int match_session(struct cifsSesInfo *ses, struct smb_vol *vol) 1830 + static int match_session(struct cifs_ses *ses, struct smb_vol *vol) 1831 1831 { 1832 1832 switch (ses->server->secType) { 1833 1833 case Kerberos: ··· 1851 1851 return 1; 1852 1852 } 1853 1853 1854 - static struct cifsSesInfo * 1854 + static struct cifs_ses * 1855 1855 cifs_find_smb_ses(struct TCP_Server_Info *server, struct smb_vol *vol) 1856 1856 { 1857 - struct cifsSesInfo *ses; 1857 + struct cifs_ses *ses; 1858 1858 1859 1859 spin_lock(&cifs_tcp_ses_lock); 1860 1860 list_for_each_entry(ses, &server->smb_ses_list, smb_ses_list) { ··· 1869 1869 } 1870 1870 1871 1871 static void 1872 - cifs_put_smb_ses(struct cifsSesInfo *ses) 1872 + cifs_put_smb_ses(struct cifs_ses *ses) 1873 1873 { 1874 1874 int xid; 1875 1875 struct TCP_Server_Info *server = ses->server; ··· 1895 1895 1896 1896 static bool warned_on_ntlm; /* globals init to false automatically */ 1897 1897 1898 - static struct cifsSesInfo * 1898 + static struct cifs_ses * 1899 1899 cifs_get_smb_ses(struct TCP_Server_Info *server, struct smb_vol *volume_info) 1900 1900 { 1901 1901 int rc = -ENOMEM, xid; 1902 - struct cifsSesInfo *ses; 1902 + struct cifs_ses *ses; 1903 1903 struct sockaddr_in *addr = (struct sockaddr_in *)&server->dstaddr; 1904 1904 struct sockaddr_in6 *addr6 = (struct sockaddr_in6 *)&server->dstaddr; 1905 1905 ··· 2002 2002 return ERR_PTR(rc); 2003 2003 } 2004 2004 2005 - static int match_tcon(struct cifsTconInfo *tcon, const char *unc) 2005 + static int match_tcon(struct cifs_tcon *tcon, const char *unc) 2006 2006 { 2007 2007 if (tcon->tidStatus == CifsExiting) 2008 2008 return 0; ··· 2011 2011 return 1; 2012 2012 } 2013 2013 2014 - static struct cifsTconInfo * 2015 - cifs_find_tcon(struct cifsSesInfo *ses, const char *unc) 2014 + static struct cifs_tcon * 2015 + cifs_find_tcon(struct cifs_ses *ses, const char *unc) 2016 2016 { 2017 2017 struct list_head *tmp; 2018 - struct cifsTconInfo *tcon; 2018 + struct cifs_tcon *tcon; 2019 2019 2020 2020 spin_lock(&cifs_tcp_ses_lock); 2021 2021 list_for_each(tmp, &ses->tcon_list) { 2022 - tcon = list_entry(tmp, struct cifsTconInfo, tcon_list); 2022 + tcon = list_entry(tmp, struct cifs_tcon, tcon_list); 2023 2023 if (!match_tcon(tcon, unc)) 2024 2024 continue; 2025 2025 ++tcon->tc_count; ··· 2031 2031 } 2032 2032 2033 2033 static void 2034 - cifs_put_tcon(struct cifsTconInfo *tcon) 2034 + cifs_put_tcon(struct cifs_tcon *tcon) 2035 2035 { 2036 2036 int xid; 2037 - struct cifsSesInfo *ses = tcon->ses; 2037 + struct cifs_ses *ses = tcon->ses; 2038 2038 2039 2039 cFYI(1, "%s: tc_count=%d\n", __func__, tcon->tc_count); 2040 2040 spin_lock(&cifs_tcp_ses_lock); ··· 2055 2055 cifs_put_smb_ses(ses); 2056 2056 } 2057 2057 2058 - static struct cifsTconInfo * 2059 - cifs_get_tcon(struct cifsSesInfo *ses, struct smb_vol *volume_info) 2058 + static struct cifs_tcon * 2059 + cifs_get_tcon(struct cifs_ses *ses, struct smb_vol *volume_info) 2060 2060 { 2061 2061 int rc, xid; 2062 - struct cifsTconInfo *tcon; 2062 + struct cifs_tcon *tcon; 2063 2063 2064 2064 tcon = cifs_find_tcon(ses, volume_info->UNC); 2065 2065 if (tcon) { ··· 2197 2197 struct smb_vol *volume_info; 2198 2198 struct cifs_sb_info *cifs_sb; 2199 2199 struct TCP_Server_Info *tcp_srv; 2200 - struct cifsSesInfo *ses; 2201 - struct cifsTconInfo *tcon; 2200 + struct cifs_ses *ses; 2201 + struct cifs_tcon *tcon; 2202 2202 struct tcon_link *tlink; 2203 2203 struct sockaddr_storage addr; 2204 2204 int rc = 0; ··· 2243 2243 } 2244 2244 2245 2245 int 2246 - get_dfs_path(int xid, struct cifsSesInfo *pSesInfo, const char *old_path, 2246 + get_dfs_path(int xid, struct cifs_ses *pSesInfo, const char *old_path, 2247 2247 const struct nls_table *nls_codepage, unsigned int *pnum_referrals, 2248 2248 struct dfs_info3_param **preferrals, int remap) 2249 2249 { ··· 2542 2542 return generic_ip_connect(server); 2543 2543 } 2544 2544 2545 - void reset_cifs_unix_caps(int xid, struct cifsTconInfo *tcon, 2545 + void reset_cifs_unix_caps(int xid, struct cifs_tcon *tcon, 2546 2546 struct super_block *sb, struct smb_vol *vol_info) 2547 2547 { 2548 2548 /* if we are reconnecting then should we check to see if ··· 2771 2771 #define CIFS_DEFAULT_WSIZE (1024 * 1024) 2772 2772 2773 2773 static unsigned int 2774 - cifs_negotiate_wsize(struct cifsTconInfo *tcon, struct smb_vol *pvolume_info) 2774 + cifs_negotiate_wsize(struct cifs_tcon *tcon, struct smb_vol *pvolume_info) 2775 2775 { 2776 2776 __u64 unix_cap = le64_to_cpu(tcon->fsUnixInfo.Capability); 2777 2777 struct TCP_Server_Info *server = tcon->ses->server; ··· 2793 2793 } 2794 2794 2795 2795 static int 2796 - is_path_accessible(int xid, struct cifsTconInfo *tcon, 2796 + is_path_accessible(int xid, struct cifs_tcon *tcon, 2797 2797 struct cifs_sb_info *cifs_sb, const char *full_path) 2798 2798 { 2799 2799 int rc; ··· 2868 2868 * determine whether there were referrals. 2869 2869 */ 2870 2870 static int 2871 - expand_dfs_referral(int xid, struct cifsSesInfo *pSesInfo, 2871 + expand_dfs_referral(int xid, struct cifs_ses *pSesInfo, 2872 2872 struct smb_vol *volume_info, struct cifs_sb_info *cifs_sb, 2873 2873 int check_prefix) 2874 2874 { ··· 2973 2973 { 2974 2974 int rc = 0; 2975 2975 int xid; 2976 - struct cifsSesInfo *pSesInfo; 2977 - struct cifsTconInfo *tcon; 2976 + struct cifs_ses *pSesInfo; 2977 + struct cifs_tcon *tcon; 2978 2978 struct TCP_Server_Info *srvTcp; 2979 2979 char *full_path; 2980 2980 struct tcon_link *tlink; ··· 3172 3172 } 3173 3173 3174 3174 int 3175 - CIFSTCon(unsigned int xid, struct cifsSesInfo *ses, 3176 - const char *tree, struct cifsTconInfo *tcon, 3175 + CIFSTCon(unsigned int xid, struct cifs_ses *ses, 3176 + const char *tree, struct cifs_tcon *tcon, 3177 3177 const struct nls_table *nls_codepage) 3178 3178 { 3179 3179 struct smb_hdr *smb_buffer; ··· 3205 3205 pSMB->AndXCommand = 0xFF; 3206 3206 pSMB->Flags = cpu_to_le16(TCON_EXTENDED_SECINFO); 3207 3207 bcc_ptr = &pSMB->Password[0]; 3208 - if ((ses->server->secMode) & SECMODE_USER) { 3208 + if ((ses->server->sec_mode) & SECMODE_USER) { 3209 3209 pSMB->PasswordLength = cpu_to_le16(1); /* minimum */ 3210 3210 *bcc_ptr = 0; /* password is null byte */ 3211 3211 bcc_ptr++; /* skip password */ ··· 3222 3222 if ((global_secflags & CIFSSEC_MAY_LANMAN) && 3223 3223 (ses->server->secType == LANMAN)) 3224 3224 calc_lanman_hash(tcon->password, ses->server->cryptkey, 3225 - ses->server->secMode & 3225 + ses->server->sec_mode & 3226 3226 SECMODE_PW_ENCRYPT ? true : false, 3227 3227 bcc_ptr); 3228 3228 else ··· 3238 3238 } 3239 3239 } 3240 3240 3241 - if (ses->server->secMode & 3241 + if (ses->server->sec_mode & 3242 3242 (SECMODE_SIGN_REQUIRED | SECMODE_SIGN_ENABLED)) 3243 3243 smb_buffer->Flags2 |= SMBFLG2_SECURITY_SIGNATURE; 3244 3244 ··· 3353 3353 return 0; 3354 3354 } 3355 3355 3356 - int cifs_negotiate_protocol(unsigned int xid, struct cifsSesInfo *ses) 3356 + int cifs_negotiate_protocol(unsigned int xid, struct cifs_ses *ses) 3357 3357 { 3358 3358 int rc = 0; 3359 3359 struct TCP_Server_Info *server = ses->server; ··· 3383 3383 } 3384 3384 3385 3385 3386 - int cifs_setup_session(unsigned int xid, struct cifsSesInfo *ses, 3386 + int cifs_setup_session(unsigned int xid, struct cifs_ses *ses, 3387 3387 struct nls_table *nls_info) 3388 3388 { 3389 3389 int rc = 0; ··· 3395 3395 ses->capabilities &= (~CAP_UNIX); 3396 3396 3397 3397 cFYI(1, "Security Mode: 0x%x Capabilities: 0x%x TimeAdjust: %d", 3398 - server->secMode, server->capabilities, server->timeAdj); 3398 + server->sec_mode, server->capabilities, server->timeAdj); 3399 3399 3400 3400 rc = CIFS_SessSetup(xid, ses, nls_info); 3401 3401 if (rc) { ··· 3427 3427 return rc; 3428 3428 } 3429 3429 3430 - static struct cifsTconInfo * 3430 + static struct cifs_tcon * 3431 3431 cifs_construct_tcon(struct cifs_sb_info *cifs_sb, uid_t fsuid) 3432 3432 { 3433 - struct cifsTconInfo *master_tcon = cifs_sb_master_tcon(cifs_sb); 3434 - struct cifsSesInfo *ses; 3435 - struct cifsTconInfo *tcon = NULL; 3433 + struct cifs_tcon *master_tcon = cifs_sb_master_tcon(cifs_sb); 3434 + struct cifs_ses *ses; 3435 + struct cifs_tcon *tcon = NULL; 3436 3436 struct smb_vol *vol_info; 3437 3437 char username[28]; /* big enough for "krb50x" + hex of ULONG_MAX 6+16 */ 3438 3438 /* We used to have this as MAX_USERNAME which is */ ··· 3465 3465 3466 3466 ses = cifs_get_smb_ses(master_tcon->ses->server, vol_info); 3467 3467 if (IS_ERR(ses)) { 3468 - tcon = (struct cifsTconInfo *)ses; 3468 + tcon = (struct cifs_tcon *)ses; 3469 3469 cifs_put_tcp_session(master_tcon->ses->server); 3470 3470 goto out; 3471 3471 } ··· 3490 3490 return cifs_sb->master_tlink; 3491 3491 } 3492 3492 3493 - struct cifsTconInfo * 3493 + struct cifs_tcon * 3494 3494 cifs_sb_master_tcon(struct cifs_sb_info *cifs_sb) 3495 3495 { 3496 3496 return tlink_tcon(cifs_sb_master_tlink(cifs_sb));
+4 -4
fs/cifs/dir.c
··· 54 54 char *full_path; 55 55 char dirsep; 56 56 struct cifs_sb_info *cifs_sb = CIFS_SB(direntry->d_sb); 57 - struct cifsTconInfo *tcon = cifs_sb_master_tcon(cifs_sb); 57 + struct cifs_tcon *tcon = cifs_sb_master_tcon(cifs_sb); 58 58 59 59 if (direntry == NULL) 60 60 return NULL; /* not much we can do if dentry is freed and ··· 149 149 __u16 fileHandle; 150 150 struct cifs_sb_info *cifs_sb; 151 151 struct tcon_link *tlink; 152 - struct cifsTconInfo *tcon; 152 + struct cifs_tcon *tcon; 153 153 char *full_path = NULL; 154 154 FILE_ALL_INFO *buf = NULL; 155 155 struct inode *newinode = NULL; ··· 353 353 int xid; 354 354 struct cifs_sb_info *cifs_sb; 355 355 struct tcon_link *tlink; 356 - struct cifsTconInfo *pTcon; 356 + struct cifs_tcon *pTcon; 357 357 struct cifs_io_parms io_parms; 358 358 char *full_path = NULL; 359 359 struct inode *newinode = NULL; ··· 485 485 bool posix_open = false; 486 486 struct cifs_sb_info *cifs_sb; 487 487 struct tcon_link *tlink; 488 - struct cifsTconInfo *pTcon; 488 + struct cifs_tcon *pTcon; 489 489 struct cifsFileInfo *cfile; 490 490 struct inode *newInode = NULL; 491 491 char *full_path = NULL;
+14 -14
fs/cifs/file.c
··· 114 114 struct cifs_sb_info *cifs_sb = CIFS_SB(sb); 115 115 struct cifs_fattr fattr; 116 116 struct tcon_link *tlink; 117 - struct cifsTconInfo *tcon; 117 + struct cifs_tcon *tcon; 118 118 119 119 cFYI(1, "posix open %s", full_path); 120 120 ··· 168 168 169 169 static int 170 170 cifs_nt_open(char *full_path, struct inode *inode, struct cifs_sb_info *cifs_sb, 171 - struct cifsTconInfo *tcon, unsigned int f_flags, __u32 *poplock, 171 + struct cifs_tcon *tcon, unsigned int f_flags, __u32 *poplock, 172 172 __u16 *pnetfid, int xid) 173 173 { 174 174 int rc; ··· 285 285 void cifsFileInfo_put(struct cifsFileInfo *cifs_file) 286 286 { 287 287 struct inode *inode = cifs_file->dentry->d_inode; 288 - struct cifsTconInfo *tcon = tlink_tcon(cifs_file->tlink); 288 + struct cifs_tcon *tcon = tlink_tcon(cifs_file->tlink); 289 289 struct cifsInodeInfo *cifsi = CIFS_I(inode); 290 290 struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); 291 291 struct cifsLockInfo *li, *tmp; ··· 343 343 int xid; 344 344 __u32 oplock; 345 345 struct cifs_sb_info *cifs_sb; 346 - struct cifsTconInfo *tcon; 346 + struct cifs_tcon *tcon; 347 347 struct tcon_link *tlink; 348 348 struct cifsFileInfo *pCifsFile = NULL; 349 349 char *full_path = NULL; ··· 457 457 int xid; 458 458 __u32 oplock; 459 459 struct cifs_sb_info *cifs_sb; 460 - struct cifsTconInfo *tcon; 460 + struct cifs_tcon *tcon; 461 461 struct cifsInodeInfo *pCifsInode; 462 462 struct inode *inode; 463 463 char *full_path = NULL; ··· 596 596 xid = GetXid(); 597 597 598 598 if (pCFileStruct) { 599 - struct cifsTconInfo *pTcon = tlink_tcon(pCFileStruct->tlink); 599 + struct cifs_tcon *pTcon = tlink_tcon(pCFileStruct->tlink); 600 600 601 601 cFYI(1, "Freeing private data in close dir"); 602 602 spin_lock(&cifs_file_list_lock); ··· 653 653 __u64 length; 654 654 bool wait_flag = false; 655 655 struct cifs_sb_info *cifs_sb; 656 - struct cifsTconInfo *tcon; 656 + struct cifs_tcon *tcon; 657 657 __u16 netfid; 658 658 __u8 lockType = LOCKING_ANDX_LARGE_FILES; 659 659 bool posix_locking = 0; ··· 865 865 unsigned int bytes_written = 0; 866 866 unsigned int total_written; 867 867 struct cifs_sb_info *cifs_sb; 868 - struct cifsTconInfo *pTcon; 868 + struct cifs_tcon *pTcon; 869 869 int xid; 870 870 struct dentry *dentry = open_file->dentry; 871 871 struct cifsInodeInfo *cifsi = CIFS_I(dentry->d_inode); ··· 1405 1405 { 1406 1406 int xid; 1407 1407 int rc = 0; 1408 - struct cifsTconInfo *tcon; 1408 + struct cifs_tcon *tcon; 1409 1409 struct cifsFileInfo *smbfile = file->private_data; 1410 1410 struct inode *inode = file->f_path.dentry->d_inode; 1411 1411 struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); ··· 1435 1435 { 1436 1436 int xid; 1437 1437 int rc = 0; 1438 - struct cifsTconInfo *tcon; 1438 + struct cifs_tcon *tcon; 1439 1439 struct cifsFileInfo *smbfile = file->private_data; 1440 1440 struct cifs_sb_info *cifs_sb = CIFS_SB(file->f_path.dentry->d_sb); 1441 1441 ··· 1526 1526 struct iov_iter it; 1527 1527 struct inode *inode; 1528 1528 struct cifsFileInfo *open_file; 1529 - struct cifsTconInfo *pTcon; 1529 + struct cifs_tcon *pTcon; 1530 1530 struct cifs_sb_info *cifs_sb; 1531 1531 struct cifs_io_parms io_parms; 1532 1532 int xid, rc; ··· 1693 1693 size_t len, cur_len; 1694 1694 int iov_offset = 0; 1695 1695 struct cifs_sb_info *cifs_sb; 1696 - struct cifsTconInfo *pTcon; 1696 + struct cifs_tcon *pTcon; 1697 1697 struct cifsFileInfo *open_file; 1698 1698 struct smb_com_read_rsp *pSMBr; 1699 1699 struct cifs_io_parms io_parms; ··· 1815 1815 unsigned int total_read; 1816 1816 unsigned int current_read_size; 1817 1817 struct cifs_sb_info *cifs_sb; 1818 - struct cifsTconInfo *pTcon; 1818 + struct cifs_tcon *pTcon; 1819 1819 int xid; 1820 1820 char *current_offset; 1821 1821 struct cifsFileInfo *open_file; ··· 1998 1998 loff_t offset; 1999 1999 struct page *page; 2000 2000 struct cifs_sb_info *cifs_sb; 2001 - struct cifsTconInfo *pTcon; 2001 + struct cifs_tcon *pTcon; 2002 2002 unsigned int bytes_read = 0; 2003 2003 unsigned int read_size, i; 2004 2004 char *smb_read_data = NULL;
+3 -3
fs/cifs/fscache.c
··· 40 40 server->fscache = NULL; 41 41 } 42 42 43 - void cifs_fscache_get_super_cookie(struct cifsTconInfo *tcon) 43 + void cifs_fscache_get_super_cookie(struct cifs_tcon *tcon) 44 44 { 45 45 struct TCP_Server_Info *server = tcon->ses->server; 46 46 ··· 51 51 server->fscache, tcon->fscache); 52 52 } 53 53 54 - void cifs_fscache_release_super_cookie(struct cifsTconInfo *tcon) 54 + void cifs_fscache_release_super_cookie(struct cifs_tcon *tcon) 55 55 { 56 56 cFYI(1, "CIFS: releasing superblock cookie (0x%p)", tcon->fscache); 57 57 fscache_relinquish_cookie(tcon->fscache, 0); ··· 62 62 { 63 63 struct cifsInodeInfo *cifsi = CIFS_I(inode); 64 64 struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); 65 - struct cifsTconInfo *tcon = cifs_sb_master_tcon(cifs_sb); 65 + struct cifs_tcon *tcon = cifs_sb_master_tcon(cifs_sb); 66 66 67 67 if (cifsi->fscache) 68 68 return;
+4 -4
fs/cifs/fscache.h
··· 40 40 */ 41 41 extern void cifs_fscache_get_client_cookie(struct TCP_Server_Info *); 42 42 extern void cifs_fscache_release_client_cookie(struct TCP_Server_Info *); 43 - extern void cifs_fscache_get_super_cookie(struct cifsTconInfo *); 44 - extern void cifs_fscache_release_super_cookie(struct cifsTconInfo *); 43 + extern void cifs_fscache_get_super_cookie(struct cifs_tcon *); 44 + extern void cifs_fscache_release_super_cookie(struct cifs_tcon *); 45 45 46 46 extern void cifs_fscache_release_inode_cookie(struct inode *); 47 47 extern void cifs_fscache_set_inode_cookie(struct inode *, struct file *); ··· 99 99 cifs_fscache_get_client_cookie(struct TCP_Server_Info *server) {} 100 100 static inline void 101 101 cifs_fscache_release_client_cookie(struct TCP_Server_Info *server) {} 102 - static inline void cifs_fscache_get_super_cookie(struct cifsTconInfo *tcon) {} 102 + static inline void cifs_fscache_get_super_cookie(struct cifs_tcon *tcon) {} 103 103 static inline void 104 - cifs_fscache_release_super_cookie(struct cifsTconInfo *tcon) {} 104 + cifs_fscache_release_super_cookie(struct cifs_tcon *tcon) {} 105 105 106 106 static inline void cifs_fscache_release_inode_cookie(struct inode *inode) {} 107 107 static inline void cifs_fscache_set_inode_cookie(struct inode *inode,
+20 -20
fs/cifs/inode.c
··· 295 295 struct inode *inode = filp->f_path.dentry->d_inode; 296 296 struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); 297 297 struct cifsFileInfo *cfile = filp->private_data; 298 - struct cifsTconInfo *tcon = tlink_tcon(cfile->tlink); 298 + struct cifs_tcon *tcon = tlink_tcon(cfile->tlink); 299 299 300 300 xid = GetXid(); 301 301 rc = CIFSSMBUnixQFileInfo(xid, tcon, cfile->netfid, &find_data); ··· 318 318 int rc; 319 319 FILE_UNIX_BASIC_INFO find_data; 320 320 struct cifs_fattr fattr; 321 - struct cifsTconInfo *tcon; 321 + struct cifs_tcon *tcon; 322 322 struct tcon_link *tlink; 323 323 struct cifs_sb_info *cifs_sb = CIFS_SB(sb); 324 324 ··· 373 373 int oplock = 0; 374 374 __u16 netfid; 375 375 struct tcon_link *tlink; 376 - struct cifsTconInfo *tcon; 376 + struct cifs_tcon *tcon; 377 377 struct cifs_io_parms io_parms; 378 378 char buf[24]; 379 379 unsigned int bytes_read; ··· 473 473 char ea_value[4]; 474 474 __u32 mode; 475 475 struct tcon_link *tlink; 476 - struct cifsTconInfo *tcon; 476 + struct cifs_tcon *tcon; 477 477 478 478 tlink = cifs_sb_tlink(cifs_sb); 479 479 if (IS_ERR(tlink)) ··· 507 507 cifs_all_info_to_fattr(struct cifs_fattr *fattr, FILE_ALL_INFO *info, 508 508 struct cifs_sb_info *cifs_sb, bool adjust_tz) 509 509 { 510 - struct cifsTconInfo *tcon = cifs_sb_master_tcon(cifs_sb); 510 + struct cifs_tcon *tcon = cifs_sb_master_tcon(cifs_sb); 511 511 512 512 memset(fattr, 0, sizeof(*fattr)); 513 513 fattr->cf_cifsattrs = le32_to_cpu(info->Attributes); ··· 558 558 struct inode *inode = filp->f_path.dentry->d_inode; 559 559 struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); 560 560 struct cifsFileInfo *cfile = filp->private_data; 561 - struct cifsTconInfo *tcon = tlink_tcon(cfile->tlink); 561 + struct cifs_tcon *tcon = tlink_tcon(cfile->tlink); 562 562 563 563 xid = GetXid(); 564 564 rc = CIFSSMBQFileInfo(xid, tcon, cfile->netfid, &find_data); ··· 595 595 struct super_block *sb, int xid, const __u16 *pfid) 596 596 { 597 597 int rc = 0, tmprc; 598 - struct cifsTconInfo *pTcon; 598 + struct cifs_tcon *pTcon; 599 599 struct tcon_link *tlink; 600 600 struct cifs_sb_info *cifs_sb = CIFS_SB(sb); 601 601 char *buf = NULL; ··· 741 741 }; 742 742 743 743 char *cifs_build_path_to_root(struct smb_vol *vol, struct cifs_sb_info *cifs_sb, 744 - struct cifsTconInfo *tcon) 744 + struct cifs_tcon *tcon) 745 745 { 746 746 int pplen = vol->prepath ? strlen(vol->prepath) : 0; 747 747 int dfsplen; ··· 889 889 struct cifs_sb_info *cifs_sb = CIFS_SB(sb); 890 890 struct inode *inode = NULL; 891 891 long rc; 892 - struct cifsTconInfo *tcon = cifs_sb_master_tcon(cifs_sb); 892 + struct cifs_tcon *tcon = cifs_sb_master_tcon(cifs_sb); 893 893 894 894 xid = GetXid(); 895 895 if (tcon->unix_ext) ··· 941 941 struct cifsInodeInfo *cifsInode = CIFS_I(inode); 942 942 struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); 943 943 struct tcon_link *tlink = NULL; 944 - struct cifsTconInfo *pTcon; 944 + struct cifs_tcon *pTcon; 945 945 FILE_BASIC_INFO info_buf; 946 946 947 947 if (attrs == NULL) ··· 1059 1059 struct cifsInodeInfo *cifsInode = CIFS_I(inode); 1060 1060 struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); 1061 1061 struct tcon_link *tlink; 1062 - struct cifsTconInfo *tcon; 1062 + struct cifs_tcon *tcon; 1063 1063 __u32 dosattr, origattr; 1064 1064 FILE_BASIC_INFO *info_buf = NULL; 1065 1065 ··· 1177 1177 struct super_block *sb = dir->i_sb; 1178 1178 struct cifs_sb_info *cifs_sb = CIFS_SB(sb); 1179 1179 struct tcon_link *tlink; 1180 - struct cifsTconInfo *tcon; 1180 + struct cifs_tcon *tcon; 1181 1181 struct iattr *attrs = NULL; 1182 1182 __u32 dosattr = 0, origattr = 0; 1183 1183 ··· 1275 1275 int xid; 1276 1276 struct cifs_sb_info *cifs_sb; 1277 1277 struct tcon_link *tlink; 1278 - struct cifsTconInfo *pTcon; 1278 + struct cifs_tcon *pTcon; 1279 1279 char *full_path = NULL; 1280 1280 struct inode *newinode = NULL; 1281 1281 struct cifs_fattr fattr; ··· 1453 1453 int xid; 1454 1454 struct cifs_sb_info *cifs_sb; 1455 1455 struct tcon_link *tlink; 1456 - struct cifsTconInfo *pTcon; 1456 + struct cifs_tcon *pTcon; 1457 1457 char *full_path = NULL; 1458 1458 struct cifsInodeInfo *cifsInode; 1459 1459 ··· 1510 1510 { 1511 1511 struct cifs_sb_info *cifs_sb = CIFS_SB(from_dentry->d_sb); 1512 1512 struct tcon_link *tlink; 1513 - struct cifsTconInfo *pTcon; 1513 + struct cifs_tcon *pTcon; 1514 1514 __u16 srcfid; 1515 1515 int oplock, rc; 1516 1516 ··· 1562 1562 char *toName = NULL; 1563 1563 struct cifs_sb_info *cifs_sb; 1564 1564 struct tcon_link *tlink; 1565 - struct cifsTconInfo *tcon; 1565 + struct cifs_tcon *tcon; 1566 1566 FILE_UNIX_BASIC_INFO *info_buf_source = NULL; 1567 1567 FILE_UNIX_BASIC_INFO *info_buf_target; 1568 1568 int xid, rc, tmprc; ··· 1792 1792 struct kstat *stat) 1793 1793 { 1794 1794 struct cifs_sb_info *cifs_sb = CIFS_SB(dentry->d_sb); 1795 - struct cifsTconInfo *tcon = cifs_sb_master_tcon(cifs_sb); 1795 + struct cifs_tcon *tcon = cifs_sb_master_tcon(cifs_sb); 1796 1796 struct inode *inode = dentry->d_inode; 1797 1797 int rc; 1798 1798 ··· 1870 1870 struct cifsInodeInfo *cifsInode = CIFS_I(inode); 1871 1871 struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); 1872 1872 struct tcon_link *tlink = NULL; 1873 - struct cifsTconInfo *pTcon = NULL; 1873 + struct cifs_tcon *pTcon = NULL; 1874 1874 struct cifs_io_parms io_parms; 1875 1875 1876 1876 /* ··· 1971 1971 struct cifsInodeInfo *cifsInode = CIFS_I(inode); 1972 1972 struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); 1973 1973 struct tcon_link *tlink; 1974 - struct cifsTconInfo *pTcon; 1974 + struct cifs_tcon *pTcon; 1975 1975 struct cifs_unix_set_info_args *args = NULL; 1976 1976 struct cifsFileInfo *open_file; 1977 1977 ··· 2257 2257 { 2258 2258 struct inode *inode = direntry->d_inode; 2259 2259 struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); 2260 - struct cifsTconInfo *pTcon = cifs_sb_master_tcon(cifs_sb); 2260 + struct cifs_tcon *pTcon = cifs_sb_master_tcon(cifs_sb); 2261 2261 2262 2262 if (pTcon->unix_ext) 2263 2263 return cifs_setattr_unix(direntry, attrs);
+1 -1
fs/cifs/ioctl.c
··· 38 38 struct cifs_sb_info *cifs_sb; 39 39 #ifdef CONFIG_CIFS_POSIX 40 40 struct cifsFileInfo *pSMBFile = filep->private_data; 41 - struct cifsTconInfo *tcon; 41 + struct cifs_tcon *tcon; 42 42 __u64 ExtAttrBits = 0; 43 43 __u64 ExtAttrMask = 0; 44 44 __u64 caps;
+6 -6
fs/cifs/link.c
··· 175 175 } 176 176 177 177 static int 178 - CIFSCreateMFSymLink(const int xid, struct cifsTconInfo *tcon, 178 + CIFSCreateMFSymLink(const int xid, struct cifs_tcon *tcon, 179 179 const char *fromName, const char *toName, 180 180 const struct nls_table *nls_codepage, int remap) 181 181 { ··· 223 223 } 224 224 225 225 static int 226 - CIFSQueryMFSymLink(const int xid, struct cifsTconInfo *tcon, 226 + CIFSQueryMFSymLink(const int xid, struct cifs_tcon *tcon, 227 227 const unsigned char *searchName, char **symlinkinfo, 228 228 const struct nls_table *nls_codepage, int remap) 229 229 { ··· 298 298 int oplock = 0; 299 299 __u16 netfid = 0; 300 300 struct tcon_link *tlink; 301 - struct cifsTconInfo *pTcon; 301 + struct cifs_tcon *pTcon; 302 302 struct cifs_io_parms io_parms; 303 303 u8 *buf; 304 304 char *pbuf; ··· 380 380 char *toName = NULL; 381 381 struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); 382 382 struct tcon_link *tlink; 383 - struct cifsTconInfo *pTcon; 383 + struct cifs_tcon *pTcon; 384 384 struct cifsInodeInfo *cifsInode; 385 385 386 386 tlink = cifs_sb_tlink(cifs_sb); ··· 455 455 char *target_path = NULL; 456 456 struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); 457 457 struct tcon_link *tlink = NULL; 458 - struct cifsTconInfo *tcon; 458 + struct cifs_tcon *tcon; 459 459 460 460 xid = GetXid(); 461 461 ··· 528 528 int xid; 529 529 struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); 530 530 struct tcon_link *tlink; 531 - struct cifsTconInfo *pTcon; 531 + struct cifs_tcon *pTcon; 532 532 char *full_path = NULL; 533 533 struct inode *newinode = NULL; 534 534
+16 -16
fs/cifs/misc.c
··· 67 67 spin_unlock(&GlobalMid_Lock); 68 68 } 69 69 70 - struct cifsSesInfo * 70 + struct cifs_ses * 71 71 sesInfoAlloc(void) 72 72 { 73 - struct cifsSesInfo *ret_buf; 73 + struct cifs_ses *ret_buf; 74 74 75 - ret_buf = kzalloc(sizeof(struct cifsSesInfo), GFP_KERNEL); 75 + ret_buf = kzalloc(sizeof(struct cifs_ses), GFP_KERNEL); 76 76 if (ret_buf) { 77 77 atomic_inc(&sesInfoAllocCount); 78 78 ret_buf->status = CifsNew; ··· 85 85 } 86 86 87 87 void 88 - sesInfoFree(struct cifsSesInfo *buf_to_free) 88 + sesInfoFree(struct cifs_ses *buf_to_free) 89 89 { 90 90 if (buf_to_free == NULL) { 91 91 cFYI(1, "Null buffer passed to sesInfoFree"); ··· 105 105 kfree(buf_to_free); 106 106 } 107 107 108 - struct cifsTconInfo * 108 + struct cifs_tcon * 109 109 tconInfoAlloc(void) 110 110 { 111 - struct cifsTconInfo *ret_buf; 112 - ret_buf = kzalloc(sizeof(struct cifsTconInfo), GFP_KERNEL); 111 + struct cifs_tcon *ret_buf; 112 + ret_buf = kzalloc(sizeof(struct cifs_tcon), GFP_KERNEL); 113 113 if (ret_buf) { 114 114 atomic_inc(&tconInfoAllocCount); 115 115 ret_buf->tidStatus = CifsNew; ··· 124 124 } 125 125 126 126 void 127 - tconInfoFree(struct cifsTconInfo *buf_to_free) 127 + tconInfoFree(struct cifs_tcon *buf_to_free) 128 128 { 129 129 if (buf_to_free == NULL) { 130 130 cFYI(1, "Null buffer passed to tconInfoFree"); ··· 295 295 case it is responsbility of caller to set the mid */ 296 296 void 297 297 header_assemble(struct smb_hdr *buffer, char smb_command /* command */ , 298 - const struct cifsTconInfo *treeCon, int word_count 298 + const struct cifs_tcon *treeCon, int word_count 299 299 /* length of fixed section (word count) in two byte units */) 300 300 { 301 301 struct list_head *temp_item; 302 - struct cifsSesInfo *ses; 302 + struct cifs_ses *ses; 303 303 char *temp = (char *) buffer; 304 304 305 305 memset(temp, 0, 256); /* bigger than MAX_CIFS_HDR_SIZE */ ··· 359 359 "did not match tcon uid"); 360 360 spin_lock(&cifs_tcp_ses_lock); 361 361 list_for_each(temp_item, &treeCon->ses->server->smb_ses_list) { 362 - ses = list_entry(temp_item, struct cifsSesInfo, smb_ses_list); 362 + ses = list_entry(temp_item, struct cifs_ses, smb_ses_list); 363 363 if (ses->linux_uid == current_fsuid()) { 364 364 if (ses->server == treeCon->ses->server) { 365 365 cFYI(1, "found matching uid substitute right smb_uid"); ··· 380 380 if (treeCon->nocase) 381 381 buffer->Flags |= SMBFLG_CASELESS; 382 382 if ((treeCon->ses) && (treeCon->ses->server)) 383 - if (treeCon->ses->server->secMode & 383 + if (treeCon->ses->server->sec_mode & 384 384 (SECMODE_SIGN_REQUIRED | SECMODE_SIGN_ENABLED)) 385 385 buffer->Flags2 |= SMBFLG2_SECURITY_SIGNATURE; 386 386 } ··· 507 507 { 508 508 struct smb_com_lock_req *pSMB = (struct smb_com_lock_req *)buf; 509 509 struct list_head *tmp, *tmp1, *tmp2; 510 - struct cifsSesInfo *ses; 511 - struct cifsTconInfo *tcon; 510 + struct cifs_ses *ses; 511 + struct cifs_tcon *tcon; 512 512 struct cifsInodeInfo *pCifsInode; 513 513 struct cifsFileInfo *netfile; 514 514 ··· 566 566 /* look up tcon based on tid & uid */ 567 567 spin_lock(&cifs_tcp_ses_lock); 568 568 list_for_each(tmp, &srv->smb_ses_list) { 569 - ses = list_entry(tmp, struct cifsSesInfo, smb_ses_list); 569 + ses = list_entry(tmp, struct cifs_ses, smb_ses_list); 570 570 list_for_each(tmp1, &ses->tcon_list) { 571 - tcon = list_entry(tmp1, struct cifsTconInfo, tcon_list); 571 + tcon = list_entry(tmp1, struct cifs_tcon, tcon_list); 572 572 if (tcon->tid != buf->Tid) 573 573 continue; 574 574
+4 -4
fs/cifs/readdir.c
··· 195 195 int len; 196 196 int oplock = 0; 197 197 int rc; 198 - struct cifsTconInfo *ptcon = cifs_sb_tcon(cifs_sb); 198 + struct cifs_tcon *ptcon = cifs_sb_tcon(cifs_sb); 199 199 char *tmpbuffer; 200 200 201 201 rc = CIFSSMBOpen(xid, ptcon, full_path, FILE_OPEN, GENERIC_READ, ··· 223 223 struct cifsFileInfo *cifsFile; 224 224 struct cifs_sb_info *cifs_sb = CIFS_SB(file->f_path.dentry->d_sb); 225 225 struct tcon_link *tlink = NULL; 226 - struct cifsTconInfo *pTcon; 226 + struct cifs_tcon *pTcon; 227 227 228 228 if (file->private_data == NULL) { 229 229 tlink = cifs_sb_tlink(cifs_sb); ··· 496 496 assume that they are located in the findfirst return buffer.*/ 497 497 /* We start counting in the buffer with entry 2 and increment for every 498 498 entry (do not increment for . or .. entry) */ 499 - static int find_cifs_entry(const int xid, struct cifsTconInfo *pTcon, 499 + static int find_cifs_entry(const int xid, struct cifs_tcon *pTcon, 500 500 struct file *file, char **ppCurrentEntry, int *num_to_ret) 501 501 { 502 502 int rc = 0; ··· 764 764 { 765 765 int rc = 0; 766 766 int xid, i; 767 - struct cifsTconInfo *pTcon; 767 + struct cifs_tcon *pTcon; 768 768 struct cifsFileInfo *cifsFile = NULL; 769 769 char *current_entry; 770 770 int num_to_fill = 0;
+21 -21
fs/cifs/sess.c
··· 37 37 * the socket has been reestablished (so we know whether to use vc 0). 38 38 * Called while holding the cifs_tcp_ses_lock, so do not block 39 39 */ 40 - static bool is_first_ses_reconnect(struct cifsSesInfo *ses) 40 + static bool is_first_ses_reconnect(struct cifs_ses *ses) 41 41 { 42 42 struct list_head *tmp; 43 - struct cifsSesInfo *tmp_ses; 43 + struct cifs_ses *tmp_ses; 44 44 45 45 list_for_each(tmp, &ses->server->smb_ses_list) { 46 - tmp_ses = list_entry(tmp, struct cifsSesInfo, 46 + tmp_ses = list_entry(tmp, struct cifs_ses, 47 47 smb_ses_list); 48 48 if (tmp_ses->need_reconnect == false) 49 49 return false; ··· 61 61 * any vc but zero (some servers reset the connection on vcnum zero) 62 62 * 63 63 */ 64 - static __le16 get_next_vcnum(struct cifsSesInfo *ses) 64 + static __le16 get_next_vcnum(struct cifs_ses *ses) 65 65 { 66 66 __u16 vcnum = 0; 67 67 struct list_head *tmp; 68 - struct cifsSesInfo *tmp_ses; 68 + struct cifs_ses *tmp_ses; 69 69 __u16 max_vcs = ses->server->max_vcs; 70 70 __u16 i; 71 71 int free_vc_found = 0; ··· 87 87 free_vc_found = 1; 88 88 89 89 list_for_each(tmp, &ses->server->smb_ses_list) { 90 - tmp_ses = list_entry(tmp, struct cifsSesInfo, 90 + tmp_ses = list_entry(tmp, struct cifs_ses, 91 91 smb_ses_list); 92 92 if (tmp_ses->vcnum == i) { 93 93 free_vc_found = 0; ··· 114 114 return cpu_to_le16(vcnum); 115 115 } 116 116 117 - static __u32 cifs_ssetup_hdr(struct cifsSesInfo *ses, SESSION_SETUP_ANDX *pSMB) 117 + static __u32 cifs_ssetup_hdr(struct cifs_ses *ses, SESSION_SETUP_ANDX *pSMB) 118 118 { 119 119 __u32 capabilities = 0; 120 120 ··· 136 136 capabilities = CAP_LARGE_FILES | CAP_NT_SMBS | CAP_LEVEL_II_OPLOCKS | 137 137 CAP_LARGE_WRITE_X | CAP_LARGE_READ_X; 138 138 139 - if (ses->server->secMode & 139 + if (ses->server->sec_mode & 140 140 (SECMODE_SIGN_REQUIRED | SECMODE_SIGN_ENABLED)) 141 141 pSMB->req.hdr.Flags2 |= SMBFLG2_SECURITY_SIGNATURE; 142 142 ··· 181 181 *pbcc_area = bcc_ptr; 182 182 } 183 183 184 - static void unicode_domain_string(char **pbcc_area, struct cifsSesInfo *ses, 184 + static void unicode_domain_string(char **pbcc_area, struct cifs_ses *ses, 185 185 const struct nls_table *nls_cp) 186 186 { 187 187 char *bcc_ptr = *pbcc_area; ··· 204 204 } 205 205 206 206 207 - static void unicode_ssetup_strings(char **pbcc_area, struct cifsSesInfo *ses, 207 + static void unicode_ssetup_strings(char **pbcc_area, struct cifs_ses *ses, 208 208 const struct nls_table *nls_cp) 209 209 { 210 210 char *bcc_ptr = *pbcc_area; ··· 236 236 *pbcc_area = bcc_ptr; 237 237 } 238 238 239 - static void ascii_ssetup_strings(char **pbcc_area, struct cifsSesInfo *ses, 239 + static void ascii_ssetup_strings(char **pbcc_area, struct cifs_ses *ses, 240 240 const struct nls_table *nls_cp) 241 241 { 242 242 char *bcc_ptr = *pbcc_area; ··· 276 276 } 277 277 278 278 static void 279 - decode_unicode_ssetup(char **pbcc_area, int bleft, struct cifsSesInfo *ses, 279 + decode_unicode_ssetup(char **pbcc_area, int bleft, struct cifs_ses *ses, 280 280 const struct nls_table *nls_cp) 281 281 { 282 282 int len; ··· 310 310 } 311 311 312 312 static int decode_ascii_ssetup(char **pbcc_area, __u16 bleft, 313 - struct cifsSesInfo *ses, 313 + struct cifs_ses *ses, 314 314 const struct nls_table *nls_cp) 315 315 { 316 316 int rc = 0; ··· 364 364 } 365 365 366 366 static int decode_ntlmssp_challenge(char *bcc_ptr, int blob_len, 367 - struct cifsSesInfo *ses) 367 + struct cifs_ses *ses) 368 368 { 369 369 unsigned int tioffset; /* challenge message target info area */ 370 370 unsigned int tilen; /* challenge message target info area length */ ··· 411 411 /* We do not malloc the blob, it is passed in pbuffer, because 412 412 it is fixed size, and small, making this approach cleaner */ 413 413 static void build_ntlmssp_negotiate_blob(unsigned char *pbuffer, 414 - struct cifsSesInfo *ses) 414 + struct cifs_ses *ses) 415 415 { 416 416 NEGOTIATE_MESSAGE *sec_blob = (NEGOTIATE_MESSAGE *)pbuffer; 417 417 __u32 flags; ··· 424 424 flags = NTLMSSP_NEGOTIATE_56 | NTLMSSP_REQUEST_TARGET | 425 425 NTLMSSP_NEGOTIATE_128 | NTLMSSP_NEGOTIATE_UNICODE | 426 426 NTLMSSP_NEGOTIATE_NTLM | NTLMSSP_NEGOTIATE_EXTENDED_SEC; 427 - if (ses->server->secMode & 427 + if (ses->server->sec_mode & 428 428 (SECMODE_SIGN_REQUIRED | SECMODE_SIGN_ENABLED)) { 429 429 flags |= NTLMSSP_NEGOTIATE_SIGN; 430 430 if (!ses->server->session_estab) ··· 449 449 This function returns the length of the data in the blob */ 450 450 static int build_ntlmssp_auth_blob(unsigned char *pbuffer, 451 451 u16 *buflen, 452 - struct cifsSesInfo *ses, 452 + struct cifs_ses *ses, 453 453 const struct nls_table *nls_cp) 454 454 { 455 455 int rc; ··· 464 464 NTLMSSP_REQUEST_TARGET | NTLMSSP_NEGOTIATE_TARGET_INFO | 465 465 NTLMSSP_NEGOTIATE_128 | NTLMSSP_NEGOTIATE_UNICODE | 466 466 NTLMSSP_NEGOTIATE_NTLM | NTLMSSP_NEGOTIATE_EXTENDED_SEC; 467 - if (ses->server->secMode & 467 + if (ses->server->sec_mode & 468 468 (SECMODE_SIGN_REQUIRED | SECMODE_SIGN_ENABLED)) 469 469 flags |= NTLMSSP_NEGOTIATE_SIGN; 470 - if (ses->server->secMode & SECMODE_SIGN_REQUIRED) 470 + if (ses->server->sec_mode & SECMODE_SIGN_REQUIRED) 471 471 flags |= NTLMSSP_NEGOTIATE_ALWAYS_SIGN; 472 472 473 473 tmp = pbuffer + sizeof(AUTHENTICATE_MESSAGE); ··· 551 551 } 552 552 553 553 int 554 - CIFS_SessSetup(unsigned int xid, struct cifsSesInfo *ses, 554 + CIFS_SessSetup(unsigned int xid, struct cifs_ses *ses, 555 555 const struct nls_table *nls_cp) 556 556 { 557 557 int rc = 0; ··· 657 657 */ 658 658 659 659 rc = calc_lanman_hash(ses->password, ses->server->cryptkey, 660 - ses->server->secMode & SECMODE_PW_ENCRYPT ? 660 + ses->server->sec_mode & SECMODE_PW_ENCRYPT ? 661 661 true : false, lnm_session_key); 662 662 663 663 ses->flags |= CIFS_SES_LANMAN;
+10 -10
fs/cifs/transport.c
··· 295 295 return 0; 296 296 } 297 297 298 - static int allocate_mid(struct cifsSesInfo *ses, struct smb_hdr *in_buf, 298 + static int allocate_mid(struct cifs_ses *ses, struct smb_hdr *in_buf, 299 299 struct mid_q_entry **ppmidQ) 300 300 { 301 301 if (ses->server->tcpStatus == CifsExiting) { ··· 355 355 return rc; 356 356 357 357 /* enable signing if server requires it */ 358 - if (server->secMode & (SECMODE_SIGN_REQUIRED | SECMODE_SIGN_ENABLED)) 358 + if (server->sec_mode & (SECMODE_SIGN_REQUIRED | SECMODE_SIGN_ENABLED)) 359 359 hdr->Flags2 |= SMBFLG2_SECURITY_SIGNATURE; 360 360 361 361 mutex_lock(&server->srv_mutex); ··· 409 409 * 410 410 */ 411 411 int 412 - SendReceiveNoRsp(const unsigned int xid, struct cifsSesInfo *ses, 412 + SendReceiveNoRsp(const unsigned int xid, struct cifs_ses *ses, 413 413 struct smb_hdr *in_buf, int flags) 414 414 { 415 415 int rc; ··· 504 504 min_t(u32, 92, be32_to_cpu(mid->resp_buf->smb_buf_length))); 505 505 506 506 /* convert the length into a more usable form */ 507 - if (server->secMode & (SECMODE_SIGN_REQUIRED | SECMODE_SIGN_ENABLED)) { 507 + if (server->sec_mode & (SECMODE_SIGN_REQUIRED | SECMODE_SIGN_ENABLED)) { 508 508 /* FIXME: add code to kill session */ 509 509 if (cifs_verify_signature(mid->resp_buf, server, 510 510 mid->sequence_number + 1) != 0) ··· 516 516 } 517 517 518 518 int 519 - SendReceive2(const unsigned int xid, struct cifsSesInfo *ses, 519 + SendReceive2(const unsigned int xid, struct cifs_ses *ses, 520 520 struct kvec *iov, int n_vec, int *pRespBufType /* ret */, 521 521 const int flags) 522 522 { ··· 645 645 } 646 646 647 647 int 648 - SendReceive(const unsigned int xid, struct cifsSesInfo *ses, 648 + SendReceive(const unsigned int xid, struct cifs_ses *ses, 649 649 struct smb_hdr *in_buf, struct smb_hdr *out_buf, 650 650 int *pbytes_returned, const int long_op) 651 651 { ··· 761 761 blocking lock to return. */ 762 762 763 763 static int 764 - send_lock_cancel(const unsigned int xid, struct cifsTconInfo *tcon, 764 + send_lock_cancel(const unsigned int xid, struct cifs_tcon *tcon, 765 765 struct smb_hdr *in_buf, 766 766 struct smb_hdr *out_buf) 767 767 { 768 768 int bytes_returned; 769 - struct cifsSesInfo *ses = tcon->ses; 769 + struct cifs_ses *ses = tcon->ses; 770 770 LOCK_REQ *pSMB = (LOCK_REQ *)in_buf; 771 771 772 772 /* We just modify the current in_buf to change ··· 783 783 } 784 784 785 785 int 786 - SendReceiveBlockingLock(const unsigned int xid, struct cifsTconInfo *tcon, 786 + SendReceiveBlockingLock(const unsigned int xid, struct cifs_tcon *tcon, 787 787 struct smb_hdr *in_buf, struct smb_hdr *out_buf, 788 788 int *pbytes_returned) 789 789 { 790 790 int rc = 0; 791 791 int rstart = 0; 792 792 struct mid_q_entry *midQ; 793 - struct cifsSesInfo *ses; 793 + struct cifs_ses *ses; 794 794 795 795 if (tcon == NULL || tcon->ses == NULL) { 796 796 cERROR(1, "Null smb session");
+4 -4
fs/cifs/xattr.c
··· 49 49 int xid; 50 50 struct cifs_sb_info *cifs_sb; 51 51 struct tcon_link *tlink; 52 - struct cifsTconInfo *pTcon; 52 + struct cifs_tcon *pTcon; 53 53 struct super_block *sb; 54 54 char *full_path = NULL; 55 55 ··· 109 109 int xid; 110 110 struct cifs_sb_info *cifs_sb; 111 111 struct tcon_link *tlink; 112 - struct cifsTconInfo *pTcon; 112 + struct cifs_tcon *pTcon; 113 113 struct super_block *sb; 114 114 char *full_path; 115 115 struct cifs_ntsd *pacl; ··· 240 240 int xid; 241 241 struct cifs_sb_info *cifs_sb; 242 242 struct tcon_link *tlink; 243 - struct cifsTconInfo *pTcon; 243 + struct cifs_tcon *pTcon; 244 244 struct super_block *sb; 245 245 char *full_path; 246 246 ··· 372 372 int xid; 373 373 struct cifs_sb_info *cifs_sb; 374 374 struct tcon_link *tlink; 375 - struct cifsTconInfo *pTcon; 375 + struct cifs_tcon *pTcon; 376 376 struct super_block *sb; 377 377 char *full_path; 378 378