crypto: sahara - avoid skcipher fallback code duplication
authorOvidiu Panait <ovidiu.panait@windriver.com>
Fri, 1 Dec 2023 17:06:25 +0000 (19:06 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 25 Jan 2024 23:35:17 +0000 (15:35 -0800)
commit326288412716785e76ea4eb7ca9d3ad361e3fc2e
tree8e10abf90e685b8ccaf5c0ad8b28ff96992449d4
parent63cdfacb0a7078d8d059ec0ff81574c8b1acecd1
crypto: sahara - avoid skcipher fallback code duplication

[ Upstream commit 01d70a4bbff20ea05cadb4c208841985a7cc6596 ]

Factor out duplicated skcipher fallback handling code to a helper function
sahara_aes_fallback(). Also, keep a single check if fallback is required in
sahara_aes_crypt().

Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Stable-dep-of: d1d6351e37aa ("crypto: sahara - handle zero-length aes requests")
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/crypto/sahara.c