Re: [PATCH v3 2/3] x86/smp native_play_dead: Prefer cpuidle_play_dead() over mwait_play_dead()

From: Rafael J. Wysocki
Date: Tue Nov 12 2024 - 11:24:28 EST


On Tue, Nov 12, 2024 at 4:08 PM Peter Zijlstra <peterz@xxxxxxxxxxxxx> wrote:
>
> On Tue, Nov 12, 2024 at 03:56:22PM +0100, Rafael J. Wysocki wrote:
>
> > > So given we don't have any such code, why can't we simply fix the cstate
> > > parsing we have in mwait_play_dead() and call it a day?
> >
> > I'll leave this one to Artem, but there is at least one reason to
> > avoid doing that I know about: There is no guarantee that whatever has
> > been found was actually validated.
>
> It's a bit daft to explicitly advertise a state in CPUID that's not
> validated. I realize that MSFT will likely only ever use the ACPI table,

Right.

> but at the same time, the CPUID bits and ACPI tables both come from the
> same BIOS image, no?

Yes, but the list of C-states advertised as supported in CPUID is
usually longer than the _CST list size (at most 3) ...