Re: [RFC][PATCH v0.3 6/6] cpufreq: intel_pstate: EAS support for hybrid platforms

From: Rafael J. Wysocki
Date: Thu Mar 13 2025 - 14:50:57 EST


On Thu, Mar 13, 2025 at 7:46 PM Tim Chen <tim.c.chen@xxxxxxxxxxxxxxx> wrote:
>
> On Fri, 2025-03-07 at 20:42 +0100, Rafael J. Wysocki wrote:
> >
> >
> > --- a/drivers/cpufreq/intel_pstate.c
> > +++ b/drivers/cpufreq/intel_pstate.c
> > @@ -44,6 +44,8 @@
> > #define INTEL_CPUFREQ_TRANSITION_DELAY_HWP 5000
> > #define INTEL_CPUFREQ_TRANSITION_DELAY 500
> >
> > +#define INTEL_PSTATE_CORE_SCALING 100000
> > +
>
> Minor nits.
>
> Suggest move the above define to
>
> #define HYBRID_SCALING_FACTOR_ADL 78741
> #define HYBRID_SCALING_FACTOR_MTL 80000
> #define HYBRID_SCALING_FACTOR_LNL 86957
> #define INTEL_PSTATE_CORE_SCALING 100000
>
> to keep the scaling factors at the same place.

It may be needed earlier, but I see your point. Keeping them together
will make sense.

>
> > @@ -3425,6 +3539,8 @@
> >
> > cpufreq_unregister_driver(intel_pstate_driver);
> > intel_pstate_driver_cleanup();
> > + /* Trigger EAS support reconfiguration in case it was used. */
>
> May be clearer to say
>
> /* Disable EAS support in case it was used */

Sure.

> My first read of the comment thought that we are enabling EAS support.
>
> > + rebuild_sched_domains_energy();
> > return 0;
> > }
> >
>
> Rest of patch looks good.

Thanks for the review!