]> asedeno.scripts.mit.edu Git - linux.git/commit
crypto: nx - don't abuse blkcipher_desc to pass iv around
authorEric Biggers <ebiggers@google.com>
Sun, 13 Oct 2019 04:39:15 +0000 (21:39 -0700)
committerHerbert Xu <herbert@gondor.apana.org.au>
Wed, 23 Oct 2019 08:46:58 +0000 (19:46 +1100)
commit7740bd51efd697fe3750c7317229ec83571f5d98
tree2e40c28085ac630f59d207bd5029a832ab01fe67
parent713b2e7203354a52ec65a913e89c957bfc8d9220
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>
drivers/crypto/nx/nx-aes-cbc.c
drivers/crypto/nx/nx-aes-ccm.c
drivers/crypto/nx/nx-aes-ctr.c
drivers/crypto/nx/nx-aes-ecb.c
drivers/crypto/nx/nx-aes-gcm.c
drivers/crypto/nx/nx.c
drivers/crypto/nx/nx.h