BACKPORT: UPSTREAM: PM / OPP: Update performance state when freq == old_freq
At boot up, CPUfreq core performs a sanity check to see if the system is running at a frequency defined in the frequency table of the CPU. If so, we try to find a valid frequency (lowest frequency greater than the currently programmed frequency) from the table and set it. When the call reaches dev_pm_opp_set_rate(), it calls _find_freq_ceil(opp_table, &old_freq) to find the previously configured OPP and this call also updates the old_freq. This eventually sets the old_freq == freq (new target requested by cpufreq core) and we skip updating the performance state in this case. Fix this by also updating the performance state when the old_freq == freq. Fixes: ca1b5d77 ("OPP: Configure all required OPPs") Cc: v5.0 <stable@vger.kernel.org> # v5.0 Reported-by:Niklas Cassel <niklas.cassel@linaro.org> Signed-off-by:
Viresh Kumar <viresh.kumar@linaro.org> (cherry picked from commit faef080f https://github.com/torvalds/linux.git ) Signed-off-by:
Niklas Cassel <niklas.cassel@linaro.org> BUG=b:129558664 TEST=Validate DVFS and schedutil governor Git-repo: https://git.linaro.org/people/niklas.cassel/kernel.git Git-commit: 616d16e1267abb4818072d1462167d3d0fe081ad Signed-off-by:
Praveen Koya <pkoya@codeaurora.org> Change-Id: I743fdbe648106dd7af9d6e1e0c74a90f549f7ea1 Signed-off-by:
Vamsi Singamsetty <vamssi@codeaurora.org> Signed-off-by:
Khasim Syed Mohammed <khasim.mohammed@linaro.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/kernel/+/1664357 Reviewed-by:
Zhihong Yu <zhihongyu@chromium.org> Commit-Queue: Zhihong Yu <zhihongyu@chromium.org> Tested-by:
Zhihong Yu <zhihongyu@chromium.org>
Loading
Please sign in to comment