crypto: ccp - Cleanup hash invocation calls
Cleanup the ahash digest invocations to check the init return code and make use of the finup routine. Signed-off-by: Tom Lendacky <thomas.lendacky@amd.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Tento commit je obsažen v:
@@ -248,9 +248,13 @@ static int ccp_sha_finup(struct ahash_request *req)
|
||||
|
||||
static int ccp_sha_digest(struct ahash_request *req)
|
||||
{
|
||||
ccp_sha_init(req);
|
||||
int ret;
|
||||
|
||||
return ccp_do_sha_update(req, req->nbytes, 1);
|
||||
ret = ccp_sha_init(req);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
return ccp_sha_finup(req);
|
||||
}
|
||||
|
||||
static int ccp_sha_setkey(struct crypto_ahash *tfm, const u8 *key,
|
||||
|
Odkázat v novém úkolu
Zablokovat Uživatele