* [PATCH] cpufreq/amd-pstate: Drop refresh_frequency_limits() from set_boost
@ 2026-12-03 13:07 Farrukh Seyer Hasan
2026-12-04 22:27 ` Mario Limonciello
0 siblings, 1 reply; 2+ messages in thread
From: Farrukh Seyer Hasan @ 2026-12-03 13:07 UTC (permalink / raw)
To: Mario Limonciello, Huang Rui, Rafael J . Wysocki, Viresh Kumar
Cc: Perry Yuan, K Prateek Nayak, linux-pm, linux-kernel,
Farrukh Seyer Hasan
Commit 6e39ba4e5a82 ("cpufreq: Add boost_freq_req QoS request") moved
the boost QoS update into policy_set_boost() after calling ->set_boost().
Because amd_pstate_set_boost() still calls refresh_frequency_limits(),
it evaluates policy limits before policy->boost_freq_req is updated.
Drop the redundant call, matching cppc_cpufreq_set_boost().
Fixes: 6e39ba4e5a82 ("cpufreq: Add boost_freq_req QoS request")
Signed-off-by: Farrukh Seyer Hasan <farrukh13hasan31@gmail.com>
---
drivers/cpufreq/amd-pstate.c | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/drivers/cpufreq/amd-pstate.c b/drivers/cpufreq/amd-pstate.c
index 69bfeb923a53..03444a81855e 100644
--- a/drivers/cpufreq/amd-pstate.c
+++ b/drivers/cpufreq/amd-pstate.c
@@ -899,17 +899,13 @@ static int amd_pstate_cpu_boost_update(struct cpufreq_policy *policy, bool on)
static int amd_pstate_set_boost(struct cpufreq_policy *policy, int state)
{
struct amd_cpudata *cpudata = policy->driver_data;
- int ret;
if (!cpudata->boost_supported) {
pr_err("Boost mode is not supported by this processor or SBIOS\n");
return -EOPNOTSUPP;
}
- ret = amd_pstate_cpu_boost_update(policy, state);
- refresh_frequency_limits(policy);
-
- return ret;
+ return amd_pstate_cpu_boost_update(policy, state);
}
static int amd_pstate_init_boost_support(struct amd_cpudata *cpudata)
--
2.56.1
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [PATCH] cpufreq/amd-pstate: Drop refresh_frequency_limits() from set_boost
2026-12-03 13:07 [PATCH] cpufreq/amd-pstate: Drop refresh_frequency_limits() from set_boost Farrukh Seyer Hasan
@ 2026-12-04 22:27 ` Mario Limonciello
0 siblings, 0 replies; 2+ messages in thread
From: Mario Limonciello @ 2026-12-04 22:27 UTC (permalink / raw)
To: Farrukh Seyer Hasan, Huang Rui, Rafael J . Wysocki, Viresh Kumar
Cc: Perry Yuan, K Prateek Nayak, linux-pm, linux-kernel
On 12/3/26 07:07, Farrukh Seyer Hasan wrote:
> Commit 6e39ba4e5a82 ("cpufreq: Add boost_freq_req QoS request") moved
> the boost QoS update into policy_set_boost() after calling ->set_boost().
>
> Because amd_pstate_set_boost() still calls refresh_frequency_limits(),
> it evaluates policy limits before policy->boost_freq_req is updated.
> Drop the redundant call, matching cppc_cpufreq_set_boost().
>
> Fixes: 6e39ba4e5a82 ("cpufreq: Add boost_freq_req QoS request")
> Signed-off-by: Farrukh Seyer Hasan <farrukh13hasan31@gmail.com>
Reviewed-by: Mario Limonciello (AMD) <superm1@kernel.org>
I'll pick this up.
> ---
> drivers/cpufreq/amd-pstate.c | 6 +-----
> 1 file changed, 1 insertion(+), 5 deletions(-)
>
> diff --git a/drivers/cpufreq/amd-pstate.c b/drivers/cpufreq/amd-pstate.c
> index 69bfeb923a53..03444a81855e 100644
> --- a/drivers/cpufreq/amd-pstate.c
> +++ b/drivers/cpufreq/amd-pstate.c
> @@ -899,17 +899,13 @@ static int amd_pstate_cpu_boost_update(struct cpufreq_policy *policy, bool on)
> static int amd_pstate_set_boost(struct cpufreq_policy *policy, int state)
> {
> struct amd_cpudata *cpudata = policy->driver_data;
> - int ret;
>
> if (!cpudata->boost_supported) {
> pr_err("Boost mode is not supported by this processor or SBIOS\n");
> return -EOPNOTSUPP;
> }
>
> - ret = amd_pstate_cpu_boost_update(policy, state);
> - refresh_frequency_limits(policy);
> -
> - return ret;
> + return amd_pstate_cpu_boost_update(policy, state);
> }
>
> static int amd_pstate_init_boost_support(struct amd_cpudata *cpudata)
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-12-04 22:27 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-12-03 13:07 [PATCH] cpufreq/amd-pstate: Drop refresh_frequency_limits() from set_boost Farrukh Seyer Hasan
2026-12-04 22:27 ` Mario Limonciello
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox