Commit f8f54e19 authored by Phil Sutter's avatar Phil Sutter Committed by Herbert Xu

crypto: mv_cesa - fix final callback not ignoring input data

Broken by commit 6ef84509 for users
passing a request with non-zero 'nbytes' field, like e.g. testmgr.

Cc: <stable@kernel.org> # 3.0+
Signed-off-by: default avatarPhil Sutter <phil.sutter@viprinet.com>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent f2ea0f5f
...@@ -712,6 +712,7 @@ static int mv_hash_final(struct ahash_request *req) ...@@ -712,6 +712,7 @@ static int mv_hash_final(struct ahash_request *req)
{ {
struct mv_req_hash_ctx *ctx = ahash_request_ctx(req); struct mv_req_hash_ctx *ctx = ahash_request_ctx(req);
ahash_request_set_crypt(req, NULL, req->result, 0);
mv_update_hash_req_ctx(ctx, 1, 0); mv_update_hash_req_ctx(ctx, 1, 0);
return mv_handle_req(&req->base); return mv_handle_req(&req->base);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment