summaryrefslogtreecommitdiffstats
path: root/drivers/thermal/step_wise.c
Commit message (Collapse)AuthorAgeFilesLines
* Thermal: build thermal governors into thermal_sys moduleZhang Rui2013-04-141-14/+2
| | | | | | | | | | | | | | | | | The thermal governors are part of the thermal framework, rather than a seperate feature/module. Because the generic thermal layer can not work without thermal governors, and it must load the thermal governors during its initialization. Build them into one module in this patch. This also fix a problem that the generic thermal layer does not work when CONFIG_THERMAL=m and CONFIG_THERMAL_GOV_XXX=y. Signed-off-by: Zhang Rui <rui.zhang@intel.com> Acked-by: Eduardo Valentin <eduardo.valentin@ti.com> Acked-by: Durgadoss R <durgadoss.r@intel.com>
* thermal: step_wise: set throttle target within thermal instance limitsAndrew Bresticker2013-04-121-2/+8
| | | | | | | | | | | | | | | | | When selecting a target cooling state in get_target_state(), make sure that the state is at least as high as the minimum when the temperature is rising and at least as low as the maximum when the temperature is falling. This is necessary because, in the THREAML_TREND_RAISING and THERMAL_TREND_DROPPING cases, the current state may only be incremented or decremented by one even if it is outside the bounds of the thermal instance. This might occur, for example, if the CPU is heating up and hits a thermal trip point for the first time when it's frequency is much higher than the range specified by the thermal instance corresponding to the trip point. Signed-off-by: Andrew Bresticker <abrestic@chromium.org> Acked-by: Eduardo Valentin <eduardo.valentin@ti.com> Signed-off-by: Zhang Rui <rui.zhang@intel.com>
* step_wise: Unify the code for both throttle and dethrottleZhang Rui2013-01-041-45/+25
| | | | Signed-off-by: Zhang Rui <rui.zhang@intel.com>
* Introduce THERMAL_TREND_RAISE/DROP_FULL support for step_wise governorZhang Rui2013-01-041-18/+46
| | | | | | | step_wise governor should set the device cooling state to upper/lower limit directly when THERMAL_TREND_RAISE/DROP_FULL. Signed-off-by: Zhang Rui <rui.zhang@intel.com>
* Thermal: Fix DEFAULT_THERMAL_GOVERNORZhang Rui2012-12-121-1/+1
| | | | | | | Fix DEFAULT_THERMAL_GOVERNOR to be consistant with the default governor selected in kernel config file. Signed-off-by: Zhang Rui <rui.zhang@intel.com>
* thermal: step_wise: Add missing static storage class specifiersSachin Kamat2012-11-051-2/+2
| | | | | | | | | | | | Fixes the following sparse warnings: drivers/thermal/step_wise.c:153:5: warning: symbol 'step_wise_throttle' was not declared. Should it be static? drivers/thermal/step_wise.c:172:25: warning: symbol 'thermal_gov_step_wise' was not declared. Should it be static? Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Acked-by: Durgadoss R <durgadoss.r@intel.com> Signed-off-by: Zhang Rui <rui.zhang@intel.com>
* Thermal: Introduce a step_wise thermal governorDurgadoss R2012-11-051-0/+194
This patch adds a simple step_wise governor to the generic thermal layer. This algorithm throttles the cooling devices in a linear fashion. If the 'trend' is heating, it throttles by one step. And if the thermal trend is cooling it de-throttles by one step. This actually moves the throttling logic from thermal_sys.c and puts inside step_wise.c, without any change. Signed-off-by: Durgadoss R <durgadoss.r@intel.com> Signed-off-by: Zhang Rui <rui.zhang@intel.com>
OpenPOWER on IntegriCloud