summaryrefslogtreecommitdiff
path: root/drivers/crypto/bcm/cipher.c
diff options
context:
space:
mode:
authorArd Biesheuvel <ardb@kernel.org>2020-11-10 10:10:42 +0100
committerHerbert Xu <herbert@gondor.apana.org.au>2020-11-20 14:45:32 +1100
commit3ad99c22cebee84034bc53e42f5115dbc97490e8 (patch)
treeae5d8b21d02aab542d2040e79e69b9cb7ecf0301 /drivers/crypto/bcm/cipher.c
parent5761498c4d074560b38a203000afc6e971ffaa7f (diff)
downloadlinux-3ad99c22cebee84034bc53e42f5115dbc97490e8.tar.gz
linux-3ad99c22cebee84034bc53e42f5115dbc97490e8.tar.bz2
linux-3ad99c22cebee84034bc53e42f5115dbc97490e8.zip
crypto: arm64/gcm - move authentication tag check to SIMD domain
Instead of copying the calculated authentication tag to memory and calling crypto_memneq() to verify it, use vector bytewise compare and min across vector instructions to decide whether the tag is valid. This is more efficient, and given that the tag is only transiently held in a NEON register, it is also safer, given that calculated tags for failed decryptions should be withheld. Signed-off-by: Ard Biesheuvel <ardb@kernel.org> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/bcm/cipher.c')
0 files changed, 0 insertions, 0 deletions