Re: [PATCH v3] x86/cpufeatures: Make X86_FEATURE_SHSTK clearcpuid-able

From: Borislav Petkov

Date: Thu May 14 2026 - 13:00:03 EST


On Thu, May 14, 2026 at 06:09:32PM +0200, Mathias Krause wrote:
> Allow X86_FEATURE_SHST to be disabled through the kernel commandline via
> 'clearcpuid=shstk' as 'nousershstk' would still enable CR4.CET even if
> no CET features are in use.

clearcpuid= taints the kernel because that cmdline option is not supposed to
be used except for debugging crap... and alas people are still using it. No
wonder... :-\

Anyway, "nousershstk" should disable the CR4 bit too.

--
Regards/Gruss,
Boris.

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