ARM: dts: rockchip: rk322x: update thermal config and add cpu's parameters
authorRocky Hao <rocky.hao@rock-chips.com>
Tue, 16 May 2017 03:07:06 +0000 (11:07 +0800)
committerHuang, Tao <huangtao@rock-chips.com>
Wed, 5 Jul 2017 06:08:58 +0000 (14:08 +0800)
add cpu's dynamic power coefficient and add gpu as a cooling device in the
thermal zone. rename the thermal zone's config and make it more readable.

Change-Id: Iac935a6dde5e079667b6712224b32e786ccebc1e
Signed-off-by: Rocky Hao <rocky.hao@rock-chips.com>
arch/arm/boot/dts/rk322x.dtsi

index 128b9186ef596657092206f87163a784eb4f61f3..d526760370bf790d17fb55b0c740079cd5d4f3c6 100644 (file)
@@ -67,6 +67,7 @@
                        resets = <&cru SRST_CORE0>;
                        operating-points-v2 = <&cpu0_opp_table>;
                        #cooling-cells = <2>; /* min followed by max */
+                       dynamic-power-coefficient = <122>;
                        clock-latency = <40000>;
                        clocks = <&cru ARMCLK>;
                };
                        <75000000>;
        };
 
-       thermal-zones {
-               cpu_thermal: cpu-thermal {
+       thermal_zones: thermal-zones {
+               soc_thermal: soc-thermal {
                        polling-delay-passive = <100>; /* milliseconds */
                        polling-delay = <5000>; /* milliseconds */
+                       sustainable-power = <1200>; /* milliwatts */
 
                        thermal-sensors = <&tsadc 0>;
 
                        trips {
-                               cpu_alert0: cpu_alert0 {
+                               threshold: trip-point@0 {
                                        temperature = <70000>; /* millicelsius */
                                        hysteresis = <2000>; /* millicelsius */
                                        type = "passive";
                                };
-                               cpu_alert1: cpu_alert1 {
-                                       temperature = <75000>; /* millicelsius */
+                               target: trip-point@1 {
+                                       temperature = <85000>; /* millicelsius */
                                        hysteresis = <2000>; /* millicelsius */
                                        type = "passive";
                                };
-                               cpu_crit: cpu_crit {
+                               soc_crit: soc-crit {
                                        temperature = <90000>; /* millicelsius */
                                        hysteresis = <2000>; /* millicelsius */
                                        type = "critical";
 
                        cooling-maps {
                                map0 {
-                                       trip = <&cpu_alert0>;
+                                       trip = <&target>;
                                        cooling-device =
-                                               <&cpu0 THERMAL_NO_LIMIT 6>;
+                                       <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+                                       contribution = <1024>;
                                };
                                map1 {
-                                       trip = <&cpu_alert1>;
+                                       trip = <&target>;
                                        cooling-device =
-                                               <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+                                       <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+                                       contribution = <1024>;
                                };
                        };
                };
                                  "Mali_PP1_IRQ",
                                  "Mali_PP1_MMU_IRQ";
                clocks = <&cru ACLK_GPU>;
+               #cooling-cells = <2>; /* min followed by max */
                clock-names = "clk_mali";
                operating-points-v2 = <&gpu_opp_table>;
                status = "disabled";