walnux/drivers/thermal
wangjianyu3 0e71a944b9 drivers/thermal: Update state when temp is stable
Fix cooling state not decreasing error when the temperature is kept at low trip(stable, not dropping).

Test on "sim:thermal", log is from /proc/thermal/cpu-thermal and see thermal/thermal_dummy.c for trip point details.

e.g. The temperature decreasing from 71 to 65 and then kept.
       z:cpu-thermal t:71 t:1 h:16 l:0 c:fan0 s:16|16

     a. Without this patch, the cooling state of "fan0" will be kept at 15, even if the temperature is at a lower trip:
       z:cpu-thermal t:65 t:1 h:16 l:0 c:fan0 s:15|15
       ... ...
       z:cpu-thermal t:65 t:1 h:16 l:0 c:fan0 s:15|15

     b. With this patch, the cooling state of "fan0" was continually decreasing to zero according to current trip point:
       z:cpu-thermal t:65 t:1 h:16 l:0 c:fan0 s:15|15
       ... ...
       z:cpu-thermal t:65 t:1 h:16 l:0 c:fan0 s:0|0

Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
2025-03-17 09:21:52 +08:00
..
CMakeLists.txt drivers: migrate to SPDX identifier 2024-11-06 18:02:25 +08:00
Kconfig Thermal: The thermal core depends on LPWORK 2024-12-26 09:23:10 +08:00
Make.defs drivers: migrate to SPDX identifier 2024-11-06 18:02:25 +08:00
thermal_core.c drivers/thermal: Fix work not queued after getting temperature fails 2025-02-22 07:56:21 -03:00
thermal_core.h drivers: migrate to SPDX identifier 2024-11-06 18:02:25 +08:00
thermal_cpufreq_cooling.c drivers: migrate to SPDX identifier 2024-11-06 18:02:25 +08:00
thermal_dummy.c drivers/thermal/dummy: Add another passive cooling device 2025-02-16 11:22:41 -03:00
thermal_procfs.c Thermal/procfs: Do not print invalid target cooling state directly 2024-12-26 09:23:10 +08:00
thermal_step_wise.c drivers/thermal: Update state when temp is stable 2025-03-17 09:21:52 +08:00