RE: [RFC PATCH 01/56] Documentation/admin-guide: Add documentation

Kaplan, David
2025-10-17T14:04:14Z

[AMD Official Use Only - AMD Internal Distribution Only]

> -----Original Message-----
> From: Josh Poimboeuf <jpoimboe@kernel.org>
> Sent: Thursday, October 16, 2025 4:25 PM
> To: Kaplan, David <David.Kaplan@amd.com>
> Cc: Thomas Gleixner <tglx@linutronix.de>; Borislav Petkov <bp@alien8.de>; Peter
> Zijlstra <peterz@infradead.org>; Pawan Gupta
> <pawan.kumar.gupta@linux.intel.com>; Ingo Molnar <mingo@redhat.com>; Dave
> Hansen <dave.hansen@linux.intel.com>; x86@kernel.org; H . Peter Anvin
> <hpa@zytor.com>; Alexander Graf <graf@amazon.com>; Boris Ostrovsky
> <boris.ostrovsky@oracle.com>; linux-kernel@vger.kernel.org
> Subject: Re: [RFC PATCH 01/56] Documentation/admin-guide: Add documentation
>
> Caution: This message originated from an External Source. Use proper caution
> when opening attachments, clicking links, or responding.
>
>
> On Mon, Oct 13, 2025 at 09:33:49AM -0500, David Kaplan wrote:
> > +Runtime Limitations
> > +^^^^^^^^^^^^^^^^^^^
> > +
> > +There are a few mitigations that cannot be toggled at runtime due to the way
> > +they are structured. Specifically, kernel PTI (page table isolation) cannot be
> > +toggled because of the complexity of this mitigation. Additionally, SMT cannot
> > +be disabled at runtime. Therefore, if a bug mitigation requires disabling SMT,
> > +a warning message will be printed.
>
> Is there a particular reason SMT can't be disabled? There's definitely
> a way to do it, see /sys/devices/system/cpu/smt/{active,control}.
>

Reason was I didn't realize you could do that :)

The existing bugs.c logic used cpu_smt_disable() which is an __init function. But now I see that if you have CONFIG_HOTPLUG_SMT then cpuhp_smt_enable()/cpuhp_smt_disable() look like they should be able to handle this.

I will look into supporting this, if CONFIG_HOTPLUG_SMT is enabled.

Thanks
--David Kaplan