ARM: mstar: Add OPP table for infinity
authorDaniel Palmer <daniel@0x0f.com>
Tue, 23 Feb 2021 06:18:28 +0000 (15:18 +0900)
committerRomain Perier <romain.perier@gmail.com>
Wed, 16 Feb 2022 18:27:48 +0000 (19:27 +0100)
Add an OPP table for the inifinity chips so
that cpu frequency scaling can happen.

Co-authored-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Daniel Palmer <daniel@0x0f.com>
Reviewed-by: Romain Perier <romain.perier@gmail.com>
arch/arm/boot/dts/mstar-infinity.dtsi

index 0bee517797f49267087776bab7e50185d295e3b1..441a917b88baf991871a762f2baf62803db7b114 100644 (file)
@@ -8,6 +8,40 @@
 
 #include <dt-bindings/gpio/msc313-gpio.h>
 
+/ {
+       cpu0_opp_table: opp_table0 {
+               compatible = "operating-points-v2";
+               opp-shared;
+
+               opp-240000000 {
+                       opp-hz = /bits/ 64 <240000000>;
+                       opp-microvolt = <1000000>;
+                       clock-latency-ns = <300000>;
+               };
+
+               opp-400000000 {
+                       opp-hz = /bits/ 64 <400000000>;
+                       opp-microvolt = <1000000>;
+                       clock-latency-ns = <300000>;
+               };
+               opp-600000000 {
+                       opp-hz = /bits/ 64 <600000000>;
+                       opp-microvolt = <1000000>;
+                       clock-latency-ns = <300000>;
+               };
+
+               opp-800000000 {
+                       opp-hz = /bits/ 64 <800000000>;
+                       opp-microvolt = <1000000>;
+                       clock-latency-ns = <300000>;
+               };
+       };
+};
+
+&cpu0 {
+       operating-points-v2 = <&cpu0_opp_table>;
+};
+
 &imi {
        reg = <0xa0000000 0x16000>;
 };