diff options
author | Herbert Xu <herbert@gondor.apana.org.au> | 2007-05-19 03:51:40 -0400 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2007-07-11 08:58:53 -0400 |
commit | fe3c5206adc5d7395828185ab73e9a522655b984 (patch) | |
tree | afe289e4e685152f0051062a396c5d995f7d6c28 /crypto/algapi.c | |
parent | 2e290f43ddb2331db2e308da206fe154bec91a7d (diff) |
[CRYPTO] api: Wake up all waiters when larval completes
Right now when a larval matures or when it dies of an error we
only wake up one waiter. This would cause other waiters to timeout
unnecessarily. This patch changes it to use complete_all to wake
up all waiters.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'crypto/algapi.c')
-rw-r--r-- | crypto/algapi.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/crypto/algapi.c b/crypto/algapi.c index f137a432061f..38aa9e994703 100644 --- a/crypto/algapi.c +++ b/crypto/algapi.c | |||
@@ -34,7 +34,7 @@ void crypto_larval_error(const char *name, u32 type, u32 mask) | |||
34 | if (alg) { | 34 | if (alg) { |
35 | if (crypto_is_larval(alg)) { | 35 | if (crypto_is_larval(alg)) { |
36 | struct crypto_larval *larval = (void *)alg; | 36 | struct crypto_larval *larval = (void *)alg; |
37 | complete(&larval->completion); | 37 | complete_all(&larval->completion); |
38 | } | 38 | } |
39 | crypto_mod_put(alg); | 39 | crypto_mod_put(alg); |
40 | } | 40 | } |
@@ -164,7 +164,7 @@ static int __crypto_register_alg(struct crypto_alg *alg, | |||
164 | continue; | 164 | continue; |
165 | 165 | ||
166 | larval->adult = alg; | 166 | larval->adult = alg; |
167 | complete(&larval->completion); | 167 | complete_all(&larval->completion); |
168 | continue; | 168 | continue; |
169 | } | 169 | } |
170 | 170 | ||