OSDN Git Service

crypto: cavium/nitrox - check assoclen and authsize for gcm(aes) cipher
authorNagadheeraj Rottela <rnagadheeraj@marvell.com>
Mon, 16 Sep 2019 06:42:06 +0000 (06:42 +0000)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 4 Oct 2019 15:06:13 +0000 (01:06 +1000)
commit3fed9baad5fdaa4a1d174326f71f1952c7b66c04
treea44198af2ff6b2941c7be04a0ae0ca4f691766f7
parentbac5c49ec29a0dd1a298211c392154c9db3050b2
crypto: cavium/nitrox - check assoclen and authsize for gcm(aes) cipher

Check if device supports assoclen to solve hung task timeout error when
extra tests are enabled. Return -EINVAL if assoclen is not supported.
Check authsize to return -EINVAL if authentication tag size is invalid.
Change blocksize to 1 to match with generic implementation.

Signed-off-by: Nagadheeraj Rottela <rnagadheeraj@marvell.com>
Reported-by: Mallesham Jatharakonda <mallesham.jatharakonda@oneconvergence.com>
Suggested-by: Mallesham Jatharakonda <mallesham.jatharakonda@oneconvergence.com>
Reviewed-by: Srikanth Jampala <jsrikanth@marvell.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/cavium/nitrox/nitrox_aead.c