Commit f271ea9f authored by Ryder Lee's avatar Ryder Lee Committed by Herbert Xu

crypto: mediatek - only treat EBUSY as transient if backlog

The driver was treating -EBUSY as indication of queueing to backlog
without checking that backlog is enabled for the request.

Fix it by checking request flags.
Signed-off-by: default avatarRyder Lee <ryder.lee@mediatek.com>
Signed-off-by: default avatarVic Wu <vic.wu@mediatek.com>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent e049ff5a
...@@ -778,7 +778,9 @@ static int mtk_sha_finup(struct ahash_request *req) ...@@ -778,7 +778,9 @@ static int mtk_sha_finup(struct ahash_request *req)
ctx->flags |= SHA_FLAGS_FINUP; ctx->flags |= SHA_FLAGS_FINUP;
err1 = mtk_sha_update(req); err1 = mtk_sha_update(req);
if (err1 == -EINPROGRESS || err1 == -EBUSY) if (err1 == -EINPROGRESS ||
(err1 == -EBUSY && (ahash_request_flags(req) &
CRYPTO_TFM_REQ_MAY_BACKLOG)))
return err1; return err1;
/* /*
* final() has to be always called to cleanup resources * final() has to be always called to cleanup resources
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment