On Wed, Sep 22 2021 at 22:27, Rafael J. Wysocki wrote: > On Tue, Sep 21, 2021 at 10:18 PM Thomas Gleixner <tglx@xxxxxxxxxxxxx> wrote: >> >> On Tue, Sep 21 2021 at 20:05, Rafael J. Wysocki wrote: >> > On 9/19/2021 2:14 AM, Thomas Gleixner wrote: >> >> What's the proper way to figure out whether PC10 is supported? >> > >> > I can't say without research. I think it'd be sufficient to check if >> > C10 is supported, because asking for it is the only way to get PC10. >> >> Do we have a common function for that or do I need to implement the >> gazillionst CPUID query for that? > > intel_idle has intel_idle_verify_cstate() that works on MWAIT > substates from CPUID. It looks like this could be reused. Not to me. That's some cpuidle/intel_idle specific check which depends on cpuidle_state_table being set up which is not available during early boot. The question I was asking whether we have a central place where we can retrieve such information w/o invoking CPUID over and over again and applying voodoo checks on it. Obviously we don't, which sucks. Thanks, tglx