Re: [PATCH] x86/fpu: Remove unnecessary checks for X86_FEATURE_FPU
From: Eric Biggers
Date: Wed Sep 23 2026 - 23:24:55 EST
On Wed, Sep 23, 2026 at 02:14:50PM -0700, Borislav Petkov wrote:
> On Mon, Aug 31, 2026 at 11:57:06AM -0700, Eric Biggers wrote:
> > Since commit ab05214025ee ("x86/fpu: Remove MATH_EMULATION and related
> > glue code"), X86_FEATURE_FPU is mandatory. If it's absent, the kernel
> > halts execution in fpu__init_system_early_generic(). Remove unnecessary
> > checks for X86_FEATURE_FPU that occur later in core x86 code.
> >
> > Signed-off-by: Eric Biggers <ebiggers@xxxxxxxxxx>
> > ---
> > arch/x86/kernel/fpu/bugs.c | 4 ----
> > arch/x86/kernel/fpu/core.c | 2 +-
> > arch/x86/kernel/fpu/init.c | 2 --
> > arch/x86/kernel/fpu/xstate.c | 5 -----
> > 4 files changed, 1 insertion(+), 12 deletions(-)
>
> Sashiko might have a point here:
>
> https://sashiko.dev/#/patchset/20260831185706.90103-1-ebiggers%40kernel.org
Sure, there's more stuff that can be removed too. It will make for a
large patch, but I'll try to get the rest in x86/fpu code.
- Eric