All of lore.kernel.org
 help / color / mirror / Atom feed
* + xor-add-missing-vzeroupper-to-avx-code.patch added to mm-nonmm-unstable branch
@ 2026-08-31 22:14 Andrew Morton
  0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2026-08-31 22:14 UTC (permalink / raw)
  To: mm-commits, stable, hch, ebiggers, akpm


The patch titled
     Subject: xor: add missing vzeroupper to AVX code
has been added to the -mm mm-nonmm-unstable branch.  Its filename is
     xor-add-missing-vzeroupper-to-avx-code.patch

This patch will shortly appear at
     https://git.kernel.org/pub/scm/linux/kernel/git/akpm/25-new.git/tree/patches/xor-add-missing-vzeroupper-to-avx-code.patch

This patch will later appear in the mm-nonmm-unstable branch at
    git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***

The -mm tree is included into linux-next via various
branches at git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
and is updated there most days

------------------------------------------------------
From: Eric Biggers <ebiggers@kernel.org>
Subject: xor: add missing vzeroupper to AVX code
Date: Mon, 31 Aug 2026 14:22:48 -0700

Since the AVX optimized XOR 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.

Link: https://lore.kernel.org/20260831212248.213805-1-ebiggers@kernel.org
Fixes: ea4d26ae24e5 ("raid5: add AVX optimized RAID5 checksumming")
Signed-off-by: Eric Biggers <ebiggers@kernel.org>
Cc: Christoph Hellwig <hch@lst.de>
Cc: <stable@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 lib/raid/xor/x86/xor-avx.c |    1 +
 1 file changed, 1 insertion(+)

--- a/lib/raid/xor/x86/xor-avx.c~xor-add-missing-vzeroupper-to-avx-code
+++ a/lib/raid/xor/x86/xor-avx.c
@@ -147,6 +147,7 @@ static void xor_gen_avx(void *dest, void
 {
 	kernel_fpu_begin();
 	xor_gen_avx_inner(dest, srcs, src_cnt, bytes);
+	asm volatile("vzeroupper");
 	kernel_fpu_end();
 }
 
_

Patches currently in -mm which might be from ebiggers@kernel.org are

xor-add-missing-vzeroupper-to-avx-code.patch
raid6-add-missing-vzeroupper-to-avx2-code.patch
raid6-add-missing-vzeroupper-to-avx-512-code.patch


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2026-08-31 22:14 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-31 22:14 + xor-add-missing-vzeroupper-to-avx-code.patch added to mm-nonmm-unstable branch Andrew Morton

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.