linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rob Herring <robh@kernel.org>
To: dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org
Cc: linux-kernel@vger.kernel.org,
	Thierry Reding <thierry.reding@gmail.com>,
	Sam Ravnborg <sam@ravnborg.org>,
	Maxime Ripard <maxime.ripard@bootlin.com>,
	Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
	Linus Walleij <linus.walleij@linaro.org>
Subject: [PATCH v2 10/15] dt-bindings: display: Convert tpo,tpg110 panel to DT schema
Date: Mon, 24 Jun 2019 15:56:44 -0600	[thread overview]
Message-ID: <20190624215649.8939-11-robh@kernel.org> (raw)
In-Reply-To: <20190624215649.8939-1-robh@kernel.org>

Convert the tpo,tpg110 panel binding to DT schema.

Cc: Linus Walleij <linus.walleij@linaro.org>
Cc: Thierry Reding <thierry.reding@gmail.com>
Cc: Sam Ravnborg <sam@ravnborg.org>
Cc: Maxime Ripard <maxime.ripard@bootlin.com>
Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Rob Herring <robh@kernel.org>
---
 .../bindings/display/panel/tpo,tpg110.txt     |  70 ------------
 .../bindings/display/panel/tpo,tpg110.yaml    | 101 ++++++++++++++++++
 2 files changed, 101 insertions(+), 70 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/display/panel/tpo,tpg110.txt
 create mode 100644 Documentation/devicetree/bindings/display/panel/tpo,tpg110.yaml

diff --git a/Documentation/devicetree/bindings/display/panel/tpo,tpg110.txt b/Documentation/devicetree/bindings/display/panel/tpo,tpg110.txt
deleted file mode 100644
index 40f3d7c713bb..000000000000
--- a/Documentation/devicetree/bindings/display/panel/tpo,tpg110.txt
+++ /dev/null
@@ -1,70 +0,0 @@
-TPO TPG110 Panel
-================
-
-This panel driver is a component that acts as an intermediary
-between an RGB output and a variety of panels. The panel
-driver is strapped up in electronics to the desired resolution
-and other properties, and has a control interface over 3WIRE
-SPI. By talking to the TPG110 over SPI, the strapped properties
-can be discovered and the hardware is therefore mostly
-self-describing.
-
-       +--------+
-SPI -> |  TPO   | -> physical display
-RGB -> | TPG110 |
-       +--------+
-
-If some electrical strap or alternate resolution is desired,
-this can be set up by taking software control of the display
-over the SPI interface. The interface can also adjust
-for properties of the display such as gamma correction and
-certain electrical driving levels.
-
-The TPG110 does not know the physical dimensions of the panel
-connected, so this needs to be specified in the device tree.
-
-It requires a GPIO line for control of its reset line.
-
-The serial protocol has line names that resemble I2C but the
-protocol is not I2C but 3WIRE SPI.
-
-Required properties:
-- compatible : one of:
-  "ste,nomadik-nhk15-display", "tpo,tpg110"
-  "tpo,tpg110"
-- grestb-gpios : panel reset GPIO
-- width-mm : see display/panel/panel-common.txt
-- height-mm : see display/panel/panel-common.txt
-
-The device needs to be a child of an SPI bus, see
-spi/spi-bus.txt. The SPI child must set the following
-properties:
-- spi-3wire
-- spi-max-frequency = <3000000>;
-as these are characteristics of this device.
-
-The device node can contain one 'port' child node with one child
-'endpoint' node, according to the bindings defined in
-media/video-interfaces.txt. This node should describe panel's video bus.
-
-Example
--------
-
-panel: display@0 {
-	compatible = "tpo,tpg110";
-	reg = <0>;
-	spi-3wire;
-	/* 320 ns min period ~= 3 MHz */
-	spi-max-frequency = <3000000>;
-	/* Width and height from data sheet */
-	width-mm = <116>;
-	height-mm = <87>;
-	grestb-gpios = <&foo_gpio 5 GPIO_ACTIVE_LOW>;
-	backlight = <&bl>;
-
-	port {
-		nomadik_clcd_panel: endpoint {
-			remote-endpoint = <&foo>;
-		};
-	};
-};
diff --git a/Documentation/devicetree/bindings/display/panel/tpo,tpg110.yaml b/Documentation/devicetree/bindings/display/panel/tpo,tpg110.yaml
new file mode 100644
index 000000000000..a51660b73f28
--- /dev/null
+++ b/Documentation/devicetree/bindings/display/panel/tpo,tpg110.yaml
@@ -0,0 +1,101 @@
+# SPDX-License-Identifier: GPL-2.0
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/display/panel/tpo,tpg110.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: TPO TPG110 Panel
+
+maintainers:
+  - Linus Walleij <linus.walleij@linaro.org>
+  - Thierry Reding <thierry.reding@gmail.com>
+
+description: |+
+  This panel driver is a component that acts as an intermediary
+  between an RGB output and a variety of panels. The panel
+  driver is strapped up in electronics to the desired resolution
+  and other properties, and has a control interface over 3WIRE
+  SPI. By talking to the TPG110 over SPI, the strapped properties
+  can be discovered and the hardware is therefore mostly
+  self-describing.
+
+         +--------+
+  SPI -> |  TPO   | -> physical display
+  RGB -> | TPG110 |
+         +--------+
+
+  If some electrical strap or alternate resolution is desired,
+  this can be set up by taking software control of the display
+  over the SPI interface. The interface can also adjust
+  for properties of the display such as gamma correction and
+  certain electrical driving levels.
+
+  The TPG110 does not know the physical dimensions of the panel
+  connected, so this needs to be specified in the device tree.
+
+  It requires a GPIO line for control of its reset line.
+
+  The serial protocol has line names that resemble I2C but the
+  protocol is not I2C but 3WIRE SPI.
+
+
+allOf:
+  - $ref: panel-common.yaml#
+
+properties:
+  compatible:
+    oneOf:
+      - items:
+          - enum:
+              - ste,nomadik-nhk15-display
+          - const: tpo,tpg110
+      - const: tpo,tpg110
+
+  reg: true
+
+  grestb-gpios:
+    maxItems: 1
+    description: panel reset GPIO
+
+  spi-3wire: true
+
+  spi-max-frequency:
+    const: 3000000
+
+required:
+  - compatible
+  - reg
+  - grestb-gpios
+  - width-mm
+  - height-mm
+  - spi-3wire
+  - spi-max-frequency
+  - port
+
+examples:
+  - |+
+    spi {
+      #address-cells = <1>;
+      #size-cells = <0>;
+
+      panel: display@0 {
+        compatible = "tpo,tpg110";
+        reg = <0>;
+        spi-3wire;
+        /* 320 ns min period ~= 3 MHz */
+        spi-max-frequency = <3000000>;
+        /* Width and height from data sheet */
+        width-mm = <116>;
+        height-mm = <87>;
+        grestb-gpios = <&foo_gpio 5 1>;
+        backlight = <&bl>;
+
+        port {
+          nomadik_clcd_panel: endpoint {
+            remote-endpoint = <&foo>;
+          };
+        };
+      };
+    };
+
+...
-- 
2.20.1


  parent reply	other threads:[~2019-06-24 21:59 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-24 21:56 [PATCH v2 00/15] Conversion of panel bindings to DT schema Rob Herring
2019-06-24 21:56 ` [PATCH v2 01/15] dt-bindings: display: rockchip-lvds: Remove panel references Rob Herring
2019-06-27  8:37   ` Heiko Stuebner
2019-06-24 21:56 ` [PATCH v2 02/15] dt-bindings: display: Convert common panel bindings to DT schema Rob Herring
2019-06-24 21:56 ` [PATCH v2 03/15] dt-bindings: display: Convert ampire,am-480272h3tmqw-t01h panel " Rob Herring
2019-06-24 21:56 ` [PATCH v2 04/15] dt-bindings: display: Convert armadeus,st0700-adapt " Rob Herring
2019-06-25  7:51   ` Maxime Ripard
2019-06-24 21:56 ` [PATCH v2 05/15] dt-bindings: display: Convert bananapi,s070wv20-ct16 " Rob Herring
2019-06-25  7:54   ` Maxime Ripard
2019-06-24 21:56 ` [PATCH v2 06/15] dt-bindings: display: Convert dlc,dlc0700yzg-1 " Rob Herring
2019-06-25  7:55   ` Maxime Ripard
2019-06-25 14:15     ` Rob Herring
2019-06-24 21:56 ` [PATCH v2 07/15] dt-bindings: display: Convert pda,91-00156-a0 " Rob Herring
2019-06-25  7:56   ` Maxime Ripard
2019-06-24 21:56 ` [PATCH v2 08/15] dt-bindings: display: Convert raspberrypi,7inch-touchscreen " Rob Herring
2019-06-25  7:56   ` Maxime Ripard
2019-06-24 21:56 ` [PATCH v2 09/15] dt-bindings: display: Convert tfc,s9700rtwv43tr-01b " Rob Herring
2019-06-25  7:57   ` Maxime Ripard
2019-06-24 21:56 ` Rob Herring [this message]
2019-06-24 22:13   ` [PATCH v2 10/15] dt-bindings: display: Convert tpo,tpg110 " Linus Walleij
2019-06-24 22:47     ` Rob Herring
2019-06-25  8:26       ` Linus Walleij
2019-06-25 14:25         ` Rob Herring
2019-06-25 21:47           ` Linus Walleij
2019-06-25  8:00   ` Maxime Ripard
2019-06-24 21:56 ` [PATCH v2 11/15] dt-bindings: display: Convert panel-lvds " Rob Herring
2019-06-24 21:56 ` [PATCH v2 12/15] dt-bindings: display: Convert innolux,ee101ia-01 panel " Rob Herring
2019-06-24 21:56 ` [PATCH v2 13/15] dt-bindings: display: Convert mitsubishi,aa104xd12 " Rob Herring
2019-06-25  7:58   ` Maxime Ripard
2019-06-24 21:56 ` [PATCH v2 14/15] dt-bindings: display: Convert mitsubishi,aa121td01 " Rob Herring
2019-06-25  7:59   ` Maxime Ripard
2019-06-24 21:56 ` [PATCH v2 15/15] dt-bindings: display: Convert sgd,gktw70sdae4se " Rob Herring
2019-06-25  7:59   ` Maxime Ripard

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=20190624215649.8939-11-robh@kernel.org \
    --to=robh@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maxime.ripard@bootlin.com \
    --cc=sam@ravnborg.org \
    --cc=thierry.reding@gmail.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).