Lines Matching refs:enc
30 struct crypto_skcipher_spawn enc; member
36 struct crypto_ablkcipher *enc; member
90 struct crypto_ablkcipher *enc = ctx->enc; in crypto_authenc_setkey() local
107 crypto_ablkcipher_clear_flags(enc, CRYPTO_TFM_REQ_MASK); in crypto_authenc_setkey()
108 crypto_ablkcipher_set_flags(enc, crypto_aead_get_flags(authenc) & in crypto_authenc_setkey()
110 err = crypto_ablkcipher_setkey(enc, keys.enckey, keys.enckeylen); in crypto_authenc_setkey()
111 crypto_aead_set_flags(authenc, crypto_ablkcipher_get_flags(enc) & in crypto_authenc_setkey()
208 ablkcipher_request_set_tfm(abreq, ctx->enc); in authenc_verify_ahash_update_done()
247 ablkcipher_request_set_tfm(abreq, ctx->enc); in authenc_verify_ahash_done()
386 u8 *iv = (u8 *)abreq - crypto_ablkcipher_ivsize(ctx->enc); in crypto_authenc_encrypt_done()
399 struct crypto_ablkcipher *enc = ctx->enc; in crypto_authenc_encrypt() local
404 u8 *iv = (u8 *)abreq - crypto_ablkcipher_ivsize(enc); in crypto_authenc_encrypt()
407 ablkcipher_request_set_tfm(abreq, enc); in crypto_authenc_encrypt()
444 skcipher_givcrypt_set_tfm(greq, ctx->enc); in crypto_authenc_givencrypt()
539 ablkcipher_request_set_tfm(abreq, ctx->enc); in crypto_authenc_decrypt()
553 struct crypto_ablkcipher *enc; in crypto_authenc_init_tfm() local
560 enc = crypto_spawn_skcipher(&ictx->enc); in crypto_authenc_init_tfm()
561 err = PTR_ERR(enc); in crypto_authenc_init_tfm()
562 if (IS_ERR(enc)) in crypto_authenc_init_tfm()
566 ctx->enc = enc; in crypto_authenc_init_tfm()
571 crypto_ablkcipher_ivsize(enc); in crypto_authenc_init_tfm()
579 crypto_ablkcipher_reqsize(enc)); in crypto_authenc_init_tfm()
593 crypto_free_ablkcipher(ctx->enc); in crypto_authenc_exit_tfm()
602 struct crypto_alg *enc; in crypto_authenc_alloc() local
637 crypto_set_skcipher_spawn(&ctx->enc, inst); in crypto_authenc_alloc()
638 err = crypto_grab_skcipher(&ctx->enc, enc_name, 0, in crypto_authenc_alloc()
644 enc = crypto_skcipher_spawn_alg(&ctx->enc); in crypto_authenc_alloc()
648 "authenc(%s,%s)", auth_base->cra_name, enc->cra_name) >= in crypto_authenc_alloc()
654 enc->cra_driver_name) >= CRYPTO_MAX_ALG_NAME) in crypto_authenc_alloc()
658 inst->alg.cra_flags |= enc->cra_flags & CRYPTO_ALG_ASYNC; in crypto_authenc_alloc()
659 inst->alg.cra_priority = enc->cra_priority * in crypto_authenc_alloc()
661 inst->alg.cra_blocksize = enc->cra_blocksize; in crypto_authenc_alloc()
662 inst->alg.cra_alignmask = auth_base->cra_alignmask | enc->cra_alignmask; in crypto_authenc_alloc()
665 inst->alg.cra_aead.ivsize = enc->cra_ablkcipher.ivsize; in crypto_authenc_alloc()
683 crypto_drop_skcipher(&ctx->enc); in crypto_authenc_alloc()
697 crypto_drop_skcipher(&ctx->enc); in crypto_authenc_free()