[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200317093922.20785-13-lkundrak@v3.sk>
Date: Tue, 17 Mar 2020 10:39:06 +0100
From: Lubomir Rintel <lkundrak@...sk>
To: Rob Herring <robh+dt@...nel.org>
Cc: Linus Walleij <linus.walleij@...aro.org>,
Bartosz Golaszewski <bgolaszewski@...libre.com>,
Thomas Gleixner <tglx@...utronix.de>,
Jason Cooper <jason@...edaemon.net>,
Marc Zyngier <maz@...nel.org>,
Mauro Carvalho Chehab <mchehab@...nel.org>,
Ulf Hansson <ulf.hansson@...aro.org>,
Kishon Vijay Abraham I <kishon@...com>,
Alessandro Zummo <a.zummo@...ertech.it>,
Alexandre Belloni <alexandre.belloni@...tlin.com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Mark Brown <broonie@...nel.org>,
Daniel Lezcano <daniel.lezcano@...aro.org>,
Andrew Lunn <andrew@...n.ch>,
Gregory Clement <gregory.clement@...tlin.com>,
Daniel Mack <daniel@...que.org>,
Haojian Zhuang <haojian.zhuang@...il.com>,
Robert Jarzmik <robert.jarzmik@...e.fr>,
devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-gpio@...r.kernel.org, linux-i2c@...r.kernel.org,
linux-media@...r.kernel.org, linux-mmc@...r.kernel.org,
linux-rtc@...r.kernel.org, linux-serial@...r.kernel.org,
linux-spi@...r.kernel.org, linux-usb@...r.kernel.org,
Lubomir Rintel <lkundrak@...sk>
Subject: [PATCH 12/28] spi: dt-bindings: spi-controller: Slaves have no address cells
SPI controllers in slave mode have a single child node that has no
address. Enforce #address-cells of zero instead of one.
Fixes: 0a1b929356830 ("spi: Add YAML schemas for the generic SPI options")
Signed-off-by: Lubomir Rintel <lkundrak@...sk>
---
.../bindings/spi/spi-controller.yaml | 23 ++++++++++++++-----
1 file changed, 17 insertions(+), 6 deletions(-)
diff --git a/Documentation/devicetree/bindings/spi/spi-controller.yaml b/Documentation/devicetree/bindings/spi/spi-controller.yaml
index d8e5509a70816..30d774cf6cc95 100644
--- a/Documentation/devicetree/bindings/spi/spi-controller.yaml
+++ b/Documentation/devicetree/bindings/spi/spi-controller.yaml
@@ -15,16 +15,27 @@ description: |
controller may be described for use in SPI master mode or in SPI slave mode,
but not for both at the same time.
+allOf:
+ - if:
+ required:
+ - spi-slave
+ then:
+ properties:
+ "#address-cells":
+ const: 0
+ "#size-cells":
+ const: 0
+ else:
+ properties:
+ "#address-cells":
+ const: 1
+ "#size-cells":
+ const: 0
+
properties:
$nodename:
pattern: "^spi(@.*|-[0-9a-f])*$"
- "#address-cells":
- const: 1
-
- "#size-cells":
- const: 0
-
cs-gpios:
description: |
GPIOs used as chip selects.
--
2.25.1
Powered by blists - more mailing lists