lkml.org 
[lkml]   [2024]   [Jan]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2] crypto: caam: fix asynchronous hash
On Thu, Jan 18, 2024 at 02:55:57PM +0530, Gaurav Jain wrote:
> 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>
> ---
> changes in v2:
> - remove if condition based on crypto_hash_alg_has_setkey() funcion.
> - added is_hmac variable in caam_hash_alg and updated the if
> condition for checking hmac algorithm.
>
> drivers/crypto/caam/caamalg_qi2.c | 7 +++++--
> drivers/crypto/caam/caamhash.c | 7 +++++--
> 2 files changed, 10 insertions(+), 4 deletions(-)

Reviewed-by: Eric Biggers <ebiggers@google.com>

- Eric

\
 
 \ /
  Last update: 2024-05-27 14:32    [W:0.028 / U:0.024 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site