Skip to contentSkip to conversation

dt-bindings: A few updates to PSCI and power-domain bindings

PATCH Applied Ulf Hansson 2 participants 5 messages Mar 26, 2020 – Mar 31, 2020

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

cover dt-bindings: A few updates to PSCI and power-domain bindings

Recent updates to the PSCI and the power-domain DT bindings, deserves some additional improvements on top. This series takes care of this.

Ulf Hansson (2):
dt-bindings: arm: Add some constraints for PSCI nodes
dt-bindings: power: Fix example for power-domain

 .../devicetree/bindings/arm/psci.yaml         |  5 ++++
 .../bindings/power/power-domain.yaml          | 28 +++++++++----------
 2 files changed, 19 insertions(+), 14 deletions(-)
Signature · 1 line
2.20.1
#1 lore raw

PATCH 1/2 dt-bindings: arm: Add some constraints for PSCI nodes

There's no point allowing anything else but "psci" for the corresponding nodename of the PSCI node, so let's make this an explicit requirement.

Moreover, let's also prevent additional properties, which also allows a better verification of the "patternProperties" bindings for subnodes.

---
 Documentation/devicetree/bindings/arm/psci.yaml | 5 +++++
 1 file changed, 5 insertions(+)
Documentation/devicetree/bindings/arm/psci.yaml +5 -0
index 5e66934455bb..9247b58c26fc 100644
@@ -32,6 +32,9 @@ description: |+
     http://infocenter.arm.com/help/topic/com.arm.doc.den0022c/DEN0022C_Power_State_Coordination_Interface.pdf
 
 properties:
+  $nodename:
+    const: psci
+
   compatible:
     oneOf:
       - description:
@@ -141,6 +144,8 @@ allOf:
         - cpu_off
         - cpu_on
 
+additionalProperties: false
+
 examples:
   - |+
 
Signature · 1 line
2.20.1
maintainer Applied
#2 lore raw

Re: [PATCH 1/2] dt-bindings: arm: Add some constraints for PSCI nodes

Quoted 11 lines · Ulf Hansson

There's no point allowing anything else but "psci" for the corresponding nodename of the PSCI node, so let's make this an explicit requirement.

Moreover, let's also prevent additional properties, which also allows a better verification of the "patternProperties" bindings for subnodes.

---
 Documentation/devicetree/bindings/arm/psci.yaml | 5 +++++
 1 file changed, 5 insertions(+)

Applied, thanks.

Rob

#3 lore raw

PATCH 2/2 dt-bindings: power: Fix example for power-domain

In reply to Ulf Hansson

The change that converted the domain-idle-states DT bindings to the json-schema, forgot to update the corresponding example for the power-domain binding. Let's fix it.

Fixes 3261227d136d ("dt-bindings: power: Convert domain-idle-states bindings to json-schema")
---
 .../bindings/power/power-domain.yaml          | 28 +++++++++----------
 1 file changed, 14 insertions(+), 14 deletions(-)
Documentation/devicetree/bindings/power/power-domain.yaml +14 -14
index 6047aacd7766..ff5936e4a215 100644
@@ -114,18 +114,18 @@ examples:
         domain-idle-states = <&DOMAIN_PWR_DN>;
     };
 
-    DOMAIN_RET: state@0 {
-        compatible = "domain-idle-state";
-        reg = <0x0 0x0>;
-        entry-latency-us = <1000>;
-        exit-latency-us = <2000>;
-        min-residency-us = <10000>;
-    };
-
-    DOMAIN_PWR_DN: state@1 {
-        compatible = "domain-idle-state";
-        reg = <0x1 0x0>;
-        entry-latency-us = <5000>;
-        exit-latency-us = <8000>;
-        min-residency-us = <7000>;
+    domain-idle-states {
+        DOMAIN_RET: domain-retention {
+            compatible = "domain-idle-state";
+            entry-latency-us = <1000>;
+            exit-latency-us = <2000>;
+            min-residency-us = <10000>;
+        };
+
+        DOMAIN_PWR_DN: domain-pwr-dn {
+            compatible = "domain-idle-state";
+            entry-latency-us = <5000>;
+            exit-latency-us = <8000>;
+            min-residency-us = <7000>;
+        };
     };
Signature · 1 line
2.20.1
maintainer Applied
#4 lore raw

Re: [PATCH 2/2] dt-bindings: power: Fix example for power-domain

Quoted 10 lines · Ulf Hansson

The change that converted the domain-idle-states DT bindings to the json-schema, forgot to update the corresponding example for the power-domain binding. Let's fix it.

Fixes 3261227d136d ("dt-bindings: power: Convert domain-idle-states bindings to json-schema")
---
 .../bindings/power/power-domain.yaml          | 28 +++++++++----------
 1 file changed, 14 insertions(+), 14 deletions(-)

Applied, thanks.

Rob