Merge tag 'for-5.1-rc2-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave...
[sfrench/cifs-2.6.git] / Documentation / devicetree / bindings / hwmon / pwm-fan.txt
1 Bindings for a fan connected to the PWM lines
2
3 Required properties:
4 - compatible    : "pwm-fan"
5 - pwms          : the PWM that is used to control the PWM fan
6 - cooling-levels      : PWM duty cycle values in a range from 0 to 255
7                         which correspond to thermal cooling states
8
9 Optional properties:
10 - fan-supply    : phandle to the regulator that provides power to the fan
11
12 Example:
13         fan0: pwm-fan {
14                 compatible = "pwm-fan";
15                 cooling-min-state = <0>;
16                 cooling-max-state = <3>;
17                 #cooling-cells = <2>;
18                 pwms = <&pwm 0 10000 0>;
19                 cooling-levels = <0 102 170 230>;
20         };
21
22         thermal-zones {
23                 cpu_thermal: cpu-thermal {
24                              thermal-sensors = <&tmu 0>;
25                              polling-delay-passive = <0>;
26                              polling-delay = <0>;
27                              trips {
28                                         cpu_alert1: cpu-alert1 {
29                                                     temperature = <100000>; /* millicelsius */
30                                                     hysteresis = <2000>; /* millicelsius */
31                                                     type = "passive";
32                                         };
33                              };
34                              cooling-maps {
35                                         map0 {
36                                                     trip = <&cpu_alert1>;
37                                                     cooling-device = <&fan0 0 1>;
38                                         };
39                              };
40                 };