diff options
| author | liwei <[email protected]> | 2024-10-24 02:29:52 +0000 |
|---|---|---|
| committer | Rafael J. Wysocki <[email protected]> | 2024-10-24 15:35:13 +0000 |
| commit | d93df29bdab133b85e94b3c328e7fe26a0ebd56c (patch) | |
| tree | bfea9ff046a4a1ee91d1303b156b772f53849fd9 /rust/helpers/bug.c | |
| parent | cpufreq: docs: Reflect latency changes in docs (diff) | |
| download | kernel-d93df29bdab133b85e94b3c328e7fe26a0ebd56c.tar.gz kernel-d93df29bdab133b85e94b3c328e7fe26a0ebd56c.zip | |
cpufreq: CPPC: fix perf_to_khz/khz_to_perf conversion exception
When the nominal_freq recorded by the kernel is equal to the lowest_freq,
and the frequency adjustment operation is triggered externally, there is
a logic error in cppc_perf_to_khz()/cppc_khz_to_perf(), resulting in perf
and khz conversion errors.
Fix this by adding a branch processing logic when nominal_freq is equal
to lowest_freq.
Fixes: ec1c7ad47664 ("cpufreq: CPPC: Fix performance/frequency conversion")
Signed-off-by: liwei <[email protected]>
Acked-by: Viresh Kumar <[email protected]>
Link: https://patch.msgid.link/[email protected]
[ rjw: Subject and changelog edits ]
Signed-off-by: Rafael J. Wysocki <[email protected]>
Diffstat (limited to 'rust/helpers/bug.c')
0 files changed, 0 insertions, 0 deletions
