mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Borislav Petkov <bp@alien8.de>
To: x86@kernel.org
Cc: Andrei Vagin <avagin@gmail.com>, Andrei Vagin <avagin@google.com>,
	Thomas Gleixner <tglx@kernel.org>, Ingo Molnar <mingo@redhat.com>,
	"Chang S. Bae" <chang.seok.bae@intel.com>,
	linux-kernel@vger.kernel.org, criu@lists.linux.dev,
	Dave Hansen <dave.hansen@linux.intel.com>,
	Alexander Mikhalitsyn <alexander@mihalicyn.com>,
	"H. Peter Anvin" <hpa@zytor.com>
Subject: Re: [PATCH 6/7] x86/fpu: Pre-fault only required size of xstate buffer
Date: Fri, 25 Sep 2026 17:14:08 -0700	[thread overview]
Message-ID: <20260926001408.GBarcOUHft7plcljAO@fat_crate.local> (raw)
In-Reply-To: <20260925191608.GAarbIeDRVdrWMczbx@fat_crate.local>

On Fri, Sep 25, 2026 at 12:16:08PM -0700, Borislav Petkov wrote:
> On Fri, Sep 25, 2026 at 09:51:03AM -0700, Andrei Vagin wrote:
> > I've sent v8.1, which is based on tip/fpu. In this version, I moved the
> > xstate_calculate_size prototype to arch/x86/include/asm/fpu/xstate.h.
> > This matches b84c96283684 to avoid the same problem when tip/x86/fpu and
> > tip/perf/core will be merged.
> 
> Thanks, makes sense.
> 
> Lemme queue them and see what conflicts I get.

Ok, this is for my tip folks: merging this into tip/master gives a wrong merge
resolution, see below.

The proper merge should be to drop one of the prototypes.

HTH.

commit c59a5d54d06d4a025f925b0b3b4c63f2b81d75e7 (HEAD -> refs/heads/test-merge)
Merge: a14fcf2723cc 391cac638edd
Author: Borislav Petkov (AMD) <bp@alien8.de>
Date:   Fri Sep 25 17:11:39 2026 -0700

    Merge branch 'tip-x86-fpu' into test-merge
    
    * tip-x86-fpu:
      selftests/x86: Add tests for signal frame FPU portability
      x86/fpu: Pre-fault only required size of xstate buffer
      x86/fpu: Fix potential underflow in xstate_calculate_size()
      x86/fpu: Document reasoning of FX-only fallback
      x86/fpu: Extract restore_from_ia32_fxstate() and clean up fpu__restore_sig()
      x86/fpu: Clean up and rename variables in signal frame handling
      x86/fpu: Document signal frame layout and portability
      xor: Add AVX-512 optimized xor_gen()
      xor: Remove redundant X86_FEATURE_OSXSAVE check
      lib/crc: x86: Stop using cpu_has_xfeatures()
      lib/crypto: x86: Stop using cpu_has_xfeatures()
      crypto: x86 - Stop using cpu_has_xfeatures()
      um: Check for missing AVX and AVX-512 xstate bits
      x86/fpu: Check for missing AVX and AVX-512 xstate bits

diff --cc arch/x86/include/asm/fpu/xstate.h
index 19dec5f0b1c7,33343e5d54b0..25308312cd78
--- a/arch/x86/include/asm/fpu/xstate.h
+++ b/arch/x86/include/asm/fpu/xstate.h
@@@ -110,10 -110,9 +110,12 @@@ int xfeature_size(int xfeature_nr)
  
  void xsaves(struct xregs_state *xsave, u64 mask);
  void xrstors(struct xregs_state *xsave, u64 mask);
 +void xsaves_nmi(struct xregs_state *xsave, u64 mask);
 +
 +unsigned int xstate_calculate_size(u64 xfeatures, bool compacted);
  
+ unsigned int xstate_calculate_size(u64 xfeatures, bool compacted);
+ 
  int xfd_enable_feature(u64 xfd_err);
  
  #ifdef CONFIG_X86_64


> 
> -- 
> Regards/Gruss,
>     Boris.
> 
> https://people.kernel.org/tglx/notes-about-netiquette

-- 
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette

  reply	other threads:[~2026-09-26  0:14 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-24 21:01 [PATCH v8 0/7] x86/fpu: Restore and reinforce signal frame portability Andrei Vagin
2026-09-24 21:01 ` [PATCH 1/7] x86/fpu: Document signal frame layout and portability Andrei Vagin
2026-09-24 21:01 ` [PATCH 2/7] x86/fpu: Clean up and rename variables in signal frame handling Andrei Vagin
2026-09-24 21:01 ` [PATCH 3/7] x86/fpu: Extract restore_from_ia32_fxstate() and clean up fpu__restore_sig() Andrei Vagin
2026-09-24 21:01 ` [PATCH 4/7] x86/fpu: Document reasoning of FX-only fallback Andrei Vagin
2026-09-24 21:01 ` [PATCH 5/7] x86/fpu: Fix potential underflow in xstate_calculate_size() Andrei Vagin
2026-09-24 21:01 ` [PATCH 6/7] x86/fpu: Pre-fault only required size of xstate buffer Andrei Vagin
2026-09-25  4:02   ` Borislav Petkov
2026-09-25 16:51     ` Andrei Vagin
2026-09-25 19:16       ` Borislav Petkov
2026-09-26  0:14         ` Borislav Petkov [this message]
2026-09-24 21:01 ` [PATCH 7/7] selftests/x86: Add tests for signal frame FPU portability Andrei Vagin
2026-09-24 21:50 ` [PATCH v8 0/7] x86/fpu: Restore and reinforce signal frame portability Andrei Vagin
  -- strict thread matches above, loose matches on Subject: below --
2026-09-25 16:24 [PATCH v8.1 " Andrei Vagin
2026-09-25 16:24 ` [PATCH 6/7] x86/fpu: Pre-fault only required size of xstate buffer Andrei Vagin
2026-09-24  4:15 [PATCH v7 0/7] x86/fpu: Restore and reinforce signal frame portability Andrei Vagin
2026-09-24  4:16 ` [PATCH 6/7] x86/fpu: Pre-fault only required size of xstate buffer Andrei Vagin
2026-09-16 23:23 [PATCH v6 0/7] x86/fpu: Restore and reinforce signal frame portability Andrei Vagin
2026-09-16 23:23 ` [PATCH 6/7] x86/fpu: Pre-fault only required size of xstate buffer Andrei Vagin
2026-09-23 23:56   ` Borislav Petkov
2026-09-08  4:34 [PATCH v5 0/7] x86/fpu: Restore and reinforce signal frame portability Andrei Vagin
2026-09-08  4:34 ` [PATCH 6/7] x86/fpu: Pre-fault only required size of xstate buffer Andrei Vagin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260926001408.GBarcOUHft7plcljAO@fat_crate.local \
    --to=bp@alien8.de \
    --cc=alexander@mihalicyn.com \
    --cc=avagin@gmail.com \
    --cc=avagin@google.com \
    --cc=chang.seok.bae@intel.com \
    --cc=criu@lists.linux.dev \
    --cc=dave.hansen@linux.intel.com \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=tglx@kernel.org \
    --cc=x86@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®