]> git.dujemihanovic.xyz Git - linux.git/commit
crypto: caam - fix asynchronous hash
authorGaurav Jain <gaurav.jain@nxp.com>
Thu, 18 Jan 2024 09:25:57 +0000 (14:55 +0530)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 26 Jan 2024 08:35:55 +0000 (16:35 +0800)
commitc5a2f74db71a849f3a60bc153d684d6d28a0c665
tree9f1c26b98878404cd293494ae07c344cc8c432f4
parente1d54d153fc3e697b841999df7cbad51492def8e
crypto: caam - fix asynchronous hash

ahash_alg->setkey is updated to ahash_nosetkey in ahash.c
so checking setkey() function to determine hmac algorithm is not valid.

to fix this added is_hmac variable in structure caam_hash_alg to determine
whether the algorithm is hmac or not.

Fixes: 2f1f34c1bf7b ("crypto: ahash - optimize performance when wrapping shash")
Signed-off-by: Gaurav Jain <gaurav.jain@nxp.com>
Reviewed-by: Eric Biggers <ebiggers@google.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/caam/caamalg_qi2.c
drivers/crypto/caam/caamhash.c