Skip to content

Commit 6a40fb0

Browse files
ye xingchenherbertx
authored andcommitted
crypto: ccp - Remove the unneeded result variable
Return the value ccp_crypto_enqueue_request() directly instead of storing it in another redundant variable. Reported-by: Zeal Robot <[email protected]> Signed-off-by: ye xingchen <[email protected]> Acked-by: John Allen <[email protected]> Signed-off-by: Herbert Xu <[email protected]>
1 parent 70513e1 commit 6a40fb0

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

drivers/crypto/ccp/ccp-crypto-des3.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ static int ccp_des3_crypt(struct skcipher_request *req, bool encrypt)
6464
struct ccp_des3_req_ctx *rctx = skcipher_request_ctx(req);
6565
struct scatterlist *iv_sg = NULL;
6666
unsigned int iv_len = 0;
67-
int ret;
6867

6968
if (!ctx->u.des3.key_len)
7069
return -EINVAL;
@@ -100,9 +99,7 @@ static int ccp_des3_crypt(struct skcipher_request *req, bool encrypt)
10099
rctx->cmd.u.des3.src_len = req->cryptlen;
101100
rctx->cmd.u.des3.dst = req->dst;
102101

103-
ret = ccp_crypto_enqueue_request(&req->base, &rctx->cmd);
104-
105-
return ret;
102+
return ccp_crypto_enqueue_request(&req->base, &rctx->cmd);
106103
}
107104

108105
static int ccp_des3_encrypt(struct skcipher_request *req)

0 commit comments

Comments
 (0)