regulator: dt-bindings: add missing unevaluatedProperties for each regulator
authorKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Wed, 26 Jul 2023 07:49:40 +0000 (09:49 +0200)
committerMark Brown <broonie@kernel.org>
Wed, 26 Jul 2023 11:49:49 +0000 (12:49 +0100)
Each regulator node, which references common regulator.yaml schema,
should disallow additional or unevaluated properties.  Otherwise
mistakes in properties will go unnoticed.

Reported-by: Konrad Dybcio <konrad.dybcio@linaro.org>
Closes: https://git.codelinaro.org/linaro/qcomlt/kernel/-/commit/1c8aeef8a6e84520b77f0c270d99c8bf692c5933
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20230726074940.121040-1-krzysztof.kozlowski@linaro.org
Signed-off-by: Mark Brown <broonie@kernel.org>
Documentation/devicetree/bindings/regulator/mps,mp5416.yaml
Documentation/devicetree/bindings/regulator/mps,mpq7920.yaml
Documentation/devicetree/bindings/regulator/pfuze100.yaml
Documentation/devicetree/bindings/regulator/qcom,rpmh-regulator.yaml
Documentation/devicetree/bindings/regulator/qcom,smd-rpm-regulator.yaml
Documentation/devicetree/bindings/regulator/richtek,rt4831-regulator.yaml
Documentation/devicetree/bindings/regulator/richtek,rtmv20-regulator.yaml
Documentation/devicetree/bindings/regulator/richtek,rtq6752-regulator.yaml
Documentation/devicetree/bindings/regulator/st,stm32mp1-pwr-reg.yaml
Documentation/devicetree/bindings/regulator/wlf,arizona.yaml

index 2e720d1528900ce6325879d8ac9fb6263a33ba14..0221397eb51ec55d1dfeb7ac3c73d09bf008f314 100644 (file)
@@ -29,10 +29,12 @@ properties:
     patternProperties:
       "^buck[1-4]$":
         $ref: regulator.yaml#
+        unevaluatedProperties: false
         type: object
 
       "^ldo[1-4]$":
         $ref: regulator.yaml#
+        unevaluatedProperties: false
         type: object
 
     additionalProperties: false
index 019c60942efcb310b4d2be704061957f650d9f42..6de5b027f990389b9cf734d67245e5efdf02487b 100644 (file)
@@ -38,11 +38,13 @@ properties:
       ldortc:
         type: object
         $ref: regulator.yaml#
+        unevaluatedProperties: false
 
     patternProperties:
       "^ldo[1-4]$":
         type: object
         $ref: regulator.yaml#
+        unevaluatedProperties: false
 
       "^buck[1-4]$":
         type: object
index e384e4953f0a71643c585cded806e05a369319ed..0eda44752cdda123bc9a0e1817dec4f03424a93d 100644 (file)
@@ -68,18 +68,22 @@ properties:
       "^sw([1-4]|[1-4][a-c]|[1-4][a-c][a-c])$":
         $ref: regulator.yaml#
         type: object
+        unevaluatedProperties: false
 
       "^vgen[1-6]$":
         $ref: regulator.yaml#
         type: object
+        unevaluatedProperties: false
 
       "^vldo[1-4]$":
         $ref: regulator.yaml#
         type: object
+        unevaluatedProperties: false
 
       "^(vsnvs|vref|vrefddr|swbst|coin|v33|vccsd)$":
         $ref: regulator.yaml#
         type: object
+        unevaluatedProperties: false
 
     additionalProperties: false
 
index 72b533c3761a0d6a73a23319708028eeda358fcd..e758093365bc01537d708ac2005811be4c9b08b9 100644 (file)
@@ -111,6 +111,7 @@ properties:
   bob:
     type: object
     $ref: regulator.yaml#
+    unevaluatedProperties: false
     description: BOB regulator node.
     dependencies:
       regulator-allow-set-load: [ regulator-allowed-modes ]
@@ -119,6 +120,7 @@ patternProperties:
   "^(smps|ldo|lvs|bob)[0-9]+$":
     type: object
     $ref: regulator.yaml#
+    unevaluatedProperties: false
     description: smps/ldo regulator nodes(s).
     dependencies:
       regulator-allow-set-load: [ regulator-allowed-modes ]
index a8ca8e0b27f86dabec4d95c057eb1f1e01f66a1a..9ea8ac0786acce29b146ad1cf96d49f38bb31560 100644 (file)
@@ -110,6 +110,7 @@ patternProperties:
   "^((s|l|lvs|5vs)[0-9]*)|(boost-bypass)|(bob)$":
     description: List of regulators and its properties
     $ref: regulator.yaml#
+    unevaluatedProperties: false
 
 additionalProperties: false
 
index d9c23333e15752a80e4f91fc45cf5a3cfa8883b0..cd06e957b9dbefce35a9fbfb37f099dd978a66cf 100644 (file)
@@ -29,6 +29,7 @@ patternProperties:
   "^DSV(LCM|P|N)$":
     type: object
     $ref: regulator.yaml#
+    unevaluatedProperties: false
     description:
       Properties for single Display Bias Voltage regulator.
 
index 446ec5127d1f092e1965f5842cf345cabde98b4b..fec3d396ca50e02c650979be1603fb40e0230364 100644 (file)
@@ -121,6 +121,7 @@ properties:
     description: load switch current regulator description.
     type: object
     $ref: regulator.yaml#
+    unevaluatedProperties: false
 
 required:
   - compatible
index e6e5a9a7d940688369d8741b45e3c8b3b6294173..ef62c618de67ca7ba132c1eac2bdcf0293e928a2 100644 (file)
@@ -35,6 +35,7 @@ properties:
       "^(p|n)avdd$":
         type: object
         $ref: regulator.yaml#
+        unevaluatedProperties: false
         description: |
           regulator description for pavdd and navdd.
 
index 7d53cfa2c288cc3a006d1031998059ea07330a90..c9586d277f41a1810b9e8e5b3dfef529d8fbac2a 100644 (file)
@@ -25,8 +25,8 @@ properties:
 patternProperties:
   "^(reg11|reg18|usb33)$":
     type: object
-
     $ref: regulator.yaml#
+    unevaluatedProperties: false
 
 required:
   - compatible
index 011819c109883b92acfcf576fdda120dd824758d..11e378648b3fd505b21ada319e87eb74ace0c2e5 100644 (file)
@@ -29,11 +29,13 @@ properties:
       Initial data for the LDO1 regulator.
     $ref: regulator.yaml#
     type: object
+    unevaluatedProperties: false
 
   micvdd:
     description:
       Initial data for the MICVDD regulator.
     $ref: regulator.yaml#
     type: object
+    unevaluatedProperties: false
 
 additionalProperties: true