aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/hwmon/pwm-fan.c
Commit message (Collapse)AuthorAgeFilesLines
...
* hwmon: (pwm-fan) Declare pwm_fan_of_get_cooling_data staticGuenter Roeck2015-03-091-1/+2
| | | | | | | | | | | | | | | | Address the following sparse warnings. drivers/hwmon/pwm-fan.c:176:5: warning: symbol 'pwm_fan_of_get_cooling_data' was not declared. Should it be static? drivers/hwmon/pwm-fan.c:176:5: warning: no previous prototype for 'pwm_fan_of_get_cooling_data' pwm_fan_of_get_cooling_data is only used in the pwm-fan driver and thus should be declared static. Cc: Lukasz Majewski <[email protected]> Acked-by: Lukasz Majewski <[email protected]> Signed-off-by: Guenter Roeck <[email protected]>
* hwmon: (pwm-fan) Add support for using PWM FAN as a cooling deviceLukasz Majewski2015-03-091-1/+88
| | | | | | | | The PWM FAN device can now be used as a thermal cooling device. Signed-off-by: Lukasz Majewski <[email protected]> Acked-by: Eduardo Valentin <[email protected]> Signed-off-by: Guenter Roeck <[email protected]>
* hwmon: (pwm-fan) Read PWM FAN configuration from device treeLukasz Majewski2015-03-091-1/+49
| | | | | | | | | | | This patch provides code for reading PWM FAN configuration data via device tree. The pwm-fan can work with full speed when configuration is not provided. However, errors are propagated when wrong DT bindings are found. Additionally the struct pwm_fan_ctx has been extended. Signed-off-by: Lukasz Majewski <[email protected]> Signed-off-by: Guenter Roeck <[email protected]>
* hwmon: (pwm-fan) Extract __set_pwm() function to only modify PWM duty cycleLukasz Majewski2015-03-091-12/+21
| | | | | | | | | | It was necessary to decouple code handling writing to sysfs from the one responsible for setting PWM of the fan. Due to that, new __set_pwm() method was extracted, which is responsible for only setting new PWM duty cycle. Signed-off-by: Lukasz Majewski <[email protected]> Signed-off-by: Guenter Roeck <[email protected]>
* hwmon: (pwm-fan) Fix suspend/resume behaviorKamil Debski2014-11-111-3/+10
| | | | | | | | | The state of a PWM output is not clearly defined after resume. Some PWM drivers do not restore the duty cycle upon resume, thus it is necessary to manually restore the correct value. Signed-off-by: Kamil Debski <[email protected]> Signed-off-by: Guenter Roeck <[email protected]>
* hwmon: (pwm-fan) Remove duplicate dev_set_drvdata callAxel Lin2014-08-041-1/+0
| | | | | | | | The dev_set_drvdata() call is equivalent to the platform_set_drvdata() call in next line. Signed-off-by: Axel Lin <[email protected]> Signed-off-by: Guenter Roeck <[email protected]>
* hwmon: Add pwm-fan driverKamil Debski2014-08-041-0/+194
The pwm-fan driver enables control of fans connected to PWM lines. This driver uses the PWM framework, so it is compatible with all PWM devices that provide drivers through the PWM framework. Signed-off-by: Kamil Debski <[email protected]> Reviewed-by: Varka Bhadram <[email protected]> Reviewed-by: Tobias Klauser <[email protected]> [Guenter Roeck: Last argument to devm_of_pwm_get is pointer, use NULL] Signed-off-by: Guenter Roeck <[email protected]>