xref: /freebsd/sys/contrib/device-tree/Bindings/media/amlogic,c3-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/amlogic,c3-mipi-csi2.yaml#
5*ae5de77eSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6*ae5de77eSEmmanuel Vadot
7*ae5de77eSEmmanuel Vadottitle: Amlogic C3 MIPI CSI-2 receiver
8*ae5de77eSEmmanuel Vadot
9*ae5de77eSEmmanuel Vadotmaintainers:
10*ae5de77eSEmmanuel Vadot  - Keke Li <keke.li@amlogic.com>
11*ae5de77eSEmmanuel Vadot
12*ae5de77eSEmmanuel Vadotdescription:
13*ae5de77eSEmmanuel Vadot  MIPI CSI-2 receiver contains CSI-2 RX PHY and host controller.
14*ae5de77eSEmmanuel Vadot  It receives the MIPI data from the image sensor and sends MIPI data
15*ae5de77eSEmmanuel Vadot  to MIPI adapter.
16*ae5de77eSEmmanuel Vadot
17*ae5de77eSEmmanuel Vadotproperties:
18*ae5de77eSEmmanuel Vadot  compatible:
19*ae5de77eSEmmanuel Vadot    enum:
20*ae5de77eSEmmanuel Vadot      - amlogic,c3-mipi-csi2
21*ae5de77eSEmmanuel Vadot
22*ae5de77eSEmmanuel Vadot  reg:
23*ae5de77eSEmmanuel Vadot    maxItems: 3
24*ae5de77eSEmmanuel Vadot
25*ae5de77eSEmmanuel Vadot  reg-names:
26*ae5de77eSEmmanuel Vadot    items:
27*ae5de77eSEmmanuel Vadot      - const: aphy
28*ae5de77eSEmmanuel Vadot      - const: dphy
29*ae5de77eSEmmanuel Vadot      - const: host
30*ae5de77eSEmmanuel Vadot
31*ae5de77eSEmmanuel Vadot  power-domains:
32*ae5de77eSEmmanuel Vadot    maxItems: 1
33*ae5de77eSEmmanuel Vadot
34*ae5de77eSEmmanuel Vadot  clocks:
35*ae5de77eSEmmanuel Vadot    maxItems: 2
36*ae5de77eSEmmanuel Vadot
37*ae5de77eSEmmanuel Vadot  clock-names:
38*ae5de77eSEmmanuel Vadot    items:
39*ae5de77eSEmmanuel Vadot      - const: vapb
40*ae5de77eSEmmanuel Vadot      - const: phy0
41*ae5de77eSEmmanuel Vadot
42*ae5de77eSEmmanuel Vadot  ports:
43*ae5de77eSEmmanuel Vadot    $ref: /schemas/graph.yaml#/properties/ports
44*ae5de77eSEmmanuel Vadot
45*ae5de77eSEmmanuel Vadot    properties:
46*ae5de77eSEmmanuel Vadot      port@0:
47*ae5de77eSEmmanuel Vadot        $ref: /schemas/graph.yaml#/$defs/port-base
48*ae5de77eSEmmanuel Vadot        unevaluatedProperties: false
49*ae5de77eSEmmanuel Vadot        description: input port node, connected to sensor.
50*ae5de77eSEmmanuel Vadot
51*ae5de77eSEmmanuel Vadot        properties:
52*ae5de77eSEmmanuel Vadot          endpoint:
53*ae5de77eSEmmanuel Vadot            $ref: video-interfaces.yaml#
54*ae5de77eSEmmanuel Vadot            unevaluatedProperties: false
55*ae5de77eSEmmanuel Vadot
56*ae5de77eSEmmanuel Vadot            properties:
57*ae5de77eSEmmanuel Vadot              data-lanes:
58*ae5de77eSEmmanuel Vadot                minItems: 1
59*ae5de77eSEmmanuel Vadot                maxItems: 4
60*ae5de77eSEmmanuel Vadot
61*ae5de77eSEmmanuel Vadot            required:
62*ae5de77eSEmmanuel Vadot              - data-lanes
63*ae5de77eSEmmanuel Vadot
64*ae5de77eSEmmanuel Vadot      port@1:
65*ae5de77eSEmmanuel Vadot        $ref: /schemas/graph.yaml#/properties/port
66*ae5de77eSEmmanuel Vadot        description: output port node
67*ae5de77eSEmmanuel Vadot
68*ae5de77eSEmmanuel Vadot    required:
69*ae5de77eSEmmanuel Vadot      - port@0
70*ae5de77eSEmmanuel Vadot      - port@1
71*ae5de77eSEmmanuel Vadot
72*ae5de77eSEmmanuel Vadotrequired:
73*ae5de77eSEmmanuel Vadot  - compatible
74*ae5de77eSEmmanuel Vadot  - reg
75*ae5de77eSEmmanuel Vadot  - reg-names
76*ae5de77eSEmmanuel Vadot  - power-domains
77*ae5de77eSEmmanuel Vadot  - clocks
78*ae5de77eSEmmanuel Vadot  - clock-names
79*ae5de77eSEmmanuel Vadot  - ports
80*ae5de77eSEmmanuel Vadot
81*ae5de77eSEmmanuel VadotadditionalProperties: false
82*ae5de77eSEmmanuel Vadot
83*ae5de77eSEmmanuel Vadotexamples:
84*ae5de77eSEmmanuel Vadot  - |
85*ae5de77eSEmmanuel Vadot    #include <dt-bindings/clock/amlogic,c3-peripherals-clkc.h>
86*ae5de77eSEmmanuel Vadot    #include <dt-bindings/power/amlogic,c3-pwrc.h>
87*ae5de77eSEmmanuel Vadot
88*ae5de77eSEmmanuel Vadot    soc {
89*ae5de77eSEmmanuel Vadot        #address-cells = <2>;
90*ae5de77eSEmmanuel Vadot        #size-cells = <2>;
91*ae5de77eSEmmanuel Vadot
92*ae5de77eSEmmanuel Vadot        csi: csi@ff018000 {
93*ae5de77eSEmmanuel Vadot            compatible = "amlogic,c3-mipi-csi2";
94*ae5de77eSEmmanuel Vadot            reg = <0x0 0xff018000 0x0 0x400>,
95*ae5de77eSEmmanuel Vadot                  <0x0 0xff019000 0x0 0x300>,
96*ae5de77eSEmmanuel Vadot                  <0x0 0xff01a000 0x0 0x100>;
97*ae5de77eSEmmanuel Vadot            reg-names = "aphy", "dphy", "host";
98*ae5de77eSEmmanuel Vadot            power-domains = <&pwrc PWRC_C3_MIPI_ISP_WRAP_ID>;
99*ae5de77eSEmmanuel Vadot            clocks =  <&clkc_periphs CLKID_VAPB>,
100*ae5de77eSEmmanuel Vadot                      <&clkc_periphs CLKID_CSI_PHY0>;
101*ae5de77eSEmmanuel Vadot            clock-names = "vapb", "phy0";
102*ae5de77eSEmmanuel Vadot            assigned-clocks = <&clkc_periphs CLKID_VAPB>,
103*ae5de77eSEmmanuel Vadot                              <&clkc_periphs CLKID_CSI_PHY0>;
104*ae5de77eSEmmanuel Vadot            assigned-clock-rates = <0>, <200000000>;
105*ae5de77eSEmmanuel Vadot
106*ae5de77eSEmmanuel Vadot            ports {
107*ae5de77eSEmmanuel Vadot                #address-cells = <1>;
108*ae5de77eSEmmanuel Vadot                #size-cells = <0>;
109*ae5de77eSEmmanuel Vadot
110*ae5de77eSEmmanuel Vadot                port@0 {
111*ae5de77eSEmmanuel Vadot                    reg = <0>;
112*ae5de77eSEmmanuel Vadot                    c3_mipi_csi_in: endpoint {
113*ae5de77eSEmmanuel Vadot                        remote-endpoint = <&imx290_out>;
114*ae5de77eSEmmanuel Vadot                        data-lanes = <1 2 3 4>;
115*ae5de77eSEmmanuel Vadot                    };
116*ae5de77eSEmmanuel Vadot                };
117*ae5de77eSEmmanuel Vadot
118*ae5de77eSEmmanuel Vadot                port@1 {
119*ae5de77eSEmmanuel Vadot                    reg = <1>;
120*ae5de77eSEmmanuel Vadot                    c3_mipi_csi_out: endpoint {
121*ae5de77eSEmmanuel Vadot                        remote-endpoint = <&c3_adap_in>;
122*ae5de77eSEmmanuel Vadot                    };
123*ae5de77eSEmmanuel Vadot                };
124*ae5de77eSEmmanuel Vadot            };
125*ae5de77eSEmmanuel Vadot        };
126*ae5de77eSEmmanuel Vadot    };
127*ae5de77eSEmmanuel Vadot...
128