arm64: dts: rockchip: Add all CPUs in cooling maps
authorViresh Kumar <viresh.kumar@linaro.org>
Fri, 16 Nov 2018 10:04:32 +0000 (15:34 +0530)
committerHeiko Stuebner <heiko@sntech.de>
Mon, 19 Nov 2018 13:45:35 +0000 (14:45 +0100)
Each CPU can (and does) participate in cooling down the system but the
DT only captures a handful of them, normally CPU0, in the cooling maps.
Things work by chance currently as under normal circumstances its the
first CPU of each cluster which is used by the operating systems to
probe the cooling devices. But as soon as this CPU ordering changes and
any other CPU is used to bring up the cooling device, we will start
seeing failures.

Also the DT is rather incomplete when we list only one CPU in the
cooling maps, as the hardware doesn't have any such limitations.

Update cooling maps to include all devices affected by individual trip
points.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
arch/arm64/boot/dts/rockchip/rk3328.dtsi
arch/arm64/boot/dts/rockchip/rk3368.dtsi
arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts
arch/arm64/boot/dts/rockchip/rk3399.dtsi

index e1a33dd981e0d2c1f93c0e333de0910fdbcb4fdd..ecd7f19c3542f740c45f5d3f4c05b314684361e1 100644 (file)
                        cooling-maps {
                                map0 {
                                        trip = <&target>;
-                                       cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+                                       cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                                        <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                                        <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                                        <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
                                        contribution = <4096>;
                                };
                        };
index 9c24de1ba43c56b70d0a29d063ec78324a764340..7014d10b954cf121632868f73d67d26afcd55c5d 100644 (file)
                                map0 {
                                        trip = <&cpu_alert0>;
                                        cooling-device =
-                                       <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+                                       <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                       <&cpu_b1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                       <&cpu_b2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                       <&cpu_b3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
                                };
                                map1 {
                                        trip = <&cpu_alert1>;
                                        cooling-device =
-                                       <&cpu_l0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+                                       <&cpu_l0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                       <&cpu_l1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                       <&cpu_l2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                       <&cpu_l3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
                                };
                        };
                };
                                map0 {
                                        trip = <&gpu_alert0>;
                                        cooling-device =
-                                       <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+                                       <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                       <&cpu_b1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                       <&cpu_b2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                       <&cpu_b3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
                                };
                        };
                };
index 2cc7c47d6a85d79312a519dd0a0c02964f9223ff..81e73103fa788605471679fd1b0868f50822c4f8 100644 (file)
                        map0 {
                                trip = <&ppvar_bigcpu_alert>;
                                cooling-device =
-                                       <&cpu_l0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+                                       <&cpu_l0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                       <&cpu_l1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                       <&cpu_l2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                       <&cpu_l3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
                                contribution = <4096>;
                        };
                        map1 {
                                trip = <&ppvar_bigcpu_alert>;
                                cooling-device =
-                                       <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+                                       <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                       <&cpu_b1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
                                contribution = <1024>;
                        };
                };
index c0f1cc4036709f2768eef2d85246ce876ee1ced6..5bd735637b77341d4fef78b0168b05549de5e5ef 100644 (file)
                                map0 {
                                        trip = <&cpu_alert0>;
                                        cooling-device =
-                                               <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+                                               <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                               <&cpu_b1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
                                };
                                map1 {
                                        trip = <&cpu_alert1>;
                                        cooling-device =
                                                <&cpu_l0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
-                                               <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+                                               <&cpu_l1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                               <&cpu_l2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                               <&cpu_l3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                               <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                               <&cpu_b1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
                                };
                        };
                };
                                map0 {
                                        trip = <&gpu_alert0>;
                                        cooling-device =
-                                               <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+                                               <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>,
+                                               <&cpu_b1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
                                };
                        };
                };