dt-bindings: pinctrl: Add missing (unevaluated|additional)Properties on child nodes
authorRob Herring <robh@kernel.org>
Tue, 23 Aug 2022 14:56:37 +0000 (09:56 -0500)
committerLinus Walleij <linus.walleij@linaro.org>
Fri, 26 Aug 2022 13:33:07 +0000 (15:33 +0200)
In order to ensure only documented properties are present, node schemas
must have unevaluatedProperties or additionalProperties set to false
(typically).

Signed-off-by: Rob Herring <robh@kernel.org>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20220823145649.3118479-6-robh@kernel.org
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Documentation/devicetree/bindings/pinctrl/brcm,bcm4908-pinctrl.yaml
Documentation/devicetree/bindings/pinctrl/intel,pinctrl-keembay.yaml
Documentation/devicetree/bindings/pinctrl/intel,pinctrl-thunderbay.yaml
Documentation/devicetree/bindings/pinctrl/marvell,ac5-pinctrl.yaml
Documentation/devicetree/bindings/pinctrl/mediatek,mt6779-pinctrl.yaml
Documentation/devicetree/bindings/pinctrl/nuvoton,wpcm450-pinctrl.yaml
Documentation/devicetree/bindings/pinctrl/renesas,rza1-ports.yaml
Documentation/devicetree/bindings/pinctrl/samsung,pinctrl.yaml
Documentation/devicetree/bindings/pinctrl/st,stm32-pinctrl.yaml
Documentation/devicetree/bindings/pinctrl/toshiba,visconti-pinctrl.yaml

index 175a992f15e16f363069edf5dd86e38dc2dbe211..8a9fb9b433ca1ef1d0d3e306cbce05390c35f3af 100644 (file)
@@ -23,6 +23,7 @@ patternProperties:
   '-pins$':
     type: object
     $ref: pinmux-node.yaml#
+    additionalProperties: false
 
     properties:
       function:
index 5e99d79499b491d343b1cbe7c74e5600634e3852..846651ff77c91590e7a01189dc55562b3b223580 100644 (file)
@@ -44,6 +44,7 @@ properties:
 patternProperties:
   '^gpio@[0-9a-f]*$':
     type: object
+    additionalProperties: false
 
     description:
       Child nodes can be specified to contain pin configuration information,
index 0ec476248f216ea971e5ff3c066d189309e38e09..6f30b5337ca25dfbffcf39d1e898cad76b1415b0 100644 (file)
@@ -42,6 +42,7 @@ properties:
 patternProperties:
   '^gpio@[0-9a-f]*$':
     type: object
+    additionalProperties: false
 
     description:
       Child nodes can be specified to contain pin configuration information,
index a651b2744caf35b01592afa997e0cebaca68c88f..491f67e7cc4fa42db9b87bf862d7cafa9e8b51f4 100644 (file)
@@ -24,6 +24,7 @@ patternProperties:
   '-pins$':
     type: object
     $ref: pinmux-node.yaml#
+    additionalProperties: false
 
     properties:
       marvell,function:
index e7601c0f5a695a5de27fb6650b1b8ea64c0301c7..840f649e36ce3711b1b81632439818e1a322a034 100644 (file)
@@ -76,6 +76,8 @@ required:
 patternProperties:
   '-[0-9]*$':
     type: object
+    additionalProperties: false
+
     patternProperties:
       '-pins*$':
         type: object
index 7a11beb8f222dd7d77d38c78c7caa561b9cb54f1..7b7f840ffc4cf1eaef61affdb8c4bfeb1c9ed3af 100644 (file)
@@ -30,6 +30,7 @@ patternProperties:
 
   "^gpio@[0-7]$":
     type: object
+    additionalProperties: false
 
     description:
       Eight GPIO banks (gpio@0 to gpio@7), that each contain between 14 and 18
index 8ed4b98a1628970ba867e674e70fe067a5b6c27c..9083040c996ab06feccd6ecdbd8468dea5f81641 100644 (file)
@@ -41,6 +41,7 @@ required:
 patternProperties:
   "^gpio-[0-9]*$":
     type: object
+    additionalProperties: false
 
     description:
       Each port of the r7s72100 pin controller hardware is itself a GPIO
index 3a65c66ca71d226691befcb2a7b0f5fbf2e8726c..d006a940c7c64646f5d24290626d2fc9e337277a 100644 (file)
@@ -97,6 +97,9 @@ patternProperties:
         additionalProperties: false
 
   "^(initial|sleep)-state$":
+    type: object
+    additionalProperties: false
+
     patternProperties:
       "^(pin-[a-z0-9-]+|[a-z0-9-]+-pin)$":
         $ref: samsung,pinctrl-pins-cfg.yaml
index d35dcc4f024219ba869d72ce4506f7ab8553a502..53c952d93ea28839a21a3a1dd9d45c490baa956b 100644 (file)
@@ -115,9 +115,12 @@ patternProperties:
 
   '-[0-9]*$':
     type: object
+    additionalProperties: false
+
     patternProperties:
       '^pins':
         type: object
+        additionalProperties: false
         description: |
           A pinctrl node should contain at least one subnode representing the
           pinctrl group available on the machine. Each subnode will list the
index 306524885a2b869aebf9da80e7c4f76f909a3838..98b4663f9766c696b4c222ffb9d3f66819163e8c 100644 (file)
@@ -36,6 +36,7 @@ patternProperties:
       pins it needs, and how they should be configured, with regard to muxer
       configuration, pullups, drive strength.
     $ref: "pinmux-node.yaml"
+    additionalProperties: false
 
     properties:
       function: