mirror of
https://github.com/torvalds/linux.git
synced 2026-05-28 09:04:39 +02:00
crypto: acomp - Add missing return statements in compress/decompress
The return statements were missing which causes REQ_CHAIN algorithms
to execute twice for every request.
Reported-by: Eric Biggers <ebiggers@kernel.org>
Fixes: 64929fe8c0 ("crypto: acomp - Remove request chaining")
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
This commit is contained in:
parent
da4cb617bc
commit
31b20bc22f
|
|
@ -292,7 +292,7 @@ int crypto_acomp_compress(struct acomp_req *req)
|
|||
if (acomp_req_on_stack(req) && acomp_is_async(tfm))
|
||||
return -EAGAIN;
|
||||
if (crypto_acomp_req_chain(tfm) || acomp_request_issg(req))
|
||||
crypto_acomp_reqtfm(req)->compress(req);
|
||||
return crypto_acomp_reqtfm(req)->compress(req);
|
||||
return acomp_do_req_chain(req, true);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(crypto_acomp_compress);
|
||||
|
|
@ -304,7 +304,7 @@ int crypto_acomp_decompress(struct acomp_req *req)
|
|||
if (acomp_req_on_stack(req) && acomp_is_async(tfm))
|
||||
return -EAGAIN;
|
||||
if (crypto_acomp_req_chain(tfm) || acomp_request_issg(req))
|
||||
crypto_acomp_reqtfm(req)->decompress(req);
|
||||
return crypto_acomp_reqtfm(req)->decompress(req);
|
||||
return acomp_do_req_chain(req, false);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(crypto_acomp_decompress);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user