FAILED: patch "[PATCH] cpufreq: intel_pstate: Sync policy->cur during CPU offline" failed to apply to 5.10-stable tree
Subsystems (3)
[email protected]
maintainerThe patch below does not apply to the 5.10-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.
To reproduce the conflict and resubmit, you may use the following commands:
git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-5.10.y
git checkout FETCH_HEAD
git cherry-pick -x bcbdaa1086c25a8a5d48e04e1b82fdfb0682b681
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '2026071452-shimmer-reformer-0bc4@gregkh' --subject-prefix 'PATCH 5.10.y' 'HEAD^..'
Possible dependencies:
thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
From bcbdaa1086c25a8a5d48e04e1b82fdfb0682b681 Mon Sep 17 00:00:00 2001
From: Fushuai Wang <[email protected]>
Date: Wed, 20 May 2026 11:21:19 +0800
Subject: [PATCH] cpufreq: intel_pstate: Sync policy->cur during CPU offline
When a CPU goes offline with HWP disabled, intel_pstate_set_min_pstate() sets the MSR_IA32_PERF_CTL to minimum frequency to prevent SMT siblings from being restricted. However, the policy->cur value was not updated, leaving it at the previous value.
When the CPU comes back online, governor->limits() checks if target_freq equals policy->cur and skips the frequency adjustment if they match. Since policy->cur still holds the previous value, the governor does not call cpufreq_driver->target to update MSR_IA32_PERF_CTL.
Fix this by synchronizing policy->cur with the hardware state when setting minimum pstate during CPU offline.
drivers/cpufreq/intel_pstate.c +4 -2
@@ -2984,10 +2984,12 @@ static int intel_cpufreq_cpu_offline(struct cpufreq_policy *policy)* from getting to lower performance levels, so force the minimum * performance on CPU offline to prevent that from happening. */ -if (hwp_active) +if (hwp_active) {intel_pstate_hwp_offline (cpu); -else + }else {intel_pstate_set_min_pstate (cpu); + policy->cur = cpu->pstate.min_freq; + }intel_pstate_exit_perf_limits (policy);
Sasha Levin
maintainerPATCH 1/1 cpufreq: intel_pstate: Sync policy->cur during CPU offline
From: Fushuai Wang <[email protected]>
[ Upstream commit bcbdaa1086c25a8a5d48e04e1b82fdfb0682b681 ]
When a CPU goes offline with HWP disabled, intel_pstate_set_min_pstate() sets the MSR_IA32_PERF_CTL to minimum frequency to prevent SMT siblings from being restricted. However, the policy->cur value was not updated, leaving it at the previous value.
When the CPU comes back online, governor->limits() checks if target_freq equals policy->cur and skips the frequency adjustment if they match. Since policy->cur still holds the previous value, the governor does not call cpufreq_driver->target to update MSR_IA32_PERF_CTL.
Fix this by synchronizing policy->cur with the hardware state when setting minimum pstate during CPU offline.
--- drivers/cpufreq/intel_pstate.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
drivers/cpufreq/intel_pstate.c +4 -2
@@ -2355,10 +2355,12 @@ static int intel_pstate_cpu_offline(struct cpufreq_policy *policy)* from getting to lower performance levels, so force the minimum * performance on CPU offline to prevent that from happening. */ -if (hwp_active) +if (hwp_active) {intel_pstate_hwp_offline (cpu); -else + }else {intel_pstate_set_min_pstate (cpu); + policy->cur = cpu->pstate.min_pstate * cpu->pstate.scaling; + }intel_pstate_exit_perf_limits (policy);
Signature · 1 line
2.53.0