commit | 4511f7166a2deb5f7a578cf87fd2fe1ae83527e3 | [log] [tgz] |
---|---|---|
author | Chen Yu <[email protected]> | Fri Oct 30 16:32:10 2015 +0800 |
committer | Zhang Rui <[email protected]> | Tue Dec 29 16:00:00 2015 +0800 |
tree | 27511588f566ac27bbc92ce8bb4b676cbcf7d4a5 | |
parent | ff140fea847e1c2002a220571ab106c2456ed252 [diff] [blame] |
Thermal: do thermal zone update after a cooling device registered When a new cooling device is registered, we need to update the thermal zone to set the new registered cooling device to a proper state. This fixes a problem that the system is cool, while the fan devices are left running on full speed after boot, if fan device is registered after thermal zone device. Here is the history of why current patch looks like this: https://patchwork.kernel.org/patch/7273041/ CC: <[email protected]> #3.18+ Reference:https://bugzilla.kernel.org/show_bug.cgi?id=92431 Tested-by: Manuel Krause <[email protected]> Tested-by: szegad <[email protected]> Tested-by: prash <[email protected]> Tested-by: amish <[email protected]> Reviewed-by: Javi Merino <[email protected]> Signed-off-by: Zhang Rui <[email protected]> Signed-off-by: Chen Yu <[email protected]>
diff --git a/include/linux/thermal.h b/include/linux/thermal.h index 103fcbe6..e13a1ac 100644 --- a/include/linux/thermal.h +++ b/include/linux/thermal.h
@@ -170,6 +170,7 @@ * @forced_passive: If > 0, temperature at which to switch on all ACPI * processor cooling devices. Currently only used by the * step-wise governor. + * @need_update: if equals 1, thermal_zone_device_update needs to be invoked. * @ops: operations this &thermal_zone_device supports * @tzp: thermal zone parameters * @governor: pointer to the governor for this thermal zone @@ -197,6 +198,7 @@ int emul_temperature; int passive; unsigned int forced_passive; + atomic_t need_update; struct thermal_zone_device_ops *ops; struct thermal_zone_params *tzp; struct thermal_governor *governor;