|
8 | 8 | #include <dt-bindings/clock/starfive,jh7110-crg.h> |
9 | 9 | #include <dt-bindings/power/starfive,jh7110-pmu.h> |
10 | 10 | #include <dt-bindings/reset/starfive,jh7110-crg.h> |
| 11 | +#include <dt-bindings/thermal/thermal.h> |
11 | 12 |
|
12 | 13 | / { |
13 | 14 | compatible = "starfive,jh7110"; |
|
57 | 58 | operating-points-v2 = <&cpu_opp>; |
58 | 59 | clocks = <&syscrg JH7110_SYSCLK_CPU_CORE>; |
59 | 60 | clock-names = "cpu"; |
| 61 | + #cooling-cells = <2>; |
60 | 62 |
|
61 | 63 | cpu1_intc: interrupt-controller { |
62 | 64 | compatible = "riscv,cpu-intc"; |
|
86 | 88 | operating-points-v2 = <&cpu_opp>; |
87 | 89 | clocks = <&syscrg JH7110_SYSCLK_CPU_CORE>; |
88 | 90 | clock-names = "cpu"; |
| 91 | + #cooling-cells = <2>; |
89 | 92 |
|
90 | 93 | cpu2_intc: interrupt-controller { |
91 | 94 | compatible = "riscv,cpu-intc"; |
|
115 | 118 | operating-points-v2 = <&cpu_opp>; |
116 | 119 | clocks = <&syscrg JH7110_SYSCLK_CPU_CORE>; |
117 | 120 | clock-names = "cpu"; |
| 121 | + #cooling-cells = <2>; |
118 | 122 |
|
119 | 123 | cpu3_intc: interrupt-controller { |
120 | 124 | compatible = "riscv,cpu-intc"; |
|
144 | 148 | operating-points-v2 = <&cpu_opp>; |
145 | 149 | clocks = <&syscrg JH7110_SYSCLK_CPU_CORE>; |
146 | 150 | clock-names = "cpu"; |
| 151 | + #cooling-cells = <2>; |
147 | 152 |
|
148 | 153 | cpu4_intc: interrupt-controller { |
149 | 154 | compatible = "riscv,cpu-intc"; |
|
198 | 203 | }; |
199 | 204 | }; |
200 | 205 |
|
| 206 | + thermal-zones { |
| 207 | + cpu-thermal { |
| 208 | + polling-delay-passive = <250>; |
| 209 | + polling-delay = <15000>; |
| 210 | + |
| 211 | + thermal-sensors = <&sfctemp>; |
| 212 | + |
| 213 | + cooling-maps { |
| 214 | + map0 { |
| 215 | + trip = <&cpu_alert0>; |
| 216 | + cooling-device = |
| 217 | + <&U74_1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, |
| 218 | + <&U74_2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, |
| 219 | + <&U74_3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, |
| 220 | + <&U74_4 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; |
| 221 | + }; |
| 222 | + }; |
| 223 | + |
| 224 | + trips { |
| 225 | + cpu_alert0: cpu_alert0 { |
| 226 | + /* milliCelsius */ |
| 227 | + temperature = <85000>; |
| 228 | + hysteresis = <2000>; |
| 229 | + type = "passive"; |
| 230 | + }; |
| 231 | + |
| 232 | + cpu_crit { |
| 233 | + /* milliCelsius */ |
| 234 | + temperature = <100000>; |
| 235 | + hysteresis = <2000>; |
| 236 | + type = "critical"; |
| 237 | + }; |
| 238 | + }; |
| 239 | + }; |
| 240 | + }; |
| 241 | + |
201 | 242 | dvp_clk: dvp-clock { |
202 | 243 | compatible = "fixed-clock"; |
203 | 244 | clock-output-names = "dvp_clk"; |
204 | 245 | #clock-cells = <0>; |
205 | 246 | }; |
206 | | - |
207 | 247 | gmac0_rgmii_rxin: gmac0-rgmii-rxin-clock { |
208 | 248 | compatible = "fixed-clock"; |
209 | 249 | clock-output-names = "gmac0_rgmii_rxin"; |
|
517 | 557 | status = "disabled"; |
518 | 558 | }; |
519 | 559 |
|
| 560 | + sfctemp: temperature-sensor@120e0000 { |
| 561 | + compatible = "starfive,jh7110-temp"; |
| 562 | + reg = <0x0 0x120e0000 0x0 0x10000>; |
| 563 | + clocks = <&syscrg JH7110_SYSCLK_TEMP_CORE>, |
| 564 | + <&syscrg JH7110_SYSCLK_TEMP_APB>; |
| 565 | + clock-names = "sense", "bus"; |
| 566 | + resets = <&syscrg JH7110_SYSRST_TEMP_CORE>, |
| 567 | + <&syscrg JH7110_SYSRST_TEMP_APB>; |
| 568 | + reset-names = "sense", "bus"; |
| 569 | + #thermal-sensor-cells = <0>; |
| 570 | + }; |
| 571 | + |
520 | 572 | syscrg: clock-controller@13020000 { |
521 | 573 | compatible = "starfive,jh7110-syscrg"; |
522 | 574 | reg = <0x0 0x13020000 0x0 0x10000>; |
|
0 commit comments