thermal: gov_step_wise: Use trip thresholds instead of trip temperatures
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 10 Apr 2024 16:43:07 +0000 (18:43 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 24 Apr 2024 08:14:33 +0000 (10:14 +0200)
commite4065f144fa60df56a8596bdc364a5b4fe8cbf40
tree58648d48999a1c8c6cca3007ed32886b21f0398a
parenta6ce8c7da59bbdafcab23b5d26f26865af77a5fa
thermal: gov_step_wise: Use trip thresholds instead of trip temperatures

In principle, the Step-Wise governor should take trip hysteresis into
account.  After all, once a trip has been crossed on the way up,
mitigation is still needed until it is crossed on the way down.

For this reason, make it use trip thresholds that are computed by
the core when trips are crossed, so as to apply mitigations in the
hysteresis rages of trips that were crossed on the way up, but have
not been crossed on the way down yet.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Reviewed-by: Lukasz Luba <lukasz.luba@arm.com>
Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org>
drivers/thermal/gov_step_wise.c