aboutsummaryrefslogtreecommitdiffstats
path: root/security/keys/trusted.c
diff options
context:
space:
mode:
authorEric Biggers <ebiggers@google.com>2018-11-14 12:21:11 -0800
committerHerbert Xu <herbert@gondor.apana.org.au>2018-11-20 14:26:55 +0800
commit3d234b3313cd12157946522fe35f5a4574f31169 (patch)
tree7d7f105aaa99a8d2c21d9e1d996330dcf95c40c6 /security/keys/trusted.c
parentcrypto: drop mask=CRYPTO_ALG_ASYNC from 'cipher' tfm allocations (diff)
downloadlinux-dev-3d234b3313cd12157946522fe35f5a4574f31169.tar.xz
linux-dev-3d234b3313cd12157946522fe35f5a4574f31169.zip
crypto: drop mask=CRYPTO_ALG_ASYNC from 'shash' tfm allocations
'shash' algorithms are always synchronous, so passing CRYPTO_ALG_ASYNC in the mask to crypto_alloc_shash() has no effect. Many users therefore already don't pass it, but some still do. This inconsistency can cause confusion, especially since the way the 'mask' argument works is somewhat counterintuitive. Thus, just remove the unneeded CRYPTO_ALG_ASYNC flags. This patch shouldn't change any actual behavior. Signed-off-by: Eric Biggers <ebiggers@google.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to '')
-rw-r--r--security/keys/trusted.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/security/keys/trusted.c b/security/keys/trusted.c
index ff6789365a12..2d4f16b2a7c5 100644
--- a/security/keys/trusted.c
+++ b/security/keys/trusted.c
@@ -1199,14 +1199,14 @@ static int __init trusted_shash_alloc(void)
{
int ret;
- hmacalg = crypto_alloc_shash(hmac_alg, 0, CRYPTO_ALG_ASYNC);
+ hmacalg = crypto_alloc_shash(hmac_alg, 0, 0);
if (IS_ERR(hmacalg)) {
pr_info("trusted_key: could not allocate crypto %s\n",
hmac_alg);
return PTR_ERR(hmacalg);
}
- hashalg = crypto_alloc_shash(hash_alg, 0, CRYPTO_ALG_ASYNC);
+ hashalg = crypto_alloc_shash(hash_alg, 0, 0);
if (IS_ERR(hashalg)) {
pr_info("trusted_key: could not allocate crypto %s\n",
hash_alg);