GNU Linux-libre 4.19.264-gnu1
[releases.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 Example:
10         fan0: pwm-fan {
11                 compatible = "pwm-fan";
12                 cooling-min-state = <0>;
13                 cooling-max-state = <3>;
14                 #cooling-cells = <2>;
15                 pwms = <&pwm 0 10000 0>;
16                 cooling-levels = <0 102 170 230>;
17         };
18
19         thermal-zones {
20                 cpu_thermal: cpu-thermal {
21                              thermal-sensors = <&tmu 0>;
22                              polling-delay-passive = <0>;
23                              polling-delay = <0>;
24                              trips {
25                                         cpu_alert1: cpu-alert1 {
26                                                     temperature = <100000>; /* millicelsius */
27                                                     hysteresis = <2000>; /* millicelsius */
28                                                     type = "passive";
29                                         };
30                              };
31                              cooling-maps {
32                                         map0 {
33                                                     trip = <&cpu_alert1>;
34                                                     cooling-device = <&fan0 0 1>;
35                                         };
36                              };
37                 };