Commit 7fb3ff2
sched/core: Fix arch_scale_freq_tick() on tickless systems
In order for the scheduler to be frequency invariant we measure the
ratio between the maximum CPU frequency and the actual CPU frequency.
During long tickless periods of time the calculations that keep track
of that might overflow, in the function scale_freq_tick():
if (check_shl_overflow(acnt, 2*SCHED_CAPACITY_SHIFT, &acnt))
goto error;
eventually forcing the kernel to disable the feature for all CPUs,
and show the warning message:
"Scheduler frequency invariance went wobbly, disabling!".
Let's avoid that by limiting the frequency invariant calculations
to CPUs with regular tick.
Fixes: e2b0d61 ("x86, sched: check for counters overflow in frequency invariant accounting")
Suggested-by: "Peter Zijlstra (Intel)" <[email protected]>
Signed-off-by: Yair Podemsky <[email protected]>
Signed-off-by: Ingo Molnar <[email protected]>
Reviewed-by: Valentin Schneider <[email protected]>
Acked-by: Giovanni Gherdovich <[email protected]>
Link: https://lore.kernel.org/r/[email protected]1 parent 0a71553 commit 7fb3ff2
1 file changed
+3
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5504 | 5504 | | |
5505 | 5505 | | |
5506 | 5506 | | |
5507 | | - | |
| 5507 | + | |
| 5508 | + | |
| 5509 | + | |
5508 | 5510 | | |
5509 | 5511 | | |
5510 | 5512 | | |
| |||
0 commit comments