linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Marek Behún" <marek.behun@nic.cz>
To: Linus Walleij <linus.walleij@linaro.org>
Cc: "Tony Lindgren" <tony@atomide.com>,
	"Shawn Guo" <shawnguo@kernel.org>,
	linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org,
	"Marek Behún" <marek.behun@nic.cz>,
	"Rob Herring" <robh+dt@kernel.org>,
	devicetree@vger.kernel.org
Subject: [PATCH v3 bus+gpio 2/5] dt-bindings: bus: Document moxtet bus binding
Date: Fri,  1 Mar 2019 04:58:49 +0100	[thread overview]
Message-ID: <20190301035852.26780-3-marek.behun@nic.cz> (raw)
In-Reply-To: <20190301035852.26780-1-marek.behun@nic.cz>

This adds device tree binding documentation for the Moxtet bus, a bus
via which the different modules connected to the Turris Mox router can
be configured.

Signed-off-by: Marek Behún <marek.behun@nic.cz>
Cc: Rob Herring <robh+dt@kernel.org>
Cc: devicetree@vger.kernel.org
---
 .../devicetree/bindings/bus/moxtet.txt        | 36 +++++++++++++++++++
 1 file changed, 36 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/bus/moxtet.txt

diff --git a/Documentation/devicetree/bindings/bus/moxtet.txt b/Documentation/devicetree/bindings/bus/moxtet.txt
new file mode 100644
index 000000000000..2bb998cbd3ad
--- /dev/null
+++ b/Documentation/devicetree/bindings/bus/moxtet.txt
@@ -0,0 +1,36 @@
+Turris Mox module configuration bus (over SPI)
+
+Required properties:
+ - compatible		: Should be "cznic,moxtet".
+ - #address-cells	: Has to be 1
+ - #size-cells		: Has to be 0
+ - spi-cpol		: Required inverted clock polarity
+ - spi-cpha		: Required shifted clock phase
+For other required and optional properties of SPI slave nodes please refer to
+../spi/spi-bus.txt.
+
+Required properties of subnodes:
+ - reg			: Should be position on the Moxtet bus
+
+The driver finds the devices connected to the bus by itself, but it may be
+needed to reference some of them from other parts of the device tree. In that
+case the devices can be defined as subnodes of the moxtet node.
+
+Example:
+
+	moxtet@1 {
+		#address-cells = <1>;
+		#size-cells = <0>;
+		compatible = "cznic,moxtet";
+		reg = <1>;
+		spi-max-frequency = <10000000>;
+		spi-cpol;
+		spi-cpha;
+
+		moxtet_sfp: gpio@0 {
+			compatible = "cznic,moxtet-sfp";
+			gpio-controller;
+			#gpio-cells = <2>;
+			reg = <0>;
+		}
+	};
-- 
2.19.2


  parent reply	other threads:[~2019-03-01  3:59 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-01  3:58 [PATCH v3 bus+gpio 0/5] Add Moxtet bus and GPIO over Moxtet bus Marek Behún
2019-03-01  3:58 ` [PATCH v3 bus+gpio 1/5] bus: Add support for " Marek Behún
2019-03-05 11:24   ` Arnd Bergmann
2019-03-01  3:58 ` Marek Behún [this message]
2019-03-01  3:58 ` [PATCH v3 bus+gpio 3/5] bus: moxtet: Add sysfs documentation Marek Behún
2019-03-01 14:34   ` Linus Walleij
2019-03-01 15:15     ` Marek Behun
2019-03-04 12:07       ` Linus Walleij
2019-03-05 11:11         ` Arnd Bergmann
2019-03-01  3:58 ` [PATCH v3 bus+gpio 4/5] drivers: gpio: Add support for GPIOs over Moxtet bus Marek Behún
2019-03-01  3:58 ` [PATCH v3 bus+gpio 5/5] dt-bindings: gpio: Document GPIOs via " Marek Behún
2019-03-01 14:36   ` Linus Walleij
2019-03-01 15:16     ` Marek Behun
2019-03-03 23:17     ` Marek Behun
2019-03-04  9:53       ` Linus Walleij

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190301035852.26780-3-marek.behun@nic.cz \
    --to=marek.behun@nic.cz \
    --cc=devicetree@vger.kernel.org \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robh+dt@kernel.org \
    --cc=shawnguo@kernel.org \
    --cc=tony@atomide.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).