提交 f271ea9f 编写于 作者: R Ryder Lee 提交者: 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: NRyder Lee <ryder.lee@mediatek.com>
Signed-off-by: NVic Wu <vic.wu@mediatek.com>
Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
上级 e049ff5a
无相关合并请求
......@@ -778,7 +778,9 @@ static int mtk_sha_finup(struct ahash_request *req)
ctx->flags |= SHA_FLAGS_FINUP;
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;
/*
* final() has to be always called to cleanup resources
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册