Skip to content

Commit

Permalink
crypto: algif_skcipher - EBUSY on aio should be an error
Browse files Browse the repository at this point in the history
[ Upstream commit 2a05b02 ]

I removed the MAY_BACKLOG flag on the aio path a while ago but
the error check still incorrectly interpreted EBUSY as success.
This may cause the submitter to wait for a request that will never
complete.

Fixes: dad4199 ("crypto: algif_skcipher - Do not set...")
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
herbertx authored and gregkh committed Oct 29, 2020
1 parent 2934dc0 commit 77827cc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crypto/algif_skcipher.c
Expand Up @@ -123,7 +123,7 @@ static int _skcipher_recvmsg(struct socket *sock, struct msghdr *msg,
crypto_skcipher_decrypt(&areq->cra_u.skcipher_req);

/* AIO operation in progress */
if (err == -EINPROGRESS || err == -EBUSY)
if (err == -EINPROGRESS)
return -EIOCBQUEUED;

sock_put(sk);
Expand Down

0 comments on commit 77827cc

Please sign in to comment.