Re: [PATCH V3] thermal/core/power_allocator: avoid thermal cdev can not be reset

From: Daniel Lezcano
Date: Fri Apr 14 2023 - 07:12:27 EST


On 13/04/2023 10:40, Di Shen wrote:
We have discussed this question in patch-v1:
https://lore.kernel.org/all/f6aaa5f1-495d-a158-14d8-ddb2bffbd9c2@xxxxxxx/

Simply put, we use the trip_temp in the Android System; set different
trip_temp for thermal control of different scenarios.

The changes are dealing with the trip points and trying to detect the threshold. That part should be handled in the thermal core or thermal trip side, not in the governor.

AFAICT, if a trip point is changed, then the power allocator should be reset, including the cdev state.

It would be more convenient to add an ops to the governor ops structure to reset the governor and then call it when a trip point is changed in thermal_zone_set_trip()


--
<http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs

Follow Linaro: <http://www.facebook.com/pages/Linaro> Facebook |
<http://twitter.com/#!/linaroorg> Twitter |
<http://www.linaro.org/linaro-blog/> Blog