xref: /freebsd/sys/contrib/device-tree/Bindings/display/rockchip/rockchip,rk3399-cdn-dp.yaml (revision ae5de77ed78ae54d86cead5604869212e8008e6b)
1*ae5de77eSEmmanuel Vadot# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
2*ae5de77eSEmmanuel Vadot%YAML 1.2
3*ae5de77eSEmmanuel Vadot---
4*ae5de77eSEmmanuel Vadot$id: http://devicetree.org/schemas/display/rockchip/rockchip,rk3399-cdn-dp.yaml#
5*ae5de77eSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6*ae5de77eSEmmanuel Vadot
7*ae5de77eSEmmanuel Vadottitle: Rockchip RK3399 specific extensions to the CDN Display Port
8*ae5de77eSEmmanuel Vadot
9*ae5de77eSEmmanuel Vadotmaintainers:
10*ae5de77eSEmmanuel Vadot  - Andy Yan <andy.yan@rock-chip.com>
11*ae5de77eSEmmanuel Vadot  - Heiko Stuebner <heiko@sntech.de>
12*ae5de77eSEmmanuel Vadot  - Sandy Huang <hjc@rock-chips.com>
13*ae5de77eSEmmanuel Vadot
14*ae5de77eSEmmanuel VadotallOf:
15*ae5de77eSEmmanuel Vadot  - $ref: /schemas/sound/dai-common.yaml#
16*ae5de77eSEmmanuel Vadot
17*ae5de77eSEmmanuel Vadotproperties:
18*ae5de77eSEmmanuel Vadot  compatible:
19*ae5de77eSEmmanuel Vadot    items:
20*ae5de77eSEmmanuel Vadot      - const: rockchip,rk3399-cdn-dp
21*ae5de77eSEmmanuel Vadot
22*ae5de77eSEmmanuel Vadot  reg:
23*ae5de77eSEmmanuel Vadot    maxItems: 1
24*ae5de77eSEmmanuel Vadot
25*ae5de77eSEmmanuel Vadot  clocks:
26*ae5de77eSEmmanuel Vadot    items:
27*ae5de77eSEmmanuel Vadot      - description: DP core work clock
28*ae5de77eSEmmanuel Vadot      - description: APB clock
29*ae5de77eSEmmanuel Vadot      - description: SPDIF interface clock
30*ae5de77eSEmmanuel Vadot      - description: GRF clock
31*ae5de77eSEmmanuel Vadot
32*ae5de77eSEmmanuel Vadot  clock-names:
33*ae5de77eSEmmanuel Vadot    items:
34*ae5de77eSEmmanuel Vadot      - const: core-clk
35*ae5de77eSEmmanuel Vadot      - const: pclk
36*ae5de77eSEmmanuel Vadot      - const: spdif
37*ae5de77eSEmmanuel Vadot      - const: grf
38*ae5de77eSEmmanuel Vadot
39*ae5de77eSEmmanuel Vadot  extcon:
40*ae5de77eSEmmanuel Vadot    $ref: /schemas/types.yaml#/definitions/phandle-array
41*ae5de77eSEmmanuel Vadot    minItems: 1
42*ae5de77eSEmmanuel Vadot    items:
43*ae5de77eSEmmanuel Vadot      - description: Extcon device providing the cable state for DP PHY device 0
44*ae5de77eSEmmanuel Vadot      - description: Extcon device providing the cable state for DP PHY device 1
45*ae5de77eSEmmanuel Vadot    description:
46*ae5de77eSEmmanuel Vadot      List of phandle to the extcon device providing the cable state for the DP PHY.
47*ae5de77eSEmmanuel Vadot
48*ae5de77eSEmmanuel Vadot  interrupts:
49*ae5de77eSEmmanuel Vadot    maxItems: 1
50*ae5de77eSEmmanuel Vadot
51*ae5de77eSEmmanuel Vadot  phys:
52*ae5de77eSEmmanuel Vadot    minItems: 1
53*ae5de77eSEmmanuel Vadot    items:
54*ae5de77eSEmmanuel Vadot      - description: DP output to the DP PHY device 0
55*ae5de77eSEmmanuel Vadot      - description: DP output to the DP PHY device 1
56*ae5de77eSEmmanuel Vadot    description:
57*ae5de77eSEmmanuel Vadot      RK3399 have two DP-USB PHY, specifying one PHY which want to use, or
58*ae5de77eSEmmanuel Vadot      specify two PHYs here to let the driver determine which PHY to use.
59*ae5de77eSEmmanuel Vadot
60*ae5de77eSEmmanuel Vadot  ports:
61*ae5de77eSEmmanuel Vadot    $ref: /schemas/graph.yaml#/properties/ports
62*ae5de77eSEmmanuel Vadot
63*ae5de77eSEmmanuel Vadot    properties:
64*ae5de77eSEmmanuel Vadot      port@0:
65*ae5de77eSEmmanuel Vadot        $ref: /schemas/graph.yaml#/properties/port
66*ae5de77eSEmmanuel Vadot        description: Input of the CDN DP
67*ae5de77eSEmmanuel Vadot
68*ae5de77eSEmmanuel Vadot        properties:
69*ae5de77eSEmmanuel Vadot          endpoint@0:
70*ae5de77eSEmmanuel Vadot            description: Connection to the VOPB
71*ae5de77eSEmmanuel Vadot
72*ae5de77eSEmmanuel Vadot          endpoint@1:
73*ae5de77eSEmmanuel Vadot            description: Connection to the VOPL
74*ae5de77eSEmmanuel Vadot
75*ae5de77eSEmmanuel Vadot      port@1:
76*ae5de77eSEmmanuel Vadot        $ref: /schemas/graph.yaml#/properties/port
77*ae5de77eSEmmanuel Vadot        description: Output of the CDN DP
78*ae5de77eSEmmanuel Vadot
79*ae5de77eSEmmanuel Vadot    required:
80*ae5de77eSEmmanuel Vadot      - port@0
81*ae5de77eSEmmanuel Vadot      - port@1
82*ae5de77eSEmmanuel Vadot
83*ae5de77eSEmmanuel Vadot  power-domains:
84*ae5de77eSEmmanuel Vadot    maxItems: 1
85*ae5de77eSEmmanuel Vadot
86*ae5de77eSEmmanuel Vadot  resets:
87*ae5de77eSEmmanuel Vadot    maxItems: 4
88*ae5de77eSEmmanuel Vadot
89*ae5de77eSEmmanuel Vadot  reset-names:
90*ae5de77eSEmmanuel Vadot    items:
91*ae5de77eSEmmanuel Vadot      - const: spdif
92*ae5de77eSEmmanuel Vadot      - const: dptx
93*ae5de77eSEmmanuel Vadot      - const: apb
94*ae5de77eSEmmanuel Vadot      - const: core
95*ae5de77eSEmmanuel Vadot
96*ae5de77eSEmmanuel Vadot  rockchip,grf:
97*ae5de77eSEmmanuel Vadot    $ref: /schemas/types.yaml#/definitions/phandle
98*ae5de77eSEmmanuel Vadot    description:
99*ae5de77eSEmmanuel Vadot      Phandle to GRF register to control HPD.
100*ae5de77eSEmmanuel Vadot
101*ae5de77eSEmmanuel Vadot  "#sound-dai-cells":
102*ae5de77eSEmmanuel Vadot    const: 1
103*ae5de77eSEmmanuel Vadot
104*ae5de77eSEmmanuel Vadotrequired:
105*ae5de77eSEmmanuel Vadot  - compatible
106*ae5de77eSEmmanuel Vadot  - reg
107*ae5de77eSEmmanuel Vadot  - clocks
108*ae5de77eSEmmanuel Vadot  - clock-names
109*ae5de77eSEmmanuel Vadot  - interrupts
110*ae5de77eSEmmanuel Vadot  - phys
111*ae5de77eSEmmanuel Vadot  - ports
112*ae5de77eSEmmanuel Vadot  - resets
113*ae5de77eSEmmanuel Vadot  - reset-names
114*ae5de77eSEmmanuel Vadot  - rockchip,grf
115*ae5de77eSEmmanuel Vadot  - "#sound-dai-cells"
116*ae5de77eSEmmanuel Vadot
117*ae5de77eSEmmanuel VadotunevaluatedProperties: false
118*ae5de77eSEmmanuel Vadot
119*ae5de77eSEmmanuel Vadotexamples:
120*ae5de77eSEmmanuel Vadot  - |
121*ae5de77eSEmmanuel Vadot    #include <dt-bindings/clock/rk3399-cru.h>
122*ae5de77eSEmmanuel Vadot    #include <dt-bindings/interrupt-controller/arm-gic.h>
123*ae5de77eSEmmanuel Vadot    #include <dt-bindings/power/rk3399-power.h>
124*ae5de77eSEmmanuel Vadot    soc {
125*ae5de77eSEmmanuel Vadot        #address-cells = <2>;
126*ae5de77eSEmmanuel Vadot        #size-cells = <2>;
127*ae5de77eSEmmanuel Vadot
128*ae5de77eSEmmanuel Vadot        dp@fec00000 {
129*ae5de77eSEmmanuel Vadot            compatible = "rockchip,rk3399-cdn-dp";
130*ae5de77eSEmmanuel Vadot            reg = <0x0 0xfec00000 0x0 0x100000>;
131*ae5de77eSEmmanuel Vadot            assigned-clocks = <&cru SCLK_DP_CORE>;
132*ae5de77eSEmmanuel Vadot            assigned-clock-rates = <100000000>;
133*ae5de77eSEmmanuel Vadot            interrupts = <GIC_SPI 9 IRQ_TYPE_LEVEL_HIGH>;
134*ae5de77eSEmmanuel Vadot            clocks = <&cru SCLK_DP_CORE>, <&cru PCLK_DP_CTRL>, <&cru SCLK_SPDIF_REC_DPTX>,
135*ae5de77eSEmmanuel Vadot                    <&cru PCLK_VIO_GRF>;
136*ae5de77eSEmmanuel Vadot            clock-names = "core-clk", "pclk", "spdif", "grf";
137*ae5de77eSEmmanuel Vadot            power-domains = <&power RK3399_PD_HDCP>;
138*ae5de77eSEmmanuel Vadot            phys = <&tcphy0_dp>, <&tcphy1_dp>;
139*ae5de77eSEmmanuel Vadot            resets = <&cru SRST_DPTX_SPDIF_REC>, <&cru SRST_P_UPHY0_DPTX>,
140*ae5de77eSEmmanuel Vadot                    <&cru SRST_P_UPHY0_APB>, <&cru SRST_DP_CORE>;
141*ae5de77eSEmmanuel Vadot            reset-names = "spdif", "dptx", "apb", "core";
142*ae5de77eSEmmanuel Vadot            rockchip,grf = <&grf>;
143*ae5de77eSEmmanuel Vadot            #sound-dai-cells = <1>;
144*ae5de77eSEmmanuel Vadot
145*ae5de77eSEmmanuel Vadot            ports {
146*ae5de77eSEmmanuel Vadot                #address-cells = <1>;
147*ae5de77eSEmmanuel Vadot                #size-cells = <0>;
148*ae5de77eSEmmanuel Vadot
149*ae5de77eSEmmanuel Vadot                dp_in: port@0 {
150*ae5de77eSEmmanuel Vadot                    reg = <0>;
151*ae5de77eSEmmanuel Vadot                    #address-cells = <1>;
152*ae5de77eSEmmanuel Vadot                    #size-cells = <0>;
153*ae5de77eSEmmanuel Vadot
154*ae5de77eSEmmanuel Vadot                    dp_in_vopb: endpoint@0 {
155*ae5de77eSEmmanuel Vadot                        reg = <0>;
156*ae5de77eSEmmanuel Vadot                        remote-endpoint = <&vopb_out_dp>;
157*ae5de77eSEmmanuel Vadot                    };
158*ae5de77eSEmmanuel Vadot
159*ae5de77eSEmmanuel Vadot                    dp_in_vopl: endpoint@1 {
160*ae5de77eSEmmanuel Vadot                        reg = <1>;
161*ae5de77eSEmmanuel Vadot                        remote-endpoint = <&vopl_out_dp>;
162*ae5de77eSEmmanuel Vadot                    };
163*ae5de77eSEmmanuel Vadot                };
164*ae5de77eSEmmanuel Vadot
165*ae5de77eSEmmanuel Vadot                dp_out: port@1 {
166*ae5de77eSEmmanuel Vadot                    reg = <1>;
167*ae5de77eSEmmanuel Vadot                };
168*ae5de77eSEmmanuel Vadot            };
169*ae5de77eSEmmanuel Vadot        };
170*ae5de77eSEmmanuel Vadot    };
171