Skip to content

Commit 92447aa

Browse files
committed
cpufreq: intel_pstate: Update asym capacity for CPUs that were offline initially
Commit 929ebc9 ("cpufreq: intel_pstate: Set asymmetric CPU capacity on hybrid systems") overlooked a corner case in which some CPUs may be offline to start with and brought back online later, after the intel_pstate driver has been registered, so their asymmetric capacity will not be set. Address this by calling hybrid_update_capacity() in the CPU initialization path that is executed instead of the online path for those CPUs. Note that this asymmetric capacity update will be skipped during driver initialization and mode switches because hybrid_max_perf_cpu is NULL in those cases. Fixes: 929ebc9 ("cpufreq: intel_pstate: Set asymmetric CPU capacity on hybrid systems") Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Link: https://patch.msgid.link/1913414.tdWV9SEqCh@rjwysocki.net
1 parent a97e293 commit 92447aa

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

drivers/cpufreq/intel_pstate.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2275,6 +2275,11 @@ static void intel_pstate_get_cpu_pstates(struct cpudata *cpu)
22752275
} else {
22762276
cpu->pstate.scaling = perf_ctl_scaling;
22772277
}
2278+
/*
2279+
* If the CPU is going online for the first time and it was
2280+
* offline initially, asym capacity scaling needs to be updated.
2281+
*/
2282+
hybrid_update_capacity(cpu);
22782283
} else {
22792284
cpu->pstate.scaling = perf_ctl_scaling;
22802285
cpu->pstate.max_pstate = pstate_funcs.get_max(cpu->cpu);

0 commit comments

Comments
 (0)