[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAJZ5v0iwAsVnvYKjKskLXuu5bDV_SMpgnTTy0zD=7fgnGzHQnA@mail.gmail.com>
Date: Fri, 18 Apr 2025 21:28:41 +0200
From: "Rafael J. Wysocki" <rafael@...nel.org>
To: Nicholas Chin <nic.c3.14@...il.com>, Viresh Kumar <viresh.kumar@...aro.org>
Cc: "Rafael J. Wysocki" <rafael@...nel.org>, linux-kernel@...r.kernel.org,
linux-pm@...r.kernel.org, rafael.j.wysocki@...el.com,
vincent.guittot@...aro.org, zhenglifeng1@...wei.com
Subject: Re: [PATCH] cpufreq: acpi: Don't enable boost on policy exit
On Fri, Apr 18, 2025 at 7:06 PM Nicholas Chin <nic.c3.14@...il.com> wrote:
>
> On 2025-04-17 23:58, Viresh Kumar wrote:
> > What about something like this instead ? Nicholas, can you give this a try
> > along with the $Subject patch (both patches should be applied) ?
> >
> > diff --git a/drivers/cpufreq/acpi-cpufreq.c b/drivers/cpufreq/acpi-cpufreq.c
> > index 924314cdeebc..71557f2ac22a 100644
> > --- a/drivers/cpufreq/acpi-cpufreq.c
> > +++ b/drivers/cpufreq/acpi-cpufreq.c
> > @@ -909,8 +909,10 @@ static int acpi_cpufreq_cpu_init(struct
> > cpufreq_policy *policy)
> > if (perf->states[0].core_frequency * 1000 != freq_table[0].frequency)
> > pr_warn(FW_WARN "P-state 0 is not max freq\n");
> >
> > - if (acpi_cpufreq_driver.set_boost)
> > + if (acpi_cpufreq_driver.set_boost) {
> > policy->boost_supported = true;
> > + policy->boost_enabled = boost_state(cpu);
So it updates policy->boost_enabled in accordance with the current
setting in the MSR.
IMO it would be better to update the MSR in accordance with
policy->boost_enabled or users may get confused if their boost
settings change after a suspend-resume cycle. Or have I got lost
completely?
> > + }
> >
> > return result;
>
> Thanks, applying this patch along with the $Subject patch works.
Powered by blists - more mailing lists