xref: /freebsd/sys/contrib/device-tree/Bindings/media/fsl,imx6-mipi-csi2.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/media/fsl,imx6-mipi-csi2.yaml#
5*ae5de77eSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6*ae5de77eSEmmanuel Vadot
7*ae5de77eSEmmanuel Vadottitle: MIPI CSI-2 Receiver core in the i.MX SoC
8*ae5de77eSEmmanuel Vadot
9*ae5de77eSEmmanuel Vadotdescription:
10*ae5de77eSEmmanuel Vadot  This is the device node for the MIPI CSI-2 Receiver core in the i.MX
11*ae5de77eSEmmanuel Vadot  SoC. This is a Synopsys Designware MIPI CSI-2 host controller core
12*ae5de77eSEmmanuel Vadot  combined with a D-PHY core mixed into the same register block. In
13*ae5de77eSEmmanuel Vadot  addition this device consists of an i.MX-specific "CSI2IPU gasket"
14*ae5de77eSEmmanuel Vadot  glue logic, also controlled from the same register block. The CSI2IPU
15*ae5de77eSEmmanuel Vadot  gasket demultiplexes the four virtual channel streams from the host
16*ae5de77eSEmmanuel Vadot  controller's 32-bit output image bus onto four 16-bit parallel busses
17*ae5de77eSEmmanuel Vadot  to the i.MX IPU CSIs.
18*ae5de77eSEmmanuel Vadot
19*ae5de77eSEmmanuel Vadotmaintainers:
20*ae5de77eSEmmanuel Vadot  - Frank Li <Frank.Li@nxp.com>
21*ae5de77eSEmmanuel Vadot
22*ae5de77eSEmmanuel Vadotproperties:
23*ae5de77eSEmmanuel Vadot  compatible:
24*ae5de77eSEmmanuel Vadot    const: fsl,imx6-mipi-csi2
25*ae5de77eSEmmanuel Vadot
26*ae5de77eSEmmanuel Vadot  reg:
27*ae5de77eSEmmanuel Vadot    maxItems: 1
28*ae5de77eSEmmanuel Vadot
29*ae5de77eSEmmanuel Vadot  clocks:
30*ae5de77eSEmmanuel Vadot    items:
31*ae5de77eSEmmanuel Vadot      - description: hsi_tx (the D-PHY clock)
32*ae5de77eSEmmanuel Vadot      - description: video_27m (D-PHY PLL reference clock)
33*ae5de77eSEmmanuel Vadot      - description: eim_podf;
34*ae5de77eSEmmanuel Vadot
35*ae5de77eSEmmanuel Vadot  clock-names:
36*ae5de77eSEmmanuel Vadot    items:
37*ae5de77eSEmmanuel Vadot      - const: dphy
38*ae5de77eSEmmanuel Vadot      - const: ref
39*ae5de77eSEmmanuel Vadot      - const: pix
40*ae5de77eSEmmanuel Vadot
41*ae5de77eSEmmanuel Vadot  interrupts:
42*ae5de77eSEmmanuel Vadot    items:
43*ae5de77eSEmmanuel Vadot      - description: CSI-2 ERR1 irq
44*ae5de77eSEmmanuel Vadot      - description: CSI-2 ERR2 irq
45*ae5de77eSEmmanuel Vadot
46*ae5de77eSEmmanuel Vadot  '#address-cells':
47*ae5de77eSEmmanuel Vadot    const: 1
48*ae5de77eSEmmanuel Vadot
49*ae5de77eSEmmanuel Vadot  '#size-cells':
50*ae5de77eSEmmanuel Vadot    const: 0
51*ae5de77eSEmmanuel Vadot
52*ae5de77eSEmmanuel Vadot  port@0:
53*ae5de77eSEmmanuel Vadot    $ref: /schemas/graph.yaml#/$defs/port-base
54*ae5de77eSEmmanuel Vadot    unevaluatedProperties: false
55*ae5de77eSEmmanuel Vadot    description:
56*ae5de77eSEmmanuel Vadot      Input port node, single endpoint describing the CSI-2 transmitter.
57*ae5de77eSEmmanuel Vadot
58*ae5de77eSEmmanuel Vadot    properties:
59*ae5de77eSEmmanuel Vadot      endpoint:
60*ae5de77eSEmmanuel Vadot        $ref: video-interfaces.yaml#
61*ae5de77eSEmmanuel Vadot        unevaluatedProperties: false
62*ae5de77eSEmmanuel Vadot
63*ae5de77eSEmmanuel Vadot        properties:
64*ae5de77eSEmmanuel Vadot          clock-lanes:
65*ae5de77eSEmmanuel Vadot            const: 0
66*ae5de77eSEmmanuel Vadot
67*ae5de77eSEmmanuel Vadot          data-lanes:
68*ae5de77eSEmmanuel Vadot            minItems: 1
69*ae5de77eSEmmanuel Vadot            items:
70*ae5de77eSEmmanuel Vadot              - const: 1
71*ae5de77eSEmmanuel Vadot              - const: 2
72*ae5de77eSEmmanuel Vadot              - const: 3
73*ae5de77eSEmmanuel Vadot              - const: 4
74*ae5de77eSEmmanuel Vadot
75*ae5de77eSEmmanuel Vadot        required:
76*ae5de77eSEmmanuel Vadot          - data-lanes
77*ae5de77eSEmmanuel Vadot
78*ae5de77eSEmmanuel VadotpatternProperties:
79*ae5de77eSEmmanuel Vadot  '^port@[1-4]$':
80*ae5de77eSEmmanuel Vadot    $ref: /schemas/graph.yaml#/$defs/port-base
81*ae5de77eSEmmanuel Vadot    unevaluatedProperties: false
82*ae5de77eSEmmanuel Vadot    description:
83*ae5de77eSEmmanuel Vadot      ports 1 through 4 are output ports connecting with parallel bus sink
84*ae5de77eSEmmanuel Vadot      endpoint nodes and correspond to the four MIPI CSI-2 virtual channel
85*ae5de77eSEmmanuel Vadot      outputs.
86*ae5de77eSEmmanuel Vadot
87*ae5de77eSEmmanuel Vadot    properties:
88*ae5de77eSEmmanuel Vadot      endpoint@0:
89*ae5de77eSEmmanuel Vadot        $ref: video-interfaces.yaml#
90*ae5de77eSEmmanuel Vadot        unevaluatedProperties: false
91*ae5de77eSEmmanuel Vadot
92*ae5de77eSEmmanuel Vadot      endpoint@1:
93*ae5de77eSEmmanuel Vadot        $ref: video-interfaces.yaml#
94*ae5de77eSEmmanuel Vadot        unevaluatedProperties: false
95*ae5de77eSEmmanuel Vadot
96*ae5de77eSEmmanuel Vadotrequired:
97*ae5de77eSEmmanuel Vadot  - compatible
98*ae5de77eSEmmanuel Vadot  - reg
99*ae5de77eSEmmanuel Vadot  - clocks
100*ae5de77eSEmmanuel Vadot  - clock-names
101*ae5de77eSEmmanuel Vadot
102*ae5de77eSEmmanuel VadotadditionalProperties: false
103*ae5de77eSEmmanuel Vadot
104*ae5de77eSEmmanuel Vadotexamples:
105*ae5de77eSEmmanuel Vadot  - |
106*ae5de77eSEmmanuel Vadot    #include <dt-bindings/clock/imx6qdl-clock.h>
107*ae5de77eSEmmanuel Vadot
108*ae5de77eSEmmanuel Vadot    mipi@21dc000 {
109*ae5de77eSEmmanuel Vadot        compatible = "fsl,imx6-mipi-csi2";
110*ae5de77eSEmmanuel Vadot        reg = <0x021dc000 0x4000>;
111*ae5de77eSEmmanuel Vadot        #address-cells = <1>;
112*ae5de77eSEmmanuel Vadot        #size-cells = <0>;
113*ae5de77eSEmmanuel Vadot        clocks = <&clks IMX6QDL_CLK_HSI_TX>,
114*ae5de77eSEmmanuel Vadot                 <&clks IMX6QDL_CLK_VIDEO_27M>,
115*ae5de77eSEmmanuel Vadot                 <&clks IMX6QDL_CLK_EIM_PODF>;
116*ae5de77eSEmmanuel Vadot        clock-names = "dphy", "ref", "pix";
117*ae5de77eSEmmanuel Vadot
118*ae5de77eSEmmanuel Vadot        port@0 {
119*ae5de77eSEmmanuel Vadot            reg = <0>;
120*ae5de77eSEmmanuel Vadot
121*ae5de77eSEmmanuel Vadot            endpoint {
122*ae5de77eSEmmanuel Vadot                remote-endpoint = <&ov5640_to_mipi_csi2>;
123*ae5de77eSEmmanuel Vadot                clock-lanes = <0>;
124*ae5de77eSEmmanuel Vadot                data-lanes = <1 2>;
125*ae5de77eSEmmanuel Vadot            };
126*ae5de77eSEmmanuel Vadot        };
127*ae5de77eSEmmanuel Vadot
128*ae5de77eSEmmanuel Vadot        port@1 {
129*ae5de77eSEmmanuel Vadot            reg = <1>;
130*ae5de77eSEmmanuel Vadot            #address-cells = <1>;
131*ae5de77eSEmmanuel Vadot            #size-cells = <0>;
132*ae5de77eSEmmanuel Vadot
133*ae5de77eSEmmanuel Vadot            endpoint@0 {
134*ae5de77eSEmmanuel Vadot                reg = <0>;
135*ae5de77eSEmmanuel Vadot                remote-endpoint = <&ipu1_csi0_mux_from_mipi_vc0>;
136*ae5de77eSEmmanuel Vadot            };
137*ae5de77eSEmmanuel Vadot
138*ae5de77eSEmmanuel Vadot            endpoint@1 {
139*ae5de77eSEmmanuel Vadot                reg = <1>;
140*ae5de77eSEmmanuel Vadot                remote-endpoint = <&ipu1_csi1_mux_from_mipi_vc0>;
141*ae5de77eSEmmanuel Vadot            };
142*ae5de77eSEmmanuel Vadot        };
143*ae5de77eSEmmanuel Vadot    };
144