UPSTREAM: cpufreq: kryo: Release OPP tables on module removal
Commit 5ad7346b ("cpufreq: kryo: Add module remove and exit") made it possible to build the kryo cpufreq driver as a module, but it failed to release all the resources, i.e. OPP tables, when the module is unloaded. This patch fixes it by releasing the OPP tables, by calling dev_pm_opp_put_supported_hw() for them, from the qcom_cpufreq_kryo_remove() routine. The array of pointers to the OPP tables is also allocated dynamically now in qcom_cpufreq_kryo_probe(), as the pointers will be required while releasing the resources. Compile tested only. Cc: 4.18+ <stable@vger.kernel.org> # v4.18+ Fixes: 5ad7346b ("cpufreq: kryo: Add module remove and exit") Reviewed-by:Georgi Djakov <georgi.djakov@linaro.org> Signed-off-by:
Viresh Kumar <viresh.kumar@linaro.org> (cherry picked from commit 0334906c 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: 19b6e0e26260a8fe2d670fae38c827e3f317b319 Signed-off-by:
Praveen Koya <pkoya@codeaurora.org> Change-Id: I2c8adab0cf0db9a2c078574d6b695b840c0728d3 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/+/1664370 Reviewed-by:
Zhihong Yu <zhihongyu@chromium.org> Reviewed-by:
Sean Paul <seanpaul@chromium.org> Commit-Queue: Zhihong Yu <zhihongyu@chromium.org> Tested-by:
Zhihong Yu <zhihongyu@chromium.org>
Loading
Please sign in to comment