arch/x86/crypto/aria-aesni-avx2-asm_64.S | 6 ++++++ 1 file changed, 6 insertions(+)
Since the AVX2 optimized ARIA code uses YMM registers, execute
vzeroupper before returning from it. This is needed to avoid degrading
the performance of any later SSE code that may happen to be executed.
Fixes: 37d8d3ae7a58 ("crypto: x86/aria - implement aria-avx2")
Cc: stable@vger.kernel.org
Cc: Taehee Yoo <ap420073@gmail.com>
Signed-off-by: Eric Biggers <ebiggers@kernel.org>
---
This didn't get picked up by the x86 maintainers yet. Herbert, can you
take this through the crypto tree?
arch/x86/crypto/aria-aesni-avx2-asm_64.S | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/arch/x86/crypto/aria-aesni-avx2-asm_64.S b/arch/x86/crypto/aria-aesni-avx2-asm_64.S
index ed53d4f46bd7..fda8cb8a99a8 100644
--- a/arch/x86/crypto/aria-aesni-avx2-asm_64.S
+++ b/arch/x86/crypto/aria-aesni-avx2-asm_64.S
@@ -982,6 +982,7 @@ SYM_TYPED_FUNC_START(aria_aesni_avx2_encrypt_32way)
%ymm8, %ymm9, %ymm10, %ymm11, %ymm12, %ymm13, %ymm14,
%ymm15, %rax);
+ vzeroupper;
FRAME_END
RET;
SYM_FUNC_END(aria_aesni_avx2_encrypt_32way)
@@ -1007,6 +1008,7 @@ SYM_TYPED_FUNC_START(aria_aesni_avx2_decrypt_32way)
%ymm8, %ymm9, %ymm10, %ymm11, %ymm12, %ymm13, %ymm14,
%ymm15, %rax);
+ vzeroupper;
FRAME_END
RET;
SYM_FUNC_END(aria_aesni_avx2_decrypt_32way)
@@ -1209,6 +1211,7 @@ SYM_TYPED_FUNC_START(aria_aesni_avx2_ctr_crypt_32way)
%ymm8, %ymm9, %ymm10, %ymm11, %ymm12, %ymm13, %ymm14,
%ymm15, %r10);
+ vzeroupper;
FRAME_END
RET;
SYM_FUNC_END(aria_aesni_avx2_ctr_crypt_32way)
@@ -1359,6 +1362,7 @@ SYM_TYPED_FUNC_START(aria_aesni_avx2_gfni_encrypt_32way)
%ymm8, %ymm9, %ymm10, %ymm11, %ymm12, %ymm13, %ymm14,
%ymm15, %rax);
+ vzeroupper;
FRAME_END
RET;
SYM_FUNC_END(aria_aesni_avx2_gfni_encrypt_32way)
@@ -1384,6 +1388,7 @@ SYM_TYPED_FUNC_START(aria_aesni_avx2_gfni_decrypt_32way)
%ymm8, %ymm9, %ymm10, %ymm11, %ymm12, %ymm13, %ymm14,
%ymm15, %rax);
+ vzeroupper;
FRAME_END
RET;
SYM_FUNC_END(aria_aesni_avx2_gfni_decrypt_32way)
@@ -1428,6 +1433,7 @@ SYM_TYPED_FUNC_START(aria_aesni_avx2_gfni_ctr_crypt_32way)
%ymm8, %ymm9, %ymm10, %ymm11, %ymm12, %ymm13, %ymm14,
%ymm15, %r10);
+ vzeroupper;
FRAME_END
RET;
SYM_FUNC_END(aria_aesni_avx2_gfni_ctr_crypt_32way)
base-commit: cee9395acd8043be0644b25c34bfa86623f2b935
--
2.55.0
On Mon, Aug 31, 2026 at 02:17:15PM -0700, Eric Biggers wrote:
> Since the AVX2 optimized ARIA code uses YMM registers, execute
> vzeroupper before returning from it. This is needed to avoid degrading
> the performance of any later SSE code that may happen to be executed.
>
> Fixes: 37d8d3ae7a58 ("crypto: x86/aria - implement aria-avx2")
> Cc: stable@vger.kernel.org
> Cc: Taehee Yoo <ap420073@gmail.com>
> Signed-off-by: Eric Biggers <ebiggers@kernel.org>
> ---
>
> This didn't get picked up by the x86 maintainers yet. Herbert, can you
> take this through the crypto tree?
>
> arch/x86/crypto/aria-aesni-avx2-asm_64.S | 6 ++++++
> 1 file changed, 6 insertions(+)
Patch applied. Thanks.
--
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
On Mon, Aug 31, 2026 at 02:17:15PM -0700, Eric Biggers wrote:
> Since the AVX2 optimized ARIA code uses YMM registers, execute
> vzeroupper before returning from it. This is needed to avoid degrading
> the performance of any later SSE code that may happen to be executed.
>
> Fixes: 37d8d3ae7a58 ("crypto: x86/aria - implement aria-avx2")
> Cc: stable@vger.kernel.org
> Cc: Taehee Yoo <ap420073@gmail.com>
> Signed-off-by: Eric Biggers <ebiggers@kernel.org>
> ---
>
> This didn't get picked up by the x86 maintainers yet. Herbert, can you
> take this through the crypto tree?
OK I could do that. I presume you want this to go into 7.3, right?
Cheers,
--
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
On Wed, Sep 02, 2026 at 06:38:29PM +1000, Herbert Xu wrote:
> On Mon, Aug 31, 2026 at 02:17:15PM -0700, Eric Biggers wrote:
> > Since the AVX2 optimized ARIA code uses YMM registers, execute
> > vzeroupper before returning from it. This is needed to avoid degrading
> > the performance of any later SSE code that may happen to be executed.
> >
> > Fixes: 37d8d3ae7a58 ("crypto: x86/aria - implement aria-avx2")
> > Cc: stable@vger.kernel.org
> > Cc: Taehee Yoo <ap420073@gmail.com>
> > Signed-off-by: Eric Biggers <ebiggers@kernel.org>
> > ---
> >
> > This didn't get picked up by the x86 maintainers yet. Herbert, can you
> > take this through the crypto tree?
>
> OK I could do that. I presume you want this to go into 7.3, right?
>
It is a bug fix, so yes it should go into 7.3.
- Eric
© 2016 - 2026 Red Hat, Inc.