[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5beee62b-7b96-4a0e-b85c-400246256aa6@arm.com>
Date: Mon, 12 Jan 2026 16:04:14 +0100
From: Pierre Gondois <pierre.gondois@....com>
To: Viresh Kumar <viresh.kumar@...aro.org>
Cc: linux-kernel@...r.kernel.org, Christian Loehle
<christian.loehle@....com>, Ionela Voinescu <ionela.voinescu@....com>,
zhenglifeng1@...wei.com, Jie Zhan <zhanjie9@...ilicon.com>,
Huang Rui <ray.huang@....com>, "Gautham R. Shenoy" <gautham.shenoy@....com>,
Mario Limonciello <mario.limonciello@....com>,
Perry Yuan <perry.yuan@....com>, "Rafael J. Wysocki" <rafael@...nel.org>,
linux-pm@...r.kernel.org
Subject: Re: [PATCH v2 2/3] cpufreq: Centralize boost freq QoS requests
On 1/8/26 06:10, Viresh Kumar wrote:
> On 08-12-25, 11:59, Pierre Gondois wrote:
>> policy_set_boost() calls the cpufreq set_boost callback.
>> Update the newly added boost_freq_req request from there:
>> - whenever boost is toggled
>> - to cover all possible paths
>>
>> Signed-off-by: Pierre Gondois <pierre.gondois@....com>
>> ---
>> drivers/cpufreq/cpufreq.c | 12 ++++++++++--
>> 1 file changed, 10 insertions(+), 2 deletions(-)
>>
>> diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c
>> index 942416f2741b0..65ef0fa70c388 100644
>> --- a/drivers/cpufreq/cpufreq.c
>> +++ b/drivers/cpufreq/cpufreq.c
>> @@ -603,10 +603,18 @@ static int policy_set_boost(struct cpufreq_policy *policy, bool enable)
>> policy->boost_enabled = enable;
>>
>> ret = cpufreq_driver->set_boost(policy, enable);
>> - if (ret)
>> + if (ret) {
>> policy->boost_enabled = !policy->boost_enabled;
>> + return ret;
>> + }
>>
>> - return ret;
>> + ret = freq_qos_update_request(policy->boost_freq_req, policy->cpuinfo.max_freq);
>> + if (ret < 0) {
>> + policy->boost_enabled = !policy->boost_enabled;
> what about calling set_boost() as well on failure to reverse prev change ?
Yes right indeed
>
>> + return ret;
>> + }
>> +
>> + return 0;
>> }
>>
>> static ssize_t store_local_boost(struct cpufreq_policy *policy,
>> --
>> 2.43.0
Powered by blists - more mailing lists