WIP: update tizen_qemu_defconfig
[platform/kernel/linux-starfive.git] / crypto / xts.c
index 63c85b9..de6cbcf 100644 (file)
@@ -203,12 +203,12 @@ static void xts_encrypt_done(struct crypto_async_request *areq, int err)
        if (!err) {
                struct xts_request_ctx *rctx = skcipher_request_ctx(req);
 
-               rctx->subreq.base.flags &= ~CRYPTO_TFM_REQ_MAY_SLEEP;
+               rctx->subreq.base.flags &= CRYPTO_TFM_REQ_MAY_BACKLOG;
                err = xts_xor_tweak_post(req, true);
 
                if (!err && unlikely(req->cryptlen % XTS_BLOCK_SIZE)) {
                        err = xts_cts_final(req, crypto_skcipher_encrypt);
-                       if (err == -EINPROGRESS)
+                       if (err == -EINPROGRESS || err == -EBUSY)
                                return;
                }
        }
@@ -223,12 +223,12 @@ static void xts_decrypt_done(struct crypto_async_request *areq, int err)
        if (!err) {
                struct xts_request_ctx *rctx = skcipher_request_ctx(req);
 
-               rctx->subreq.base.flags &= ~CRYPTO_TFM_REQ_MAY_SLEEP;
+               rctx->subreq.base.flags &= CRYPTO_TFM_REQ_MAY_BACKLOG;
                err = xts_xor_tweak_post(req, false);
 
                if (!err && unlikely(req->cryptlen % XTS_BLOCK_SIZE)) {
                        err = xts_cts_final(req, crypto_skcipher_decrypt);
-                       if (err == -EINPROGRESS)
+                       if (err == -EINPROGRESS || err == -EBUSY)
                                return;
                }
        }