/drivers/crypto/axis/ |
D | artpec6_crypto.c | 1089 struct artpec6_crypto_request_context *req_ctx = NULL; in artpec6_crypto_encrypt() local 1093 req_ctx = skcipher_request_ctx(req); in artpec6_crypto_encrypt() 1099 req_ctx->decrypt = 0; in artpec6_crypto_encrypt() 1114 ret = artpec6_crypto_common_init(&req_ctx->common, in artpec6_crypto_encrypt() 1123 artpec6_crypto_common_destroy(&req_ctx->common); in artpec6_crypto_encrypt() 1127 return artpec6_crypto_submit(&req_ctx->common); in artpec6_crypto_encrypt() 1135 struct artpec6_crypto_request_context *req_ctx = NULL; in artpec6_crypto_decrypt() local 1138 req_ctx = skcipher_request_ctx(req); in artpec6_crypto_decrypt() 1144 req_ctx->decrypt = 1; in artpec6_crypto_decrypt() 1160 ret = artpec6_crypto_common_init(&req_ctx->common, &req->base, in artpec6_crypto_decrypt() [all …]
|
/drivers/crypto/ |
D | talitos.c | 1703 struct talitos_ahash_req_ctx *req_ctx = ahash_request_ctx(areq); in common_nonsnoop_hash_unmap() local 1715 if (req_ctx->last) in common_nonsnoop_hash_unmap() 1716 memcpy(areq->result, req_ctx->hw_context, in common_nonsnoop_hash_unmap() 1719 if (req_ctx->psrc) in common_nonsnoop_hash_unmap() 1720 talitos_sg_unmap(dev, edesc, req_ctx->psrc, NULL, 0, 0); in common_nonsnoop_hash_unmap() 1730 if (is_sec1 && req_ctx->nbuf) in common_nonsnoop_hash_unmap() 1750 struct talitos_ahash_req_ctx *req_ctx = ahash_request_ctx(areq); in ahash_done() local 1752 if (!req_ctx->last && req_ctx->to_hash_later) { in ahash_done() 1754 req_ctx->buf_idx = (req_ctx->buf_idx + 1) & 1; in ahash_done() 1755 req_ctx->nbuf = req_ctx->to_hash_later; in ahash_done() [all …]
|
D | ixp4xx_crypto.c | 347 struct aead_ctx *req_ctx = aead_request_ctx(req); in finish_scattered_hmac() local 352 if (req_ctx->encrypt) { in finish_scattered_hmac() 353 scatterwalk_map_and_copy(req_ctx->hmac_virt, in finish_scattered_hmac() 356 dma_pool_free(buffer_pool, req_ctx->hmac_virt, crypt->icv_rev_aes); in finish_scattered_hmac() 373 struct aead_ctx *req_ctx = aead_request_ctx(req); in one_packet() local 375 free_buf_chain(dev, req_ctx->src, crypt->src_buf); in one_packet() 376 free_buf_chain(dev, req_ctx->dst, crypt->dst_buf); in one_packet() 377 if (req_ctx->hmac_virt) { in one_packet() 385 struct ablk_ctx *req_ctx = skcipher_request_ctx(req); in one_packet() local 392 if (req_ctx->encrypt) { in one_packet() [all …]
|
D | mxs-dcp.c | 117 struct dcp_sha_req_ctx req_ctx; member 822 memcpy(rctx, &export->req_ctx, sizeof(struct dcp_sha_req_ctx)); in dcp_sha_import() 835 memcpy(&export->req_ctx, rctx_state, sizeof(struct dcp_sha_req_ctx)); in dcp_sha_export()
|
/drivers/crypto/ccree/ |
D | cc_cipher.c | 508 struct cipher_req_ctx *req_ctx, in cc_setup_readiv_desc() argument 516 int direction = req_ctx->gen_ctx.op_type; in cc_setup_readiv_desc() 517 dma_addr_t iv_dma_addr = req_ctx->gen_ctx.iv_dma_addr; in cc_setup_readiv_desc() 564 struct cipher_req_ctx *req_ctx, in cc_setup_state_desc() argument 573 int direction = req_ctx->gen_ctx.op_type; in cc_setup_state_desc() 574 dma_addr_t iv_dma_addr = req_ctx->gen_ctx.iv_dma_addr; in cc_setup_state_desc() 608 struct cipher_req_ctx *req_ctx, in cc_setup_xex_state_desc() argument 617 int direction = req_ctx->gen_ctx.op_type; in cc_setup_xex_state_desc() 620 dma_addr_t iv_dma_addr = req_ctx->gen_ctx.iv_dma_addr; in cc_setup_xex_state_desc() 686 struct cipher_req_ctx *req_ctx, in cc_setup_key_desc() argument [all …]
|
D | cc_aead.c | 876 struct aead_req_ctx *req_ctx = aead_request_ctx(req); in cc_proc_digest_desc() local 880 int direct = req_ctx->gen_ctx.op_type; in cc_proc_digest_desc() 887 set_dout_dlli(&desc[idx], req_ctx->icv_dma_addr, ctx->authsize, in cc_proc_digest_desc() 903 set_dout_dlli(&desc[idx], req_ctx->mac_buf_dma_addr, in cc_proc_digest_desc() 926 struct aead_req_ctx *req_ctx = aead_request_ctx(req); in cc_set_cipher_desc() local 927 unsigned int hw_iv_size = req_ctx->hw_iv_size; in cc_set_cipher_desc() 929 int direct = req_ctx->gen_ctx.op_type; in cc_set_cipher_desc() 935 set_din_type(&desc[idx], DMA_DLLI, req_ctx->gen_ctx.iv_dma_addr, in cc_set_cipher_desc() 968 struct aead_req_ctx *req_ctx = aead_request_ctx(req); in cc_proc_cipher() local 969 int direct = req_ctx->gen_ctx.op_type; in cc_proc_cipher() [all …]
|
D | cc_buffer_mgr.c | 343 struct cipher_req_ctx *req_ctx = (struct cipher_req_ctx *)ctx; in cc_unmap_cipher_request() local 345 if (req_ctx->gen_ctx.iv_dma_addr) { in cc_unmap_cipher_request() 347 &req_ctx->gen_ctx.iv_dma_addr, ivsize); in cc_unmap_cipher_request() 348 dma_unmap_single(dev, req_ctx->gen_ctx.iv_dma_addr, in cc_unmap_cipher_request() 352 if (req_ctx->dma_buf_type == CC_DMA_BUF_MLLI && in cc_unmap_cipher_request() 353 req_ctx->mlli_params.mlli_virt_addr) { in cc_unmap_cipher_request() 354 dma_pool_free(req_ctx->mlli_params.curr_pool, in cc_unmap_cipher_request() 355 req_ctx->mlli_params.mlli_virt_addr, in cc_unmap_cipher_request() 356 req_ctx->mlli_params.mlli_dma_addr); in cc_unmap_cipher_request() 360 dma_unmap_sg(dev, src, req_ctx->in_nents, DMA_TO_DEVICE); in cc_unmap_cipher_request() [all …]
|
/drivers/crypto/caam/ |
D | caampkc.c | 46 struct caam_rsa_req_ctx *req_ctx = akcipher_request_ctx(req); in rsa_io_unmap() local 49 dma_unmap_sg(dev, req_ctx->fixup_src, edesc->src_nents, DMA_TO_DEVICE); in rsa_io_unmap() 120 struct caam_rsa_req_ctx *req_ctx = akcipher_request_ctx(req); in rsa_pub_done() local 129 edesc = req_ctx->edesc; in rsa_pub_done() 154 struct caam_rsa_req_ctx *req_ctx = akcipher_request_ctx(req); in rsa_priv_f_done() local 162 edesc = req_ctx->edesc; in rsa_priv_f_done() 248 struct caam_rsa_req_ctx *req_ctx = akcipher_request_ctx(req); in rsa_edesc_alloc() local 270 req_ctx->fixup_src = scatterwalk_ffwd(req_ctx->src, req->src, in rsa_edesc_alloc() 272 req_ctx->fixup_src_len = req->src_len - lzeros; in rsa_edesc_alloc() 279 req_ctx->fixup_src = req->src; in rsa_edesc_alloc() [all …]
|
D | caamalg_qi2.c | 350 struct caam_request *req_ctx = aead_request_ctx(req); in aead_edesc_alloc() local 351 struct dpaa2_fl_entry *in_fle = &req_ctx->fd_flt[1]; in aead_edesc_alloc() 352 struct dpaa2_fl_entry *out_fle = &req_ctx->fd_flt[0]; in aead_edesc_alloc() 547 memset(&req_ctx->fd_flt, 0, sizeof(req_ctx->fd_flt)); in aead_edesc_alloc() 1110 struct caam_request *req_ctx = skcipher_request_ctx(req); in skcipher_edesc_alloc() local 1111 struct dpaa2_fl_entry *in_fle = &req_ctx->fd_flt[1]; in skcipher_edesc_alloc() 1112 struct dpaa2_fl_entry *out_fle = &req_ctx->fd_flt[0]; in skcipher_edesc_alloc() 1236 memset(&req_ctx->fd_flt, 0, sizeof(req_ctx->fd_flt)); in skcipher_edesc_alloc() 1284 struct caam_request *req_ctx = to_caam_req(areq); in aead_encrypt_done() local 1285 struct aead_edesc *edesc = req_ctx->edesc; in aead_encrypt_done() [all …]
|
/drivers/crypto/chelsio/ |
D | chcr_algo.c | 1569 struct chcr_ahash_req_ctx *req_ctx = ahash_request_ctx(req); in create_hash_wr() local 1583 unsigned int rx_channel_id = req_ctx->rxqidx / ctx->rxq_perchan; in create_hash_wr() 1587 req_ctx->hctx_wr.imm = (transhdr_len + param->bfr_len + in create_hash_wr() 1589 nents = sg_nents_xlen(req_ctx->hctx_wr.srcsg, param->sg_len, in create_hash_wr() 1590 CHCR_SRC_SG_SIZE, req_ctx->hctx_wr.src_ofst); in create_hash_wr() 1592 transhdr_len += req_ctx->hctx_wr.imm ? roundup(param->bfr_len + in create_hash_wr() 1617 memcpy(chcr_req->key_ctx.key, req_ctx->partial_hash, in create_hash_wr() 1635 req_ctx->hctx_wr.dma_addr = in create_hash_wr() 1636 dma_map_single(&u_ctx->lldi.pdev->dev, req_ctx->reqbfr, in create_hash_wr() 1639 req_ctx->hctx_wr. dma_addr)) { in create_hash_wr() [all …]
|
/drivers/crypto/ux500/hash/ |
D | hash_core.c | 553 struct hash_req_ctx *req_ctx = ahash_request_ctx(req); in ux500_hash_init() local 558 memset(&req_ctx->state, 0, sizeof(struct hash_state)); in ux500_hash_init() 559 req_ctx->updated = 0; in ux500_hash_init() 562 req_ctx->dma_mode = false; /* Don't use DMA */ in ux500_hash_init() 569 req_ctx->dma_mode = true; in ux500_hash_init() 571 req_ctx->dma_mode = false; in ux500_hash_init() 764 struct hash_ctx *ctx, struct hash_req_ctx *req_ctx, in hash_process_data() argument 780 if (req_ctx->updated) { in hash_process_data() 783 memmove(req_ctx->state.buffer, in hash_process_data() 800 req_ctx->updated = 1; in hash_process_data() [all …]
|