arm64: dts: ls208xa: add cpu idle support
authorYuantian Tang <andy.tang@nxp.com>
Mon, 7 Aug 2017 01:54:39 +0000 (09:54 +0800)
committerShawn Guo <shawnguo@kernel.org>
Mon, 14 Aug 2017 01:14:19 +0000 (09:14 +0800)
ls208xa supports another cpu idle state which is pw20 which saves
more power when cpu is idle.
It was implemented through psci firmware.

Signed-off-by: Tang Yuantian <andy.tang@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
arch/arm64/boot/dts/freescale/fsl-ls2080a.dtsi
arch/arm64/boot/dts/freescale/fsl-ls2088a.dtsi
arch/arm64/boot/dts/freescale/fsl-ls208xa.dtsi

index d789c6814e6a57fd6e7b0d1e8e4700fd8ce2e7a7..8d739301e7b8acbb34951d2b843553bcc101f1e8 100644 (file)
@@ -53,6 +53,7 @@
                compatible = "arm,cortex-a57";
                reg = <0x0>;
                clocks = <&clockgen 1 0>;
+               cpu-idle-states = <&CPU_PW20>;
                next-level-cache = <&cluster0_l2>;
                #cooling-cells = <2>;
        };
@@ -62,6 +63,7 @@
                compatible = "arm,cortex-a57";
                reg = <0x1>;
                clocks = <&clockgen 1 0>;
+               cpu-idle-states = <&CPU_PW20>;
                next-level-cache = <&cluster0_l2>;
        };
 
@@ -70,6 +72,7 @@
                compatible = "arm,cortex-a57";
                reg = <0x100>;
                clocks = <&clockgen 1 1>;
+               cpu-idle-states = <&CPU_PW20>;
                next-level-cache = <&cluster1_l2>;
                #cooling-cells = <2>;
        };
@@ -79,6 +82,7 @@
                compatible = "arm,cortex-a57";
                reg = <0x101>;
                clocks = <&clockgen 1 1>;
+               cpu-idle-states = <&CPU_PW20>;
                next-level-cache = <&cluster1_l2>;
        };
 
@@ -87,6 +91,7 @@
                compatible = "arm,cortex-a57";
                reg = <0x200>;
                clocks = <&clockgen 1 2>;
+               cpu-idle-states = <&CPU_PW20>;
                next-level-cache = <&cluster2_l2>;
                #cooling-cells = <2>;
        };
                compatible = "arm,cortex-a57";
                reg = <0x201>;
                clocks = <&clockgen 1 2>;
+               cpu-idle-states = <&CPU_PW20>;
                next-level-cache = <&cluster2_l2>;
        };
 
                reg = <0x300>;
                clocks = <&clockgen 1 3>;
                next-level-cache = <&cluster3_l2>;
+               cpu-idle-states = <&CPU_PW20>;
                #cooling-cells = <2>;
        };
 
                compatible = "arm,cortex-a57";
                reg = <0x301>;
                clocks = <&clockgen 1 3>;
+               cpu-idle-states = <&CPU_PW20>;
                next-level-cache = <&cluster3_l2>;
        };
 
        cluster3_l2: l2-cache3 {
                compatible = "cache";
        };
+
+       CPU_PW20: cpu-pw20 {
+               compatible = "arm,idle-state";
+               idle-state-name = "PW20";
+               arm,psci-suspend-param = <0x00010000>;
+               entry-latency-us = <2000>;
+               exit-latency-us = <2000>;
+               min-residency-us = <6000>;
+       };
 };
 
 &pcie1 {
index 5c695c6580566020a647f7bbe80efef7df227131..6aa319dae396ffffc135b4e9af9e893029dd1ba7 100644 (file)
@@ -53,6 +53,7 @@
                compatible = "arm,cortex-a72";
                reg = <0x0>;
                clocks = <&clockgen 1 0>;
+               cpu-idle-states = <&CPU_PW20>;
                next-level-cache = <&cluster0_l2>;
                #cooling-cells = <2>;
        };
@@ -62,6 +63,7 @@
                compatible = "arm,cortex-a72";
                reg = <0x1>;
                clocks = <&clockgen 1 0>;
+               cpu-idle-states = <&CPU_PW20>;
                next-level-cache = <&cluster0_l2>;
        };
 
@@ -70,6 +72,7 @@
                compatible = "arm,cortex-a72";
                reg = <0x100>;
                clocks = <&clockgen 1 1>;
+               cpu-idle-states = <&CPU_PW20>;
                next-level-cache = <&cluster1_l2>;
                #cooling-cells = <2>;
        };
@@ -79,6 +82,7 @@
                compatible = "arm,cortex-a72";
                reg = <0x101>;
                clocks = <&clockgen 1 1>;
+               cpu-idle-states = <&CPU_PW20>;
                next-level-cache = <&cluster1_l2>;
        };
 
@@ -88,6 +92,7 @@
                reg = <0x200>;
                clocks = <&clockgen 1 2>;
                next-level-cache = <&cluster2_l2>;
+               cpu-idle-states = <&CPU_PW20>;
                #cooling-cells = <2>;
        };
 
                compatible = "arm,cortex-a72";
                reg = <0x201>;
                clocks = <&clockgen 1 2>;
+               cpu-idle-states = <&CPU_PW20>;
                next-level-cache = <&cluster2_l2>;
        };
 
                compatible = "arm,cortex-a72";
                reg = <0x300>;
                clocks = <&clockgen 1 3>;
+               cpu-idle-states = <&CPU_PW20>;
                next-level-cache = <&cluster3_l2>;
                #cooling-cells = <2>;
        };
                compatible = "arm,cortex-a72";
                reg = <0x301>;
                clocks = <&clockgen 1 3>;
+               cpu-idle-states = <&CPU_PW20>;
                next-level-cache = <&cluster3_l2>;
        };
 
        cluster3_l2: l2-cache3 {
                compatible = "cache";
        };
+
+       CPU_PW20: cpu-pw20 {
+               compatible = "arm,idle-state";
+               idle-state-name = "PW20";
+               arm,psci-suspend-param = <0x00010000>;
+               entry-latency-us = <2000>;
+               exit-latency-us = <2000>;
+               min-residency-us = <6000>;
+       };
 };
 
 &pcie1 {
index fc1234dc90f9031e55b993c23b6475430000ace6..4fb9a0966a84f2db6c51861c5087ccb5346c49c9 100644 (file)
                interrupts = <1 7 0x8>; /* PMU PPI, Level low type */
        };
 
+       psci {
+               compatible = "arm,psci-0.2";
+               method = "smc";
+       };
+
        soc {
                compatible = "simple-bus";
                #address-cells = <2>;