Lines Matching refs:mask
61 u32 mask) in __crypto_alg_lookup() argument
72 if ((q->cra_flags ^ type) & mask) in __crypto_alg_lookup()
77 ((struct crypto_larval *)q)->mask != mask) in __crypto_alg_lookup()
110 struct crypto_larval *crypto_larval_alloc(const char *name, u32 type, u32 mask) in crypto_larval_alloc() argument
118 larval->mask = mask; in crypto_larval_alloc()
131 u32 mask) in crypto_larval_add() argument
136 larval = crypto_larval_alloc(name, type, mask); in crypto_larval_add()
143 alg = __crypto_alg_lookup(name, type, mask); in crypto_larval_add()
197 u32 mask) in crypto_alg_lookup() argument
202 if (!((type | mask) & CRYPTO_ALG_TESTED)) in crypto_alg_lookup()
206 alg = __crypto_alg_lookup(name, type | test, mask | test); in crypto_alg_lookup()
208 alg = __crypto_alg_lookup(name, type, mask); in crypto_alg_lookup()
221 u32 mask) in crypto_larval_lookup() argument
229 mask &= ~(CRYPTO_ALG_LARVAL | CRYPTO_ALG_DEAD); in crypto_larval_lookup()
231 alg = crypto_alg_lookup(name, type, mask); in crypto_larval_lookup()
232 if (!alg && !(mask & CRYPTO_NOLOAD)) { in crypto_larval_lookup()
235 if (!((type ^ CRYPTO_ALG_NEED_FALLBACK) & mask & in crypto_larval_lookup()
239 alg = crypto_alg_lookup(name, type, mask); in crypto_larval_lookup()
245 alg = crypto_larval_add(name, type, mask); in crypto_larval_lookup()
264 struct crypto_alg *crypto_alg_mod_lookup(const char *name, u32 type, u32 mask) in crypto_alg_mod_lookup() argument
277 if (!((type | mask) & CRYPTO_ALG_INTERNAL)) in crypto_alg_mod_lookup()
278 mask |= CRYPTO_ALG_INTERNAL; in crypto_alg_mod_lookup()
280 larval = crypto_larval_lookup(name, type, mask); in crypto_alg_mod_lookup()
297 static int crypto_init_ops(struct crypto_tfm *tfm, u32 type, u32 mask) in crypto_init_ops() argument
302 return type_obj->init(tfm, type, mask); in crypto_init_ops()
327 static unsigned int crypto_ctxsize(struct crypto_alg *alg, u32 type, u32 mask) in crypto_ctxsize() argument
334 return len + type_obj->ctxsize(alg, type, mask); in crypto_ctxsize()
360 u32 mask) in __crypto_alloc_tfm() argument
366 tfm_size = sizeof(*tfm) + crypto_ctxsize(alg, type, mask); in __crypto_alloc_tfm()
373 err = crypto_init_ops(tfm, type, mask); in __crypto_alloc_tfm()
417 struct crypto_tfm *crypto_alloc_base(const char *alg_name, u32 type, u32 mask) in crypto_alloc_base() argument
425 alg = crypto_alg_mod_lookup(alg_name, type, mask); in crypto_alloc_base()
431 tfm = __crypto_alloc_tfm(alg, type, mask); in crypto_alloc_base()
494 u32 type, u32 mask) in crypto_find_alg() argument
498 mask &= frontend->maskclear; in crypto_find_alg()
500 mask |= frontend->maskset; in crypto_find_alg()
503 return crypto_alg_mod_lookup(alg_name, type, mask); in crypto_find_alg()
528 const struct crypto_type *frontend, u32 type, u32 mask) in crypto_alloc_tfm() argument
536 alg = crypto_find_alg(alg_name, frontend, type, mask); in crypto_alloc_tfm()
587 int crypto_has_alg(const char *name, u32 type, u32 mask) in crypto_has_alg() argument
590 struct crypto_alg *alg = crypto_alg_mod_lookup(name, type, mask); in crypto_has_alg()