Lines Matching refs:cpu_to_le16
104 hdr->StructureSize = cpu_to_le16(64); in smb2_hdr_assemble()
106 hdr->CreditRequest = cpu_to_le16(2); /* BB make this dynamic */ in smb2_hdr_assemble()
116 hdr->CreditCharge = cpu_to_le16(1); in smb2_hdr_assemble()
140 pdu->StructureSize2 = cpu_to_le16(parmsize); in smb2_hdr_assemble()
313 #define SMB2_PREAUTH_INTEGRITY_CAPABILITIES cpu_to_le16(1)
314 #define SMB2_ENCRYPTION_CAPABILITIES cpu_to_le16(2)
320 pneg_ctxt->DataLength = cpu_to_le16(38); in build_preauth_ctxt()
321 pneg_ctxt->HashAlgorithmCount = cpu_to_le16(1); in build_preauth_ctxt()
322 pneg_ctxt->SaltLength = cpu_to_le16(SMB311_SALT_SIZE); in build_preauth_ctxt()
331 pneg_ctxt->DataLength = cpu_to_le16(6); in build_encrypt_ctxt()
332 pneg_ctxt->CipherCount = cpu_to_le16(2); in build_encrypt_ctxt()
349 req->NegotiateContextCount = cpu_to_le16(2); in assemble_neg_contexts()
402 req->Dialects[0] = cpu_to_le16(ses->server->vals->protocol_id); in SMB2_negotiate()
404 req->DialectCount = cpu_to_le16(1); /* One vers= at a time for now */ in SMB2_negotiate()
409 req->SecurityMode = cpu_to_le16(SMB2_NEGOTIATE_SIGNING_REQUIRED); in SMB2_negotiate()
411 req->SecurityMode = cpu_to_le16(SMB2_NEGOTIATE_SIGNING_ENABLED); in SMB2_negotiate()
444 if (rsp->DialectRevision == cpu_to_le16(SMB20_PROT_ID)) in SMB2_negotiate()
446 else if (rsp->DialectRevision == cpu_to_le16(SMB21_PROT_ID)) in SMB2_negotiate()
448 else if (rsp->DialectRevision == cpu_to_le16(SMB30_PROT_ID)) in SMB2_negotiate()
450 else if (rsp->DialectRevision == cpu_to_le16(SMB302_PROT_ID)) in SMB2_negotiate()
453 else if (rsp->DialectRevision == cpu_to_le16(SMB311_PROT_ID)) in SMB2_negotiate()
531 cpu_to_le16(SMB2_NEGOTIATE_SIGNING_REQUIRED); in smb3_validate_negotiate()
534 cpu_to_le16(SMB2_NEGOTIATE_SIGNING_ENABLED); in smb3_validate_negotiate()
538 vneg_inbuf.DialectCount = cpu_to_le16(1); in smb3_validate_negotiate()
540 cpu_to_le16(tcon->ses->server->vals->protocol_id); in smb3_validate_negotiate()
559 cpu_to_le16(tcon->ses->server->vals->protocol_id)) in smb3_validate_negotiate()
562 if (pneg_rsp->SecurityMode != cpu_to_le16(tcon->ses->server->sec_mode)) in smb3_validate_negotiate()
635 req->hdr.CreditRequest = cpu_to_le16(3); in SMB2_sess_setup()
754 cpu_to_le16(sizeof(struct smb2_sess_setup_req) - in SMB2_sess_setup()
756 req->SecurityBufferLength = cpu_to_le16(blob_length); in SMB2_sess_setup()
960 req->PathOffset = cpu_to_le16(sizeof(struct smb2_tree_connect_req) in SMB2_tcon()
962 req->PathLength = cpu_to_le16(unc_path_len - 2); in SMB2_tcon()
1067 buf->ccontext.DataOffset = cpu_to_le16(offsetof in create_durable_buf()
1070 buf->ccontext.NameOffset = cpu_to_le16(offsetof in create_durable_buf()
1072 buf->ccontext.NameLength = cpu_to_le16(4); in create_durable_buf()
1090 buf->ccontext.DataOffset = cpu_to_le16(offsetof in create_reconnect_durable_buf()
1093 buf->ccontext.NameOffset = cpu_to_le16(offsetof in create_reconnect_durable_buf()
1095 buf->ccontext.NameLength = cpu_to_le16(4); in create_reconnect_durable_buf()
1167 buf->ccontext.DataOffset = cpu_to_le16(offsetof in create_durable_v2_buf()
1170 buf->ccontext.NameOffset = cpu_to_le16(offsetof in create_durable_v2_buf()
1172 buf->ccontext.NameLength = cpu_to_le16(4); in create_durable_v2_buf()
1198 cpu_to_le16(offsetof(struct create_durable_handle_reconnect_v2, in create_reconnect_durable_v2_buf()
1203 cpu_to_le16(offsetof(struct create_durable_handle_reconnect_v2, in create_reconnect_durable_v2_buf()
1205 buf->ccontext.NameLength = cpu_to_le16(4); in create_reconnect_durable_v2_buf()
1346 req->NameOffset = cpu_to_le16(sizeof(struct smb2_create_req) - 4); in SMB2_open()
1353 req->NameLength = cpu_to_le16(uni_path_len - 2); in SMB2_open()
1600 cpu_to_le16(COMPRESSION_FORMAT_DEFAULT); in SMB2_set_compression()
1744 cpu_to_le16(sizeof(struct smb2_query_info_req) - 1 - 4); in query_info()
1827 req->hdr.CreditRequest = cpu_to_le16(1); in SMB2_echo()
2039 buf->CreditCharge = cpu_to_le16(DIV_ROUND_UP(rdata->bytes, in smb2_async_readv()
2202 req->DataOffset = cpu_to_le16( in smb2_async_writev()
2225 req->hdr.CreditCharge = cpu_to_le16(DIV_ROUND_UP(wdata->bytes, in smb2_async_writev()
2285 req->DataOffset = cpu_to_le16( in SMB2_write()
2367 __le16 asteriks = cpu_to_le16('*'); in SMB2_query_directory()
2406 cpu_to_le16(sizeof(struct smb2_query_directory_req) - 1 - 4); in SMB2_query_directory()
2407 req->FileNameLength = cpu_to_le16(len); in SMB2_query_directory()
2518 cpu_to_le16(sizeof(struct smb2_set_info_req) - 1 - 4); in send_set_info()
2675 req->hdr.CreditRequest = cpu_to_le16(1); in SMB2_oplock_break()
2722 cpu_to_le16(sizeof(struct smb2_query_info_req) - 1 - 4); in build_qfs_info_req()
2850 req->LockCount = cpu_to_le16(num_lock); in smb2_lockv()
2904 req->hdr.CreditRequest = cpu_to_le16(1); in SMB2_lease_break()
2905 req->StructureSize = cpu_to_le16(36); in SMB2_lease_break()