Commit 93aa7f8a12d1b229bcee12a1100a6df4945f5432
1 parent
872ac8743c
Exists in
master
and in
20 other branches
[CRYPTO] cryptd: Fix EINPROGRESS notification context
The EINPROGRESS notifications should be done just like the final call-backs, i.e., with BH off. This patch fixes the call in cryptd since previously it was called with BH on. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Showing 1 changed file with 4 additions and 5 deletions Side-by-side Diff
crypto/cryptd.c
... | ... | @@ -82,10 +82,8 @@ |
82 | 82 | |
83 | 83 | rctx = ablkcipher_request_ctx(req); |
84 | 84 | |
85 | - if (unlikely(err == -EINPROGRESS)) { | |
86 | - rctx->complete(&req->base, err); | |
87 | - return; | |
88 | - } | |
85 | + if (unlikely(err == -EINPROGRESS)) | |
86 | + goto out; | |
89 | 87 | |
90 | 88 | desc.tfm = child; |
91 | 89 | desc.info = req->info; |
92 | 90 | |
... | ... | @@ -95,8 +93,9 @@ |
95 | 93 | |
96 | 94 | req->base.complete = rctx->complete; |
97 | 95 | |
96 | +out: | |
98 | 97 | local_bh_disable(); |
99 | - req->base.complete(&req->base, err); | |
98 | + rctx->complete(&req->base, err); | |
100 | 99 | local_bh_enable(); |
101 | 100 | } |
102 | 101 |