Lines Matching refs:cdata

88 	struct alginfo cdata;  member
186 const bool ctr_mode = ((ctx->cdata.algtype & OP_ALG_AAI_MASK) == in aead_set_sh_desc()
190 if (!ctx->cdata.keylen || !ctx->authsize) in aead_set_sh_desc()
208 ctx->cdata.keylen - CTR_RFC3686_NONCE_SIZE); in aead_set_sh_desc()
220 ctx->cdata.key_virt = ctx->key + ctx->adata.keylen_pad; in aead_set_sh_desc()
221 ctx->cdata.key_dma = ctx->key_dma + ctx->adata.keylen_pad; in aead_set_sh_desc()
224 data_len[1] = ctx->cdata.keylen; in aead_set_sh_desc()
235 ctx->cdata.key_inline = !!(inl_mask & 2); in aead_set_sh_desc()
241 cnstr_shdsc_aead_givencap(desc, &ctx->cdata, &ctx->adata, in aead_set_sh_desc()
246 cnstr_shdsc_aead_encap(desc, &ctx->cdata, &ctx->adata, in aead_set_sh_desc()
263 ctx->cdata.key_inline = !!(inl_mask & 2); in aead_set_sh_desc()
267 cnstr_shdsc_aead_decap(desc, &ctx->cdata, &ctx->adata, in aead_set_sh_desc()
320 ctx->cdata.keylen = keys.enckeylen; in aead_setkey()
598 if (!ctx->cdata.keylen || !ctx->authsize) in chachapoly_set_sh_desc()
603 cnstr_shdsc_chachapoly(desc, &ctx->cdata, &ctx->adata, ivsize, in chachapoly_set_sh_desc()
612 cnstr_shdsc_chachapoly(desc, &ctx->cdata, &ctx->adata, ivsize, in chachapoly_set_sh_desc()
645 ctx->cdata.key_virt = ctx->key; in chachapoly_setkey()
646 ctx->cdata.keylen = keylen - saltlen; in chachapoly_setkey()
659 ctx->cdata.keylen; in gcm_set_sh_desc()
661 if (!ctx->cdata.keylen || !ctx->authsize) in gcm_set_sh_desc()
670 ctx->cdata.key_inline = true; in gcm_set_sh_desc()
671 ctx->cdata.key_virt = ctx->key; in gcm_set_sh_desc()
673 ctx->cdata.key_inline = false; in gcm_set_sh_desc()
674 ctx->cdata.key_dma = ctx->key_dma; in gcm_set_sh_desc()
679 cnstr_shdsc_gcm_encap(desc, &ctx->cdata, ivsize, ctx->authsize, true); in gcm_set_sh_desc()
690 ctx->cdata.key_inline = true; in gcm_set_sh_desc()
691 ctx->cdata.key_virt = ctx->key; in gcm_set_sh_desc()
693 ctx->cdata.key_inline = false; in gcm_set_sh_desc()
694 ctx->cdata.key_dma = ctx->key_dma; in gcm_set_sh_desc()
699 cnstr_shdsc_gcm_decap(desc, &ctx->cdata, ivsize, ctx->authsize, true); in gcm_set_sh_desc()
738 ctx->cdata.keylen = keylen; in gcm_setkey()
751 ctx->cdata.keylen; in rfc4106_set_sh_desc()
753 if (!ctx->cdata.keylen || !ctx->authsize) in rfc4106_set_sh_desc()
756 ctx->cdata.key_virt = ctx->key; in rfc4106_set_sh_desc()
764 ctx->cdata.key_inline = true; in rfc4106_set_sh_desc()
766 ctx->cdata.key_inline = false; in rfc4106_set_sh_desc()
767 ctx->cdata.key_dma = ctx->key_dma; in rfc4106_set_sh_desc()
772 cnstr_shdsc_rfc4106_encap(desc, &ctx->cdata, ivsize, ctx->authsize, in rfc4106_set_sh_desc()
784 ctx->cdata.key_inline = true; in rfc4106_set_sh_desc()
786 ctx->cdata.key_inline = false; in rfc4106_set_sh_desc()
787 ctx->cdata.key_dma = ctx->key_dma; in rfc4106_set_sh_desc()
792 cnstr_shdsc_rfc4106_decap(desc, &ctx->cdata, ivsize, ctx->authsize, in rfc4106_set_sh_desc()
837 ctx->cdata.keylen = keylen - 4; in rfc4106_setkey()
838 dma_sync_single_for_device(dev, ctx->key_dma, ctx->cdata.keylen, in rfc4106_setkey()
852 ctx->cdata.keylen; in rfc4543_set_sh_desc()
854 if (!ctx->cdata.keylen || !ctx->authsize) in rfc4543_set_sh_desc()
857 ctx->cdata.key_virt = ctx->key; in rfc4543_set_sh_desc()
865 ctx->cdata.key_inline = true; in rfc4543_set_sh_desc()
867 ctx->cdata.key_inline = false; in rfc4543_set_sh_desc()
868 ctx->cdata.key_dma = ctx->key_dma; in rfc4543_set_sh_desc()
873 cnstr_shdsc_rfc4543_encap(desc, &ctx->cdata, ivsize, ctx->authsize, in rfc4543_set_sh_desc()
885 ctx->cdata.key_inline = true; in rfc4543_set_sh_desc()
887 ctx->cdata.key_inline = false; in rfc4543_set_sh_desc()
888 ctx->cdata.key_dma = ctx->key_dma; in rfc4543_set_sh_desc()
893 cnstr_shdsc_rfc4543_decap(desc, &ctx->cdata, ivsize, ctx->authsize, in rfc4543_set_sh_desc()
936 ctx->cdata.keylen = keylen - 4; in rfc4543_setkey()
937 dma_sync_single_for_device(dev, ctx->key_dma, ctx->cdata.keylen, in rfc4543_setkey()
959 ctx->cdata.keylen = keylen; in skcipher_setkey()
960 ctx->cdata.key_virt = key; in skcipher_setkey()
961 ctx->cdata.key_inline = true; in skcipher_setkey()
966 cnstr_shdsc_skcipher_encap(desc, &ctx->cdata, ivsize, is_rfc3686, in skcipher_setkey()
976 cnstr_shdsc_skcipher_decap(desc, &ctx->cdata, ivsize, is_rfc3686, in skcipher_setkey()
1087 ctx->cdata.keylen = keylen; in xts_skcipher_setkey()
1088 ctx->cdata.key_virt = key; in xts_skcipher_setkey()
1089 ctx->cdata.key_inline = true; in xts_skcipher_setkey()
1094 cnstr_shdsc_xts_skcipher_encap(desc, &ctx->cdata); in xts_skcipher_setkey()
1103 cnstr_shdsc_xts_skcipher_decap(desc, &ctx->cdata); in xts_skcipher_setkey()
1583 ctx->cdata.algtype = OP_TYPE_CLASS1_ALG | caam->class1_alg_type; in caam_cra_init()