diff mbox series

[1/2] dt-bindings: cpu: idle-states: Add idle-state-disabled property

Message ID 20230608085544.16211-3-quic_tnimkar@quicinc.com
State Superseded
Headers show
Series Add provision to keep idle state disabled | expand

Commit Message

Tushar Nimkar June 8, 2023, 8:55 a.m. UTC
This change adds idle-state-disabled property using which certain or all
idle-states can be kept disabled during boot-up. Once boot-up is completed
same can be enabled using below command.

echo N > /sys/devices/system/cpu/cpuX/cpuidle/stateX/disable

Cc: devicetree@vger.kernel.org
Signed-off-by: Tushar Nimkar <quic_tnimkar@quicinc.com>
---
 Documentation/devicetree/bindings/cpu/idle-states.yaml | 8 ++++++++
 1 file changed, 8 insertions(+)

Comments

Krzysztof Kozlowski June 9, 2023, 1:15 p.m. UTC | #1
On 08/06/2023 10:55, Tushar Nimkar wrote:
> This change adds idle-state-disabled property using which certain or all
> idle-states can be kept disabled during boot-up. Once boot-up is completed
> same can be enabled using below command.
> 
> echo N > /sys/devices/system/cpu/cpuX/cpuidle/stateX/disab

This is a duplicated patch. I already commented on other so to make it
clear: NAK for this one :)

Best regards,
Krzysztof
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/cpu/idle-states.yaml b/Documentation/devicetree/bindings/cpu/idle-states.yaml
index b8cc826c9501..f999bc666bbd 100644
--- a/Documentation/devicetree/bindings/cpu/idle-states.yaml
+++ b/Documentation/devicetree/bindings/cpu/idle-states.yaml
@@ -358,6 +358,13 @@  patternProperties:
           systems entry-latency-us + exit-latency-us will exceed
           wakeup-latency-us by this duration.
 
+      idle-state-disabled:
+        description: |
+          If present the idle state stays disabled. It can be enabled back from
+          shell using below command.
+          echo N > /sys/devices/system/cpu/cpuX/cpuidle/stateX/disable
+        type: boolean
+
       idle-state-name:
         $ref: /schemas/types.yaml#/definitions/string
         description:
@@ -548,6 +555,7 @@  examples:
             CPU_SLEEP_0_0: cpu-sleep-0-0 {
                 compatible = "arm,idle-state";
                 local-timer-stop;
+                idle-state-disabled;
                 arm,psci-suspend-param = <0x0010000>;
                 entry-latency-us = <250>;
                 exit-latency-us = <500>;