ahash.c (498495dba268b20e8eadd7fe93c140c68b6cc9d2) ahash.c (cd6ed77ad5d223dc6299fb58f62e0f5267f7e2ba)
1/*
2 * Asynchronous Cryptographic Hash operations.
3 *
4 * This is the asynchronous version of hash.c with notification of
5 * completion via a callback.
6 *
7 * Copyright (c) 2008 Loc Ho <lho@amcc.com>
8 *

--- 635 unchanged lines hidden (view full) ---

644{
645 struct crypto_alg *alg;
646
647 alg = crypto_attr_alg2(rta, &crypto_ahash_type, type, mask);
648 return IS_ERR(alg) ? ERR_CAST(alg) : __crypto_hash_alg_common(alg);
649}
650EXPORT_SYMBOL_GPL(ahash_attr_alg);
651
1/*
2 * Asynchronous Cryptographic Hash operations.
3 *
4 * This is the asynchronous version of hash.c with notification of
5 * completion via a callback.
6 *
7 * Copyright (c) 2008 Loc Ho <lho@amcc.com>
8 *

--- 635 unchanged lines hidden (view full) ---

644{
645 struct crypto_alg *alg;
646
647 alg = crypto_attr_alg2(rta, &crypto_ahash_type, type, mask);
648 return IS_ERR(alg) ? ERR_CAST(alg) : __crypto_hash_alg_common(alg);
649}
650EXPORT_SYMBOL_GPL(ahash_attr_alg);
651
652bool crypto_hash_alg_has_setkey(struct hash_alg_common *halg)
653{
654 struct crypto_alg *alg = &halg->base;
655
656 if (alg->cra_type != &crypto_ahash_type)
657 return crypto_shash_alg_has_setkey(__crypto_shash_alg(alg));
658
659 return __crypto_ahash_alg(alg)->setkey != NULL;
660}
661EXPORT_SYMBOL_GPL(crypto_hash_alg_has_setkey);
662
652MODULE_LICENSE("GPL");
653MODULE_DESCRIPTION("Asynchronous cryptographic hash type");
663MODULE_LICENSE("GPL");
664MODULE_DESCRIPTION("Asynchronous cryptographic hash type");