linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] dt-bindings: Ensure child nodes are of type 'object'
@ 2019-07-15 23:04 Rob Herring
  2019-07-16  7:19 ` Miquel Raynal
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Rob Herring @ 2019-07-15 23:04 UTC (permalink / raw)
  To: devicetree
  Cc: linux-kernel, Maxime Ripard, Chen-Yu Tsai, David Woodhouse,
	Brian Norris, Marek Vasut, Miquel Raynal, Richard Weinberger,
	Vignesh Raghavendra, Linus Walleij, Maxime Coquelin,
	Alexandre Torgue, Mark Brown, linux-mtd, linux-gpio, linux-stm32,
	linux-spi

Properties which are child node definitions need to have an explict
type. Otherwise, a matching (DT) property can silently match when an
error is desired. Fix this up tree-wide. Once this is fixed, the
meta-schema will enforce this on any child node definitions.

Cc: Maxime Ripard <maxime.ripard@bootlin.com>
Cc: Chen-Yu Tsai <wens@csie.org>
Cc: David Woodhouse <dwmw2@infradead.org>
Cc: Brian Norris <computersforpeace@gmail.com>
Cc: Marek Vasut <marek.vasut@gmail.com>
Cc: Miquel Raynal <miquel.raynal@bootlin.com>
Cc: Richard Weinberger <richard@nod.at>
Cc: Vignesh Raghavendra <vigneshr@ti.com>
Cc: Linus Walleij <linus.walleij@linaro.org>
Cc: Maxime Coquelin <mcoquelin.stm32@gmail.com>
Cc: Alexandre Torgue <alexandre.torgue@st.com>
Cc: Mark Brown <broonie@kernel.org>
Cc: linux-mtd@lists.infradead.org
Cc: linux-gpio@vger.kernel.org
Cc: linux-stm32@st-md-mailman.stormreply.com
Cc: linux-spi@vger.kernel.org
Signed-off-by: Rob Herring <robh@kernel.org>
---
Please ack. I will take this via the DT tree.

Rob

 .../devicetree/bindings/bus/allwinner,sun8i-a23-rsb.yaml       | 1 +
 .../devicetree/bindings/mtd/allwinner,sun4i-a10-nand.yaml      | 1 +
 Documentation/devicetree/bindings/mtd/nand-controller.yaml     | 1 +
 .../devicetree/bindings/pinctrl/st,stm32-pinctrl.yaml          | 3 +++
 .../devicetree/bindings/spi/allwinner,sun4i-a10-spi.yaml       | 1 +
 .../devicetree/bindings/spi/allwinner,sun6i-a31-spi.yaml       | 1 +
 6 files changed, 8 insertions(+)

diff --git a/Documentation/devicetree/bindings/bus/allwinner,sun8i-a23-rsb.yaml b/Documentation/devicetree/bindings/bus/allwinner,sun8i-a23-rsb.yaml
index fc2f63860cc8..be32f087c529 100644
--- a/Documentation/devicetree/bindings/bus/allwinner,sun8i-a23-rsb.yaml
+++ b/Documentation/devicetree/bindings/bus/allwinner,sun8i-a23-rsb.yaml
@@ -42,6 +42,7 @@ properties:
 
 patternProperties:
   "^.*@[0-9a-fA-F]+$":
+    type: object
     properties:
       reg:
         maxItems: 1
diff --git a/Documentation/devicetree/bindings/mtd/allwinner,sun4i-a10-nand.yaml b/Documentation/devicetree/bindings/mtd/allwinner,sun4i-a10-nand.yaml
index e5a411518be1..b5b3cf5b1ac2 100644
--- a/Documentation/devicetree/bindings/mtd/allwinner,sun4i-a10-nand.yaml
+++ b/Documentation/devicetree/bindings/mtd/allwinner,sun4i-a10-nand.yaml
@@ -55,6 +55,7 @@ patternProperties:
   "^pinctrl-[0-9]+$": true
 
   "^nand@[a-f0-9]+$":
+    type: object
     properties:
       reg:
         minimum: 0
diff --git a/Documentation/devicetree/bindings/mtd/nand-controller.yaml b/Documentation/devicetree/bindings/mtd/nand-controller.yaml
index 199ba5ac2a06..d261b7096c69 100644
--- a/Documentation/devicetree/bindings/mtd/nand-controller.yaml
+++ b/Documentation/devicetree/bindings/mtd/nand-controller.yaml
@@ -40,6 +40,7 @@ properties:
 
 patternProperties:
   "^nand@[a-f0-9]$":
+    type: object
     properties:
       reg:
         description:
diff --git a/Documentation/devicetree/bindings/pinctrl/st,stm32-pinctrl.yaml b/Documentation/devicetree/bindings/pinctrl/st,stm32-pinctrl.yaml
index 06c4b66c3ee6..3ac5d2088e49 100644
--- a/Documentation/devicetree/bindings/pinctrl/st,stm32-pinctrl.yaml
+++ b/Documentation/devicetree/bindings/pinctrl/st,stm32-pinctrl.yaml
@@ -55,6 +55,7 @@ properties:
 
 patternProperties:
   '^gpio@[0-9a-f]*$':
+    type: object
     properties:
       gpio-controller: true
       '#gpio-cells':
@@ -113,8 +114,10 @@ patternProperties:
       - st,bank-name
 
   '-[0-9]*$':
+    type: object
     patternProperties:
       '^pins':
+        type: object
         description: |
           A pinctrl node should contain at least one subnode representing the
           pinctrl group available on the machine. Each subnode will list the
diff --git a/Documentation/devicetree/bindings/spi/allwinner,sun4i-a10-spi.yaml b/Documentation/devicetree/bindings/spi/allwinner,sun4i-a10-spi.yaml
index c374fd4923a6..6d1329c28170 100644
--- a/Documentation/devicetree/bindings/spi/allwinner,sun4i-a10-spi.yaml
+++ b/Documentation/devicetree/bindings/spi/allwinner,sun4i-a10-spi.yaml
@@ -50,6 +50,7 @@ properties:
 
 patternProperties:
   "^.*@[0-9a-f]+":
+    type: object
     properties:
       reg:
         items:
diff --git a/Documentation/devicetree/bindings/spi/allwinner,sun6i-a31-spi.yaml b/Documentation/devicetree/bindings/spi/allwinner,sun6i-a31-spi.yaml
index bda7a5befd8b..f36c46d236d7 100644
--- a/Documentation/devicetree/bindings/spi/allwinner,sun6i-a31-spi.yaml
+++ b/Documentation/devicetree/bindings/spi/allwinner,sun6i-a31-spi.yaml
@@ -55,6 +55,7 @@ properties:
 
 patternProperties:
   "^.*@[0-9a-f]+":
+    type: object
     properties:
       reg:
         items:
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] dt-bindings: Ensure child nodes are of type 'object'
  2019-07-15 23:04 [PATCH] dt-bindings: Ensure child nodes are of type 'object' Rob Herring
@ 2019-07-16  7:19 ` Miquel Raynal
  2019-07-16  8:28 ` Maxime Ripard
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: Miquel Raynal @ 2019-07-16  7:19 UTC (permalink / raw)
  To: Rob Herring
  Cc: devicetree, linux-kernel, Maxime Ripard, Chen-Yu Tsai,
	David Woodhouse, Brian Norris, Marek Vasut, Richard Weinberger,
	Vignesh Raghavendra, Linus Walleij, Maxime Coquelin,
	Alexandre Torgue, Mark Brown, linux-mtd, linux-gpio, linux-stm32,
	linux-spi

Hi Rob,

Rob Herring <robh@kernel.org> wrote on Mon, 15 Jul 2019 17:04:57 -0600:

> Properties which are child node definitions need to have an explict
> type. Otherwise, a matching (DT) property can silently match when an
> error is desired. Fix this up tree-wide. Once this is fixed, the
> meta-schema will enforce this on any child node definitions.
> 
> Cc: Maxime Ripard <maxime.ripard@bootlin.com>
> Cc: Chen-Yu Tsai <wens@csie.org>
> Cc: David Woodhouse <dwmw2@infradead.org>
> Cc: Brian Norris <computersforpeace@gmail.com>
> Cc: Marek Vasut <marek.vasut@gmail.com>
> Cc: Miquel Raynal <miquel.raynal@bootlin.com>
> Cc: Richard Weinberger <richard@nod.at>
> Cc: Vignesh Raghavendra <vigneshr@ti.com>
> Cc: Linus Walleij <linus.walleij@linaro.org>
> Cc: Maxime Coquelin <mcoquelin.stm32@gmail.com>
> Cc: Alexandre Torgue <alexandre.torgue@st.com>
> Cc: Mark Brown <broonie@kernel.org>
> Cc: linux-mtd@lists.infradead.org
> Cc: linux-gpio@vger.kernel.org
> Cc: linux-stm32@st-md-mailman.stormreply.com
> Cc: linux-spi@vger.kernel.org
> Signed-off-by: Rob Herring <robh@kernel.org>
> ---
> Please ack. I will take this via the DT tree.
> 
> Rob
> 
>  .../devicetree/bindings/bus/allwinner,sun8i-a23-rsb.yaml       | 1 +
>  .../devicetree/bindings/mtd/allwinner,sun4i-a10-nand.yaml      | 1 +
>  Documentation/devicetree/bindings/mtd/nand-controller.yaml     | 1 +
>  .../devicetree/bindings/pinctrl/st,stm32-pinctrl.yaml          | 3 +++
>  .../devicetree/bindings/spi/allwinner,sun4i-a10-spi.yaml       | 1 +
>  .../devicetree/bindings/spi/allwinner,sun6i-a31-spi.yaml       | 1 +
>  6 files changed, 8 insertions(+)
> 

[...]

> diff --git a/Documentation/devicetree/bindings/mtd/nand-controller.yaml b/Documentation/devicetree/bindings/mtd/nand-controller.yaml
> index 199ba5ac2a06..d261b7096c69 100644
> --- a/Documentation/devicetree/bindings/mtd/nand-controller.yaml
> +++ b/Documentation/devicetree/bindings/mtd/nand-controller.yaml
> @@ -40,6 +40,7 @@ properties:
>  
>  patternProperties:
>    "^nand@[a-f0-9]$":
> +    type: object
>      properties:
>        reg:
>          description:

For the mtd .yaml:

Acked-by: Miquel Raynal <miquel.raynal@bootlin.com>


Thanks,
Miquèl

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] dt-bindings: Ensure child nodes are of type 'object'
  2019-07-15 23:04 [PATCH] dt-bindings: Ensure child nodes are of type 'object' Rob Herring
  2019-07-16  7:19 ` Miquel Raynal
@ 2019-07-16  8:28 ` Maxime Ripard
  2019-07-16 11:09 ` Mark Brown
  2019-07-18 16:20 ` Alexandre Torgue
  3 siblings, 0 replies; 5+ messages in thread
From: Maxime Ripard @ 2019-07-16  8:28 UTC (permalink / raw)
  To: Rob Herring
  Cc: devicetree, linux-kernel, Chen-Yu Tsai, David Woodhouse,
	Brian Norris, Marek Vasut, Miquel Raynal, Richard Weinberger,
	Vignesh Raghavendra, Linus Walleij, Maxime Coquelin,
	Alexandre Torgue, Mark Brown, linux-mtd, linux-gpio, linux-stm32,
	linux-spi

On Mon, Jul 15, 2019 at 05:04:57PM -0600, Rob Herring wrote:
> Properties which are child node definitions need to have an explict
> type. Otherwise, a matching (DT) property can silently match when an
> error is desired. Fix this up tree-wide. Once this is fixed, the
> meta-schema will enforce this on any child node definitions.
>
> Cc: Maxime Ripard <maxime.ripard@bootlin.com>
> Cc: Chen-Yu Tsai <wens@csie.org>
> Cc: David Woodhouse <dwmw2@infradead.org>
> Cc: Brian Norris <computersforpeace@gmail.com>
> Cc: Marek Vasut <marek.vasut@gmail.com>
> Cc: Miquel Raynal <miquel.raynal@bootlin.com>
> Cc: Richard Weinberger <richard@nod.at>
> Cc: Vignesh Raghavendra <vigneshr@ti.com>
> Cc: Linus Walleij <linus.walleij@linaro.org>
> Cc: Maxime Coquelin <mcoquelin.stm32@gmail.com>
> Cc: Alexandre Torgue <alexandre.torgue@st.com>
> Cc: Mark Brown <broonie@kernel.org>
> Cc: linux-mtd@lists.infradead.org
> Cc: linux-gpio@vger.kernel.org
> Cc: linux-stm32@st-md-mailman.stormreply.com
> Cc: linux-spi@vger.kernel.org
> Signed-off-by: Rob Herring <robh@kernel.org>

Acked-by: Maxime Ripard <maxime.ripard@bootlin.com>

Thanks!
Maxime

--
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] dt-bindings: Ensure child nodes are of type 'object'
  2019-07-15 23:04 [PATCH] dt-bindings: Ensure child nodes are of type 'object' Rob Herring
  2019-07-16  7:19 ` Miquel Raynal
  2019-07-16  8:28 ` Maxime Ripard
@ 2019-07-16 11:09 ` Mark Brown
  2019-07-18 16:20 ` Alexandre Torgue
  3 siblings, 0 replies; 5+ messages in thread
From: Mark Brown @ 2019-07-16 11:09 UTC (permalink / raw)
  To: Rob Herring
  Cc: devicetree, linux-kernel, Maxime Ripard, Chen-Yu Tsai,
	David Woodhouse, Brian Norris, Marek Vasut, Miquel Raynal,
	Richard Weinberger, Vignesh Raghavendra, Linus Walleij,
	Maxime Coquelin, Alexandre Torgue, linux-mtd, linux-gpio,
	linux-stm32, linux-spi

[-- Attachment #1: Type: text/plain, Size: 375 bytes --]

On Mon, Jul 15, 2019 at 05:04:57PM -0600, Rob Herring wrote:
> Properties which are child node definitions need to have an explict
> type. Otherwise, a matching (DT) property can silently match when an
> error is desired. Fix this up tree-wide. Once this is fixed, the
> meta-schema will enforce this on any child node definitions.

Acked-by: Mark Brown <broonie@kernel.org>

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] dt-bindings: Ensure child nodes are of type 'object'
  2019-07-15 23:04 [PATCH] dt-bindings: Ensure child nodes are of type 'object' Rob Herring
                   ` (2 preceding siblings ...)
  2019-07-16 11:09 ` Mark Brown
@ 2019-07-18 16:20 ` Alexandre Torgue
  3 siblings, 0 replies; 5+ messages in thread
From: Alexandre Torgue @ 2019-07-18 16:20 UTC (permalink / raw)
  To: Rob Herring, devicetree
  Cc: linux-kernel, Maxime Ripard, Chen-Yu Tsai, David Woodhouse,
	Brian Norris, Marek Vasut, Miquel Raynal, Richard Weinberger,
	Vignesh Raghavendra, Linus Walleij, Maxime Coquelin, Mark Brown,
	linux-mtd, linux-gpio, linux-stm32, linux-spi

Hi Rob

On 7/16/19 1:04 AM, Rob Herring wrote:
> Properties which are child node definitions need to have an explict
> type. Otherwise, a matching (DT) property can silently match when an
> error is desired. Fix this up tree-wide. Once this is fixed, the
> meta-schema will enforce this on any child node definitions.
> 
> Cc: Maxime Ripard <maxime.ripard@bootlin.com>
> Cc: Chen-Yu Tsai <wens@csie.org>
> Cc: David Woodhouse <dwmw2@infradead.org>
> Cc: Brian Norris <computersforpeace@gmail.com>
> Cc: Marek Vasut <marek.vasut@gmail.com>
> Cc: Miquel Raynal <miquel.raynal@bootlin.com>
> Cc: Richard Weinberger <richard@nod.at>
> Cc: Vignesh Raghavendra <vigneshr@ti.com>
> Cc: Linus Walleij <linus.walleij@linaro.org>
> Cc: Maxime Coquelin <mcoquelin.stm32@gmail.com>
> Cc: Alexandre Torgue <alexandre.torgue@st.com>
> Cc: Mark Brown <broonie@kernel.org>
> Cc: linux-mtd@lists.infradead.org
> Cc: linux-gpio@vger.kernel.org
> Cc: linux-stm32@st-md-mailman.stormreply.com
> Cc: linux-spi@vger.kernel.org
> Signed-off-by: Rob Herring <robh@kernel.org>
> ---
> Please ack. I will take this via the DT tree.
>

For pinctrl STM32:

Acked-by: Alexandre TORGUE <alexandre.torgue@st.com>

thanks

Alexandre

> Rob
> 
>

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-07-18 16:21 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-07-15 23:04 [PATCH] dt-bindings: Ensure child nodes are of type 'object' Rob Herring
2019-07-16  7:19 ` Miquel Raynal
2019-07-16  8:28 ` Maxime Ripard
2019-07-16 11:09 ` Mark Brown
2019-07-18 16:20 ` Alexandre Torgue

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).