Messages in this thread | | | Date | Wed, 31 Mar 2021 10:24:20 +0200 | From | Borislav Petkov <> | Subject | Re: Candidate Linux ABI for Intel AMX and hypothetical new related features |
| |
On Fri, Mar 26, 2021 at 04:12:25PM -0700, Andy Lutomirski wrote: > To detect features and control XCR0, we add some new arch_prctls: > > arch_prctl(ARCH_GET_XCR0_SUPPORT, 0, ...); > > returns the set of XCR0 bits supported on the current kernel. > > arch_prctl(ARCH_GET_XCR0_LAZY_SUPPORT, 0, ...); > > returns 0. See below. > > arch_prctl(ARCH_SET_XCR0, xcr0, lazy_states, sigsave_states, > sigclear_states, 0);
Right, but I'd simply replace that "XCR0" arch detail, more or less, with "XSTATE":
ARCH_GET_XSTATE_SUPPORT ARCH_GET_XSTATE_LAZY_SUPPORT ARCH_SET_XSTATE or ARCH_ENABLE_XSTATE or so
to denote that this is controlling XSTATE handling while the XCR0 thing is the control register and when in the future something else does control that (XCR0[63] is one provision for that) then we're still on-point with the naming.
> Thoughts?
FTR, I really like the aspect of apps *requesting* handling of non-legacy, fat states and latter remaining off otherwise in order to keep the sanity of everyone involved.
Thx.
-- Regards/Gruss, Boris.
https://people.kernel.org/tglx/notes-about-netiquette
| |