Lines Matching refs:alg
111 struct aead_alg *alg = crypto_aead_alg(aead); in crypto_aead_exit_tfm() local
113 alg->exit(aead); in crypto_aead_exit_tfm()
119 struct aead_alg *alg = crypto_aead_alg(aead); in crypto_aead_init_tfm() local
123 aead->authsize = alg->maxauthsize; in crypto_aead_init_tfm()
125 if (alg->exit) in crypto_aead_init_tfm()
128 if (alg->init) in crypto_aead_init_tfm()
129 return alg->init(aead); in crypto_aead_init_tfm()
135 struct sk_buff *skb, struct crypto_alg *alg) in crypto_aead_report() argument
138 struct aead_alg *aead = container_of(alg, struct aead_alg, base); in crypto_aead_report()
145 raead.blocksize = alg->cra_blocksize; in crypto_aead_report()
152 static void crypto_aead_show(struct seq_file *m, struct crypto_alg *alg)
154 static void crypto_aead_show(struct seq_file *m, struct crypto_alg *alg) in crypto_aead_show() argument
156 struct aead_alg *aead = container_of(alg, struct aead_alg, base); in crypto_aead_show()
159 seq_printf(m, "async : %s\n", alg->cra_flags & CRYPTO_ALG_ASYNC ? in crypto_aead_show()
161 seq_printf(m, "blocksize : %u\n", alg->cra_blocksize); in crypto_aead_show()
211 static int aead_prepare_alg(struct aead_alg *alg) in aead_prepare_alg() argument
213 struct crypto_alg *base = &alg->base; in aead_prepare_alg()
215 if (max3(alg->maxauthsize, alg->ivsize, alg->chunksize) > in aead_prepare_alg()
219 if (!alg->chunksize) in aead_prepare_alg()
220 alg->chunksize = base->cra_blocksize; in aead_prepare_alg()
229 int crypto_register_aead(struct aead_alg *alg) in crypto_register_aead() argument
231 struct crypto_alg *base = &alg->base; in crypto_register_aead()
234 err = aead_prepare_alg(alg); in crypto_register_aead()
242 void crypto_unregister_aead(struct aead_alg *alg) in crypto_unregister_aead() argument
244 crypto_unregister_alg(&alg->base); in crypto_unregister_aead()
285 err = aead_prepare_alg(&inst->alg); in aead_register_instance()