Merge tag 'warning-fixes-20211005' of git://git.kernel.org/pub/scm/linux/kernel/git...
[muen/linux.git] / Documentation / devicetree / bindings / display / bridge / ti,sn65dsi83.yaml
1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2 %YAML 1.2
3 ---
4 $id: http://devicetree.org/schemas/display/bridge/ti,sn65dsi83.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
6
7 title: SN65DSI83 and SN65DSI84 DSI to LVDS bridge chip
8
9 maintainers:
10   - Marek Vasut <marex@denx.de>
11
12 description: |
13   Texas Instruments SN65DSI83 1x Single-link MIPI DSI
14   to 1x Single-link LVDS
15   https://www.ti.com/lit/gpn/sn65dsi83
16   Texas Instruments SN65DSI84 1x Single-link MIPI DSI
17   to 1x Dual-link or 2x Single-link LVDS
18   https://www.ti.com/lit/gpn/sn65dsi84
19
20 properties:
21   compatible:
22     enum:
23       - ti,sn65dsi83
24       - ti,sn65dsi84
25
26   reg:
27     enum:
28       - 0x2c
29       - 0x2d
30
31   enable-gpios:
32     maxItems: 1
33     description: GPIO specifier for bridge_en pin (active high).
34
35   ports:
36     $ref: /schemas/graph.yaml#/properties/ports
37
38     properties:
39       port@0:
40         $ref: /schemas/graph.yaml#/$defs/port-base
41         unevaluatedProperties: false
42         description: Video port for MIPI DSI Channel-A input
43
44         properties:
45           endpoint:
46             $ref: /schemas/media/video-interfaces.yaml#
47             unevaluatedProperties: false
48
49             properties:
50               data-lanes:
51                 description: array of physical DSI data lane indexes.
52                 minItems: 1
53                 maxItems: 4
54                 items:
55                   - const: 1
56                   - const: 2
57                   - const: 3
58                   - const: 4
59
60       port@1:
61         $ref: /schemas/graph.yaml#/$defs/port-base
62         unevaluatedProperties: false
63         description: Video port for MIPI DSI Channel-B input
64
65         properties:
66           endpoint:
67             $ref: /schemas/media/video-interfaces.yaml#
68             unevaluatedProperties: false
69
70             properties:
71               data-lanes:
72                 description: array of physical DSI data lane indexes.
73                 minItems: 1
74                 maxItems: 4
75                 items:
76                   - const: 1
77                   - const: 2
78                   - const: 3
79                   - const: 4
80
81       port@2:
82         $ref: /schemas/graph.yaml#/properties/port
83         description: Video port for LVDS Channel-A output (panel or bridge).
84
85       port@3:
86         $ref: /schemas/graph.yaml#/properties/port
87         description: Video port for LVDS Channel-B output (panel or bridge).
88
89     required:
90       - port@0
91       - port@2
92
93 required:
94   - compatible
95   - reg
96   - enable-gpios
97   - ports
98
99 allOf:
100   - if:
101       properties:
102         compatible:
103           contains:
104             const: ti,sn65dsi83
105     then:
106       properties:
107         ports:
108           properties:
109             port@1: false
110             port@3: false
111
112   - if:
113       properties:
114         compatible:
115           contains:
116             const: ti,sn65dsi84
117     then:
118       properties:
119         ports:
120           properties:
121             port@1: false
122
123 additionalProperties: false
124
125 examples:
126   - |
127     #include <dt-bindings/gpio/gpio.h>
128
129     i2c {
130         #address-cells = <1>;
131         #size-cells = <0>;
132
133         bridge@2d {
134             compatible = "ti,sn65dsi83";
135             reg = <0x2d>;
136
137             enable-gpios = <&gpio2 1 GPIO_ACTIVE_HIGH>;
138
139             ports {
140                 #address-cells = <1>;
141                 #size-cells = <0>;
142
143                 port@0 {
144                     reg = <0>;
145
146                     endpoint {
147                         remote-endpoint = <&dsi0_out>;
148                         data-lanes = <1 2 3 4>;
149                     };
150                 };
151
152                 port@2 {
153                     reg = <2>;
154
155                     endpoint {
156                         remote-endpoint = <&panel_in_lvds>;
157                     };
158                 };
159             };
160         };
161     };