summaryrefslogtreecommitdiff
path: root/arch/x86
diff options
context:
space:
mode:
authorEric Biggers <ebiggers@google.com>2024-04-06 03:26:10 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2024-06-12 12:11:32 +0300
commitb39d0d661752860633b67409d94e30525eba0ff3 (patch)
tree4a29e917223f2538ac3e740fcf9052e3b3de2ec3 /arch/x86
parent1c5bce29d0d9376782a8d8a76cd423ae43ef280f (diff)
downloadlinux-b39d0d661752860633b67409d94e30525eba0ff3.tar.xz
crypto: x86/sha512-avx2 - add missing vzeroupper
[ Upstream commit 6a24fdfe1edbafacdacd53516654d99068f20eec ] Since sha512_transform_rorx() uses ymm registers, execute vzeroupper before returning from it. This is necessary to avoid reducing the performance of SSE code. Fixes: e01d69cb0195 ("crypto: sha512 - Optimized SHA512 x86_64 assembly routine using AVX instructions.") Signed-off-by: Eric Biggers <ebiggers@google.com> Acked-by: Tim Chen <tim.c.chen@linux.intel.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'arch/x86')
-rw-r--r--arch/x86/crypto/sha512-avx2-asm.S1
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/x86/crypto/sha512-avx2-asm.S b/arch/x86/crypto/sha512-avx2-asm.S
index f08496cd6870..24973f42c43f 100644
--- a/arch/x86/crypto/sha512-avx2-asm.S
+++ b/arch/x86/crypto/sha512-avx2-asm.S
@@ -680,6 +680,7 @@ SYM_TYPED_FUNC_START(sha512_transform_rorx)
pop %r12
pop %rbx
+ vzeroupper
RET
SYM_FUNC_END(sha512_transform_rorx)