diff options
author | Eric Biggers <ebiggers@google.com> | 2019-10-13 06:39:15 +0200 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2019-10-23 10:46:58 +0200 |
commit | 7740bd51efd697fe3750c7317229ec83571f5d98 (patch) | |
tree | 2e40c28085ac630f59d207bd5029a832ab01fe67 /drivers/crypto/nx/nx-aes-ecb.c | |
parent | crypto: padlock-aes - convert to skcipher API (diff) | |
download | linux-7740bd51efd697fe3750c7317229ec83571f5d98.tar.xz linux-7740bd51efd697fe3750c7317229ec83571f5d98.zip |
crypto: nx - don't abuse blkcipher_desc to pass iv around
The NX crypto driver is using 'struct blkcipher_desc' to pass the IV
around, even for AEADs (for which it creates the struct on the stack).
This is not appropriate since this structure is part of the "blkcipher"
API, which is deprecated and will be removed.
Just pass around the IV directly instead.
Signed-off-by: Eric Biggers <ebiggers@google.com>
Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/nx/nx-aes-ecb.c')
-rw-r--r-- | drivers/crypto/nx/nx-aes-ecb.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/crypto/nx/nx-aes-ecb.c b/drivers/crypto/nx/nx-aes-ecb.c index c67570470c9d..87183890d1ab 100644 --- a/drivers/crypto/nx/nx-aes-ecb.c +++ b/drivers/crypto/nx/nx-aes-ecb.c @@ -72,8 +72,8 @@ static int ecb_aes_nx_crypt(struct blkcipher_desc *desc, do { to_process = nbytes - processed; - rc = nx_build_sg_lists(nx_ctx, desc, dst, src, &to_process, - processed, NULL); + rc = nx_build_sg_lists(nx_ctx, NULL, dst, src, &to_process, + processed, NULL); if (rc) goto out; |