Re: [PATCH v3 3/3] intel_idle: Provide enter_dead() handler for SRF

From: Dave Hansen
Date: Tue Nov 12 2024 - 13:22:06 EST


On 11/12/24 03:28, Rafael J. Wysocki wrote:
> On Tue, Nov 12, 2024 at 12:18 PM Patryk Wlazlyn
> <patryk.wlazlyn@xxxxxxxxxxxxxxx> wrote:
>>> This series has said multiple times how the old algorithm is wrong. But
>>> it never actually _fixed_ the bad algorithm, only worked around it.
>>>
>>> Does mwait_play_dead() itself need to get fixed?
>> I don't think so. The old algorithm gives fairly good heuristic for computing
>> the mwait hint for the deepest cstate. Even though it's not guaranteed to work,
>> it does work on most of the platforms that don't early return. I think we should
>> leave it, but prefer idle_driver.
> IOW, as a fallback mechanism, it is as good as it gets.
>
> As the primary source of information though, not quite.

Could we also work to make this a bit more clear when it should be used
and where the primary sources of information are?