aboutsummaryrefslogtreecommitdiffstats
path: root/crypto/crypto_engine.c
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/crypto_engine.c')
-rw-r--r--crypto/crypto_engine.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/crypto/crypto_engine.c b/crypto/crypto_engine.c
index 21f7916151145..74fcc08970411 100644
--- a/crypto/crypto_engine.c
+++ b/crypto/crypto_engine.c
@@ -129,9 +129,6 @@ start_request:
if (!engine->retry_support)
engine->cur_req = async_req;
- if (backlog)
- crypto_request_complete(backlog, -EINPROGRESS);
-
if (engine->busy)
was_busy = true;
else
@@ -217,6 +214,9 @@ req_err_2:
crypto_request_complete(async_req, ret);
retry:
+ if (backlog)
+ crypto_request_complete(backlog, -EINPROGRESS);
+
/* If retry mechanism is supported, send new requests to engine */
if (engine->retry_support) {
spin_lock_irqsave(&engine->queue_lock, flags);