Lines Matching refs:ses
132 struct cifs_ses *ses; in cifs_reconnect_tcon() local
145 ses = tcon->ses; in cifs_reconnect_tcon()
146 server = ses->server; in cifs_reconnect_tcon()
198 if (!ses->need_reconnect && !tcon->need_reconnect) in cifs_reconnect_tcon()
207 mutex_lock(&ses->session_mutex); in cifs_reconnect_tcon()
216 mutex_unlock(&ses->session_mutex); in cifs_reconnect_tcon()
220 rc = cifs_negotiate_protocol(0, ses); in cifs_reconnect_tcon()
221 if (rc == 0 && ses->need_reconnect) in cifs_reconnect_tcon()
222 rc = cifs_setup_session(0, ses, nls_codepage); in cifs_reconnect_tcon()
226 mutex_unlock(&ses->session_mutex); in cifs_reconnect_tcon()
232 mutex_unlock(&ses->session_mutex); in cifs_reconnect_tcon()
243 if (cap_unix(ses)) in cifs_reconnect_tcon()
301 struct cifs_ses *ses, void **request_buf) in small_smb_init_no_tc() argument
311 buffer->Mid = get_next_mid(ses->server); in small_smb_init_no_tc()
312 if (ses->capabilities & CAP_UNICODE) in small_smb_init_no_tc()
314 if (ses->capabilities & CAP_STATUS32) in small_smb_init_no_tc()
369 if (tcon->ses->need_reconnect || tcon->need_reconnect) in smb_init_no_reconnect()
408 decode_ext_sec_blob(struct cifs_ses *ses, NEGOTIATE_RSP *pSMBr) in decode_ext_sec_blob() argument
413 struct TCP_Server_Info *server = ses->server; in decode_ext_sec_blob()
591 CIFSSMBNegotiate(const unsigned int xid, struct cifs_ses *ses) in CIFSSMBNegotiate() argument
598 struct TCP_Server_Info *server = ses->server; in CIFSSMBNegotiate()
614 if (should_set_ext_sec_flag(ses->sectype)) { in CIFSSMBNegotiate()
633 rc = SendReceive(xid, ses, (struct smb_hdr *) pSMB, in CIFSSMBNegotiate()
672 cifs_dbg(NOISY, "Max buf = %d\n", ses->server->maxBuf); in CIFSSMBNegotiate()
679 memcpy(ses->server->cryptkey, pSMBr->u.EncryptionKey, in CIFSSMBNegotiate()
684 rc = decode_ext_sec_blob(ses, pSMBr); in CIFSSMBNegotiate()
694 rc = cifs_enable_signing(server, ses->sign); in CIFSSMBNegotiate()
711 if ((tcon->ses == NULL) || (tcon->ses->server == NULL)) in CIFSSMBTDis()
720 if ((tcon->need_reconnect) || (tcon->ses->need_reconnect)) in CIFSSMBTDis()
728 rc = SendReceiveNoRsp(xid, tcon->ses, (char *)smb_buffer, 0); in CIFSSMBTDis()
800 CIFSSMBLogoff(const unsigned int xid, struct cifs_ses *ses) in CIFSSMBLogoff() argument
812 if (!ses || !ses->server) in CIFSSMBLogoff()
815 mutex_lock(&ses->session_mutex); in CIFSSMBLogoff()
816 if (ses->need_reconnect) in CIFSSMBLogoff()
821 mutex_unlock(&ses->session_mutex); in CIFSSMBLogoff()
825 pSMB->hdr.Mid = get_next_mid(ses->server); in CIFSSMBLogoff()
827 if (ses->server->sign) in CIFSSMBLogoff()
830 pSMB->hdr.Uid = ses->Suid; in CIFSSMBLogoff()
833 rc = SendReceiveNoRsp(xid, ses, (char *) pSMB, 0); in CIFSSMBLogoff()
836 mutex_unlock(&ses->session_mutex); in CIFSSMBLogoff()
906 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSPOSIXDelFile()
951 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBDelFile()
995 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBRmDir()
1039 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBMkDir()
1116 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSPOSIXCreate()
1280 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in SMBLegacyOpen()
1386 if (tcon->ses->capabilities & CAP_UNIX) in CIFS_open()
1404 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *)req, in CIFS_open()
1623 struct TCP_Server_Info *server = tcon->ses->server; in cifs_readv_callback()
1686 if (tcon->ses->capabilities & CAP_LARGE_FILES) in cifs_async_readv()
1727 rc = cifs_call_async(tcon->ses->server, &rqst, cifs_readv_receive, in cifs_async_readv()
1758 if (tcon->ses->capabilities & CAP_LARGE_FILES) in CIFSSMBRead()
1777 if (tcon->ses->server == NULL) in CIFSSMBRead()
1800 rc = SendReceive2(xid, tcon->ses, iov, 1, &resp_buf_type, in CIFSSMBRead()
1868 if (tcon->ses == NULL) in CIFSSMBWrite()
1871 if (tcon->ses->capabilities & CAP_LARGE_FILES) in CIFSSMBWrite()
1890 if (tcon->ses->server == NULL) in CIFSSMBWrite()
1907 if (tcon->ses->capabilities & CAP_LARGE_WRITE_X) { in CIFSSMBWrite()
1910 bytes_sent = (tcon->ses->server->maxBuf - MAX_CIFS_HDR_SIZE) in CIFSSMBWrite()
1943 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBWrite()
2001 server = tlink_tcon(wdata->cfile->tlink)->ses->server; in cifs_writev_requeue()
2161 wdata->result = cifs_check_receive(mid, tcon->ses->server, 0); in cifs_writev_callback()
2193 add_credits(tcon->ses->server, &credits, 0); in cifs_writev_callback()
2208 if (tcon->ses->capabilities & CAP_LARGE_FILES) { in cifs_async_writev()
2270 rc = cifs_call_async(tcon->ses->server, &rqst, NULL, in cifs_async_writev()
2303 if (tcon->ses->capabilities & CAP_LARGE_FILES) { in CIFSSMBWrite2()
2320 if (tcon->ses->server == NULL) in CIFSSMBWrite2()
2356 rc = SendReceive2(xid, tcon->ses, iov, n_vec + 1, &resp_buf_type, 0, in CIFSSMBWrite2()
2424 rc = SendReceive2(xid, tcon->ses, iov, 2, &resp_buf_type, in cifs_lockv()
2491 rc = SendReceiveNoRsp(xid, tcon->ses, (char *)pSMB, flags); in CIFSSMBLock()
2579 rc = SendReceive2(xid, tcon->ses, iov, 1 /* num iovecs */, in CIFSSMBPosixLock()
2649 rc = SendReceiveNoRsp(xid, tcon->ses, (char *) pSMB, 0); in CIFSSMBClose()
2679 rc = SendReceiveNoRsp(xid, tcon->ses, (char *) pSMB, 0); in CIFSSMBFlush()
2739 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBRename()
2820 rc = SendReceive(xid, pTcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBRenameOpenFile()
2884 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBCopy()
2969 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSUnixCreateSymLink()
3052 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSUnixCreateHardLink()
3122 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSCreateHardLink()
3192 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBUnixQuerySymLink()
3280 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBQuerySymLink()
3400 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMB_set_compression()
3612 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBGetPosixACL()
3703 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBSetPosixACL()
3762 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSGetExtAttr()
3921 rc = SendReceive2(xid, tcon->ses, iov, 1 /* num iovec */, &buf_type, in CIFSSMBGetCIFSACL()
4027 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBSetCIFSACL()
4078 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in SMBQueryInformation()
4153 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBQFileInfo()
4238 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBQPathInfo()
4320 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBUnixQFileInfo()
4402 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBUnixQPathInfo()
4519 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSFindFirst()
4647 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSFindNext()
4736 rc = SendReceiveNoRsp(xid, tcon->ses, (char *) pSMB, 0); in CIFSFindClose()
4807 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSGetSrvInodeNumber()
4842 CIFSGetDFSRefer(const unsigned int xid, struct cifs_ses *ses, in CIFSGetDFSRefer() argument
4858 if (ses == NULL || ses->tcon_ipc == NULL) in CIFSGetDFSRefer()
4862 rc = smb_init(SMB_COM_TRANSACTION2, 15, ses->tcon_ipc, (void **) &pSMB, in CIFSGetDFSRefer()
4869 pSMB->hdr.Mid = get_next_mid(ses->server); in CIFSGetDFSRefer()
4870 pSMB->hdr.Tid = ses->tcon_ipc->tid; in CIFSGetDFSRefer()
4871 pSMB->hdr.Uid = ses->Suid; in CIFSGetDFSRefer()
4872 if (ses->capabilities & CAP_STATUS32) in CIFSGetDFSRefer()
4874 if (ses->capabilities & CAP_DFS) in CIFSGetDFSRefer()
4877 if (ses->capabilities & CAP_UNICODE) { in CIFSGetDFSRefer()
4889 if (ses->server->sign) in CIFSGetDFSRefer()
4892 pSMB->hdr.Uid = ses->Suid; in CIFSGetDFSRefer()
4918 rc = SendReceive(xid, ses, (struct smb_hdr *) pSMB, in CIFSGetDFSRefer()
4994 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in SMBOldQFSInfo()
5081 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBQFSInfo()
5168 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBQFSAttributeInfo()
5239 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBQFSDeviceInfo()
5309 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBQFSUnixInfo()
5392 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBSetFSUnixInfo()
5454 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBQFSPosixInfo()
5555 if (tcon->ses->capabilities & CAP_INFOLEVEL_PASSTHRU) in CIFSSMBSetEOF()
5562 if (tcon->ses->capabilities & CAP_INFOLEVEL_PASSTHRU) in CIFSSMBSetEOF()
5587 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBSetEOF()
5648 if (tcon->ses->capabilities & CAP_INFOLEVEL_PASSTHRU) in CIFSSMBSetFileSize()
5655 if (tcon->ses->capabilities & CAP_INFOLEVEL_PASSTHRU) in CIFSSMBSetFileSize()
5665 rc = SendReceiveNoRsp(xid, tcon->ses, (char *) pSMB, 0); in CIFSSMBSetFileSize()
5729 if (tcon->ses->capabilities & CAP_INFOLEVEL_PASSTHRU) in CIFSSMBSetFileInfo()
5737 rc = SendReceiveNoRsp(xid, tcon->ses, (char *) pSMB, 0); in CIFSSMBSetFileInfo()
5798 rc = SendReceiveNoRsp(xid, tcon->ses, (char *) pSMB, 0); in CIFSSMBSetFileDisposition()
5895 if (tcon->ses->capabilities & CAP_INFOLEVEL_PASSTHRU) in CIFSSMBSetPathInfo()
5903 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBSetPathInfo()
5956 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB,
6071 rc = SendReceiveNoRsp(xid, tcon->ses, (char *) pSMB, 0); in CIFSSMBUnixSetFileInfo()
6148 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBUnixSetPathInfo()
6232 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBQAllEAs()
6445 rc = SendReceive(xid, tcon->ses, (struct smb_hdr *) pSMB, in CIFSSMBSetEA()