mirror of
https://github.com/torvalds/linux.git
synced 2024-11-25 21:51:40 +00:00
Thermal control fix for 6.10-rc6
Replace an earlier fix for a recent regression in the Step-Wise thermal governor that was not effective in all of the relevant cases (Rafael Wysocki). -----BEGIN PGP SIGNATURE----- iQJGBAABCAAwFiEE4fcc61cGeeHD/fCwgsRv/nhiVHEFAmZ9uGMSHHJqd0Byand5 c29ja2kubmV0AAoJEILEb/54YlRxA1sP/2P0PACGXLzhlnKNvTaDL6DieqI310sH u/wkuVBWY84xcNnfRwn+xlh0vWLczDX5VDBh9LUtOYfl+jaJSt6mtRT53Nd2V7Ko 2HqdsYkBjAPemXu5Vy2fwm24KtdgkZBldDDgk6vM3u4eqNw1YOMOT+Ayv+LdS9FP ZeEwHwciEb6r/I9+/Ll9V4tOOGl4JH5+Q9DT5PoWB0COtqbpHPaVogVf3QathMqY HZyS4DfJogz17rdTMN8e/9kigVGxaUFXyahFK0J25XnWzHxve2di6NGKqmnP246V u9iZIELkfD6x0KkijZUf1FueQFXjFq0zHyd1CrtZMIP5doLJlaRUy+fjsc1nLxdd 5FC5HoDn5Dr51WhaE9JbUAyVxhaE5cW+npH7AkgCTYwY4/Zr3IZvRbuvXNEfCZ+1 6dJKLSEKnXbZEC43IrTt5o0kvqSXSwZEp8wLiO1rphtvZULgJkLu87RB93VpkqiL LfXw9Y7MofYItsuIe/hCD8eqe2WAw7WaXJk+YnZptvF9+B5HoOGWWNjvLL7iXZ8w qAjEDemzvIpjMLCDsiSVtfOoMwh/GQghwpJ9QISnjIES8qUQI3oV2ZGgtGpfUaSU z35uDDsQ4tajUNzNsp9WbUXzDJp+32iZOfHmH4c6ozbEu/3VNd8/plU2NqMTAGEC AgAoTJbnSega =FcvI -----END PGP SIGNATURE----- Merge tag 'thermal-6.10-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull thermal control fix from Rafael Wysocki: "Replace an earlier fix for a recent regression in the Step-Wise thermal governor that was not effective in all of the relevant cases (Rafael Wysocki)" * tag 'thermal-6.10-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: thermal: gov_step_wise: Go straight to instance->lower when mitigation is over
This commit is contained in:
commit
92572d2c08
@ -55,7 +55,11 @@ static unsigned long get_target_state(struct thermal_instance *instance,
|
||||
if (cur_state <= instance->lower)
|
||||
return THERMAL_NO_TARGET;
|
||||
|
||||
return clamp(cur_state - 1, instance->lower, instance->upper);
|
||||
/*
|
||||
* If 'throttle' is false, no mitigation is necessary, so
|
||||
* request the lower state for this instance.
|
||||
*/
|
||||
return instance->lower;
|
||||
}
|
||||
|
||||
return instance->target;
|
||||
@ -93,23 +97,6 @@ static void thermal_zone_trip_update(struct thermal_zone_device *tz,
|
||||
if (instance->initialized && old_target == instance->target)
|
||||
continue;
|
||||
|
||||
if (trip->type == THERMAL_TRIP_PASSIVE) {
|
||||
/*
|
||||
* If the target state for this thermal instance
|
||||
* changes from THERMAL_NO_TARGET to something else,
|
||||
* ensure that the zone temperature will be updated
|
||||
* (assuming enabled passive cooling) until it becomes
|
||||
* THERMAL_NO_TARGET again, or the cooling device may
|
||||
* not be reset to its initial state.
|
||||
*/
|
||||
if (old_target == THERMAL_NO_TARGET &&
|
||||
instance->target != THERMAL_NO_TARGET)
|
||||
tz->passive++;
|
||||
else if (old_target != THERMAL_NO_TARGET &&
|
||||
instance->target == THERMAL_NO_TARGET)
|
||||
tz->passive--;
|
||||
}
|
||||
|
||||
instance->initialized = true;
|
||||
|
||||
mutex_lock(&instance->cdev->lock);
|
||||
|
Loading…
Reference in New Issue
Block a user