Skip to content

Commit cce7480

Browse files
committed
arm64: dts: allwinner: h616: add CPU idle states and thermal idle devices
Injecting idle has much greater effect on CPU power consumption than just lowering frequency under a constant 100% load. Thus, it's very useful for thermal throttling near critically high temperatures. Users are expected to explicitly reference thermal idle states in their cooling maps.
1 parent 0ba5a64 commit cce7480

File tree

1 file changed

+41
-0
lines changed

1 file changed

+41
-0
lines changed

arch/arm64/boot/dts/allwinner/sun50i-h616.dtsi

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,14 @@
2727
enable-method = "psci";
2828
clocks = <&ccu CLK_CPUX>;
2929
#cooling-cells = <2>;
30+
cpu-idle-states = <&CPU_SLEEP>;
31+
dynamic-power-coefficient = <100>;
32+
33+
cpu0idle: thermal-idle {
34+
#cooling-cells = <2>;
35+
duration-us = <10000>;
36+
exit-latency-us = <500>;
37+
};
3038
};
3139

3240
cpu1: cpu@1 {
@@ -36,6 +44,13 @@
3644
enable-method = "psci";
3745
clocks = <&ccu CLK_CPUX>;
3846
#cooling-cells = <2>;
47+
cpu-idle-states = <&CPU_SLEEP>;
48+
49+
cpu1idle: thermal-idle {
50+
#cooling-cells = <2>;
51+
duration-us = <10000>;
52+
exit-latency-us = <500>;
53+
};
3954
};
4055

4156
cpu2: cpu@2 {
@@ -45,6 +60,13 @@
4560
enable-method = "psci";
4661
clocks = <&ccu CLK_CPUX>;
4762
#cooling-cells = <2>;
63+
cpu-idle-states = <&CPU_SLEEP>;
64+
65+
cpu2idle: thermal-idle {
66+
#cooling-cells = <2>;
67+
duration-us = <10000>;
68+
exit-latency-us = <500>;
69+
};
4870
};
4971

5072
cpu3: cpu@3 {
@@ -54,6 +76,25 @@
5476
enable-method = "psci";
5577
clocks = <&ccu CLK_CPUX>;
5678
#cooling-cells = <2>;
79+
cpu-idle-states = <&CPU_SLEEP>;
80+
81+
cpu3idle: thermal-idle {
82+
#cooling-cells = <2>;
83+
duration-us = <10000>;
84+
exit-latency-us = <500>;
85+
};
86+
};
87+
idle-states {
88+
entry-method = "psci";
89+
90+
CPU_SLEEP: cpu-sleep {
91+
compatible = "arm,idle-state";
92+
local-timer-stop;
93+
arm,psci-suspend-param = <0x0010000>;
94+
entry-latency-us = <120>;
95+
exit-latency-us = <250>;
96+
min-residency-us = <900>;
97+
};
5798
};
5899
};
59100

0 commit comments

Comments
 (0)