[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <Yc7q4T839yqpCpfE@gondor.apana.org.au>
Date: Fri, 31 Dec 2021 22:34:57 +1100
From: Herbert Xu <herbert@...dor.apana.org.au>
To: Jakub Kicinski <kuba@...nel.org>
Cc: netdev@...r.kernel.org, stable@...r.kernel.org, x86@...nel.org,
ardb@...nel.org, linux-crypto@...r.kernel.org
Subject: Re: [PATCH crypto] x86/aesni: don't require alignment of data
On Tue, Dec 21, 2021 at 07:06:11AM -0800, Jakub Kicinski wrote:
> x86 AES-NI routines can deal with unaligned data. Crypto context
> (key, iv etc.) have to be aligned but we take care of that separately
> by copying it onto the stack. We were feeding unaligned data into
> crypto routines up until commit 83c83e658863 ("crypto: aesni -
> refactor scatterlist processing") switched to use the full
> skcipher API which uses cra_alignmask to decide data alignment.
>
> This fixes 21% performance regression in kTLS.
>
> Tested by booting with CONFIG_CRYPTO_MANAGER_EXTRA_TESTS=y
> (and running thru various kTLS packets).
>
> CC: stable@...r.kernel.org # 5.15+
> Fixes: 83c83e658863 ("crypto: aesni - refactor scatterlist processing")
> Signed-off-by: Jakub Kicinski <kuba@...nel.org>
> ---
> CC: herbert@...dor.apana.org.au
> CC: x86@...nel.org
> CC: ardb@...nel.org
> CC: linux-crypto@...r.kernel.org
> ---
> arch/x86/crypto/aesni-intel_glue.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
Patch applied. Thanks.
--
Email: Herbert Xu <herbert@...dor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
Powered by blists - more mailing lists