Lines Matching refs:ahash
49 static void *ah_alloc_tmp(struct crypto_ahash *ahash, int nfrags, in ah_alloc_tmp() argument
54 len = size + crypto_ahash_digestsize(ahash) + in ah_alloc_tmp()
55 (crypto_ahash_alignmask(ahash) & in ah_alloc_tmp()
60 len += sizeof(struct ahash_request) + crypto_ahash_reqsize(ahash); in ah_alloc_tmp()
78 static inline u8 *ah_tmp_icv(struct crypto_ahash *ahash, void *tmp, in ah_tmp_icv() argument
81 return PTR_ALIGN((u8 *)tmp + offset, crypto_ahash_alignmask(ahash) + 1); in ah_tmp_icv()
84 static inline struct ahash_request *ah_tmp_req(struct crypto_ahash *ahash, in ah_tmp_req() argument
89 req = (void *)PTR_ALIGN(icv + crypto_ahash_digestsize(ahash), in ah_tmp_req()
92 ahash_request_set_tfm(req, ahash); in ah_tmp_req()
97 static inline struct scatterlist *ah_req_sg(struct crypto_ahash *ahash, in ah_req_sg() argument
101 crypto_ahash_reqsize(ahash), in ah_req_sg()
305 icv = ah_tmp_icv(ahp->ahash, iph_ext, extlen); in ah6_output_done()
331 struct crypto_ahash *ahash; in ah6_output() local
344 ahash = ahp->ahash; in ah6_output()
361 iph_base = ah_alloc_tmp(ahash, nfrags + sglists, IPV6HDR_BASELEN + in ah6_output()
368 icv = ah_tmp_icv(ahash, seqhi, seqhi_len); in ah6_output()
369 req = ah_tmp_req(ahash, icv); in ah6_output()
370 sg = ah_req_sg(ahash, req); in ah6_output()
474 icv = ah_tmp_icv(ahp->ahash, auth_data, ahp->icv_trunc_len); in ah6_input_done()
517 struct crypto_ahash *ahash; in ah6_input() local
546 ahash = ahp->ahash; in ah6_input()
573 work_iph = ah_alloc_tmp(ahash, nfrags + sglists, hdr_len + in ah6_input()
582 icv = ah_tmp_icv(ahash, seqhi, seqhi_len); in ah6_input()
583 req = ah_tmp_req(ahash, icv); in ah6_input()
584 sg = ah_req_sg(ahash, req); in ah6_input()
676 struct crypto_ahash *ahash; in ah6_init_state() local
688 ahash = crypto_alloc_ahash(x->aalg->alg_name, 0, 0); in ah6_init_state()
689 if (IS_ERR(ahash)) in ah6_init_state()
692 ahp->ahash = ahash; in ah6_init_state()
693 if (crypto_ahash_setkey(ahash, x->aalg->alg_key, in ah6_init_state()
707 crypto_ahash_digestsize(ahash)) { in ah6_init_state()
709 x->aalg->alg_name, crypto_ahash_digestsize(ahash), in ah6_init_state()
735 crypto_free_ahash(ahp->ahash); in ah6_init_state()
748 crypto_free_ahash(ahp->ahash); in ah6_destroy()