xref: /freebsd/sys/contrib/device-tree/Bindings/display/bridge/toshiba,tc358767.yaml (revision 5ca8e32633c4ffbbcd6762e5888b6a4ba0708c6c)
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/toshiba,tc358767.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: Toshiba TC358767/TC358867/TC9595 DSI/DPI/eDP bridge
8
9maintainers:
10  - Andrey Gusakov <andrey.gusakov@cogentembedded.com>
11
12description: |
13  The TC358767/TC358867/TC9595 is bridge device which
14  converts DSI/DPI to eDP/DP .
15
16properties:
17  compatible:
18    oneOf:
19      - items:
20          - enum:
21              - toshiba,tc358867
22              - toshiba,tc9595
23          - const: toshiba,tc358767
24      - const: toshiba,tc358767
25
26  reg:
27    enum:
28      - 0x68
29      - 0x0f
30    description: |
31        i2c address of the bridge, 0x68 or 0x0f, depending on bootstrap pins
32
33  clock-names:
34    const: ref
35
36  clocks:
37    maxItems: 1
38    description: |
39        OF device-tree clock specification for refclk input. The reference.
40        clock rate must be 13 MHz, 19.2 MHz, 26 MHz, or 38.4 MHz.
41
42  shutdown-gpios:
43    maxItems: 1
44    description: |
45        OF device-tree gpio specification for SD pin(active high shutdown input)
46
47  reset-gpios:
48    maxItems: 1
49    description: |
50        OF device-tree gpio specification for RSTX pin(active low system reset)
51
52  toshiba,hpd-pin:
53    $ref: /schemas/types.yaml#/definitions/uint32
54    enum:
55      - 0
56      - 1
57    description: TC358767 GPIO pin number to which HPD is connected to (0 or 1)
58
59  ports:
60    $ref: /schemas/graph.yaml#/properties/ports
61
62    properties:
63      port@0:
64        $ref: /schemas/graph.yaml#/$defs/port-base
65        unevaluatedProperties: false
66        description: |
67            DSI input port. The remote endpoint phandle should be a
68            reference to a valid DSI output endpoint node
69
70        properties:
71          endpoint:
72            $ref: /schemas/media/video-interfaces.yaml#
73            unevaluatedProperties: false
74
75            properties:
76              data-lanes:
77                description: array of physical DSI data lane indexes.
78                minItems: 1
79                items:
80                  - const: 1
81                  - const: 2
82                  - const: 3
83                  - const: 4
84
85      port@1:
86        $ref: /schemas/graph.yaml#/properties/port
87        description: |
88            DPI input/output port. The remote endpoint phandle should be a
89            reference to a valid DPI output or input endpoint node.
90
91      port@2:
92        $ref: /schemas/graph.yaml#/properties/port
93        description: |
94            eDP/DP output port. The remote endpoint phandle should be a
95            reference to a valid eDP panel input endpoint node. This port is
96            optional, treated as DP panel if not defined
97
98    oneOf:
99      - required:
100          - port@0
101      - required:
102          - port@1
103
104
105required:
106  - compatible
107  - reg
108  - clock-names
109  - clocks
110  - ports
111
112additionalProperties: false
113
114examples:
115  - |
116    #include <dt-bindings/gpio/gpio.h>
117
118    /* DPI input and eDP output */
119
120    i2c {
121        #address-cells = <1>;
122        #size-cells = <0>;
123
124        edp-bridge@68 {
125            compatible = "toshiba,tc358767";
126            reg = <0x68>;
127            shutdown-gpios = <&gpio3 23 GPIO_ACTIVE_HIGH>;
128            reset-gpios = <&gpio3 24 GPIO_ACTIVE_LOW>;
129            clock-names = "ref";
130            clocks = <&edp_refclk>;
131
132            ports {
133                #address-cells = <1>;
134                #size-cells = <0>;
135
136                port@1 {
137                    reg = <1>;
138
139                    bridge_in_0: endpoint {
140                        remote-endpoint = <&dpi_out>;
141                    };
142                };
143
144                port@2 {
145                    reg = <2>;
146
147                    bridge_out: endpoint {
148                        remote-endpoint = <&panel_in>;
149                    };
150                };
151            };
152        };
153    };
154  - |
155    /* DPI input and DP output */
156
157    i2c {
158        #address-cells = <1>;
159        #size-cells = <0>;
160
161        edp-bridge@68 {
162            compatible = "toshiba,tc358767";
163            reg = <0x68>;
164            shutdown-gpios = <&gpio3 23 GPIO_ACTIVE_HIGH>;
165            reset-gpios = <&gpio3 24 GPIO_ACTIVE_LOW>;
166            clock-names = "ref";
167            clocks = <&edp_refclk>;
168
169            ports {
170                #address-cells = <1>;
171                #size-cells = <0>;
172
173                port@1 {
174                    reg = <1>;
175
176                    bridge_in_1: endpoint {
177                        remote-endpoint = <&dpi_out>;
178                    };
179                };
180            };
181        };
182    };
183