1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2%YAML 1.2 3--- 4$id: http://devicetree.org/schemas/media/xilinx/xlnx,csi2rxss.yaml# 5$schema: http://devicetree.org/meta-schemas/core.yaml# 6 7title: Xilinx MIPI CSI-2 Receiver Subsystem 8 9maintainers: 10 - Vishal Sagar <vishal.sagar@xilinx.com> 11 12description: | 13 The Xilinx MIPI CSI-2 Receiver Subsystem is used to capture MIPI CSI-2 14 traffic from compliant camera sensors and send the output as AXI4 Stream 15 video data for image processing. 16 The subsystem consists of a MIPI D-PHY in slave mode which captures the 17 data packets. This is passed along the MIPI CSI-2 Rx IP which extracts the 18 packet data. The optional Video Format Bridge (VFB) converts this data to 19 AXI4 Stream video data. 20 For more details, please refer to PG232 Xilinx MIPI CSI-2 Receiver Subsystem. 21 Please note that this bindings includes only the MIPI CSI-2 Rx controller 22 and Video Format Bridge and not D-PHY. 23 24properties: 25 compatible: 26 items: 27 - enum: 28 - xlnx,mipi-csi2-rx-subsystem-5.0 29 30 reg: 31 maxItems: 1 32 33 interrupts: 34 maxItems: 1 35 36 clocks: 37 description: List of clock specifiers 38 items: 39 - description: AXI Lite clock 40 - description: Video clock 41 42 clock-names: 43 items: 44 - const: lite_aclk 45 - const: video_aclk 46 47 xlnx,csi-pxl-format: 48 description: | 49 This denotes the CSI Data type selected in hw design. 50 Packets other than this data type (except for RAW8 and 51 User defined data types) will be filtered out. 52 Possible values are as below - 53 0x1e - YUV4228B 54 0x1f - YUV42210B 55 0x20 - RGB444 56 0x21 - RGB555 57 0x22 - RGB565 58 0x23 - RGB666 59 0x24 - RGB888 60 0x28 - RAW6 61 0x29 - RAW7 62 0x2a - RAW8 63 0x2b - RAW10 64 0x2c - RAW12 65 0x2d - RAW14 66 0x2e - RAW16 67 0x2f - RAW20 68 $ref: /schemas/types.yaml#/definitions/uint32 69 oneOf: 70 - minimum: 0x1e 71 maximum: 0x24 72 - minimum: 0x28 73 maximum: 0x2f 74 75 xlnx,vfb: 76 type: boolean 77 description: Present when Video Format Bridge is enabled in IP configuration 78 79 xlnx,en-csi-v2-0: 80 type: boolean 81 description: Present if CSI v2 is enabled in IP configuration. 82 83 xlnx,en-vcx: 84 type: boolean 85 description: | 86 When present, there are maximum 16 virtual channels, else only 4. 87 88 xlnx,en-active-lanes: 89 type: boolean 90 description: | 91 Present if the number of active lanes can be re-configured at 92 runtime in the Protocol Configuration Register. Otherwise all lanes, 93 as set in IP configuration, are always active. 94 95 video-reset-gpios: 96 description: Optional specifier for a GPIO that asserts video_aresetn. 97 maxItems: 1 98 99 ports: 100 type: object 101 102 properties: 103 port@0: 104 type: object 105 description: | 106 Input / sink port node, single endpoint describing the 107 CSI-2 transmitter. 108 109 properties: 110 reg: 111 const: 0 112 113 endpoint: 114 type: object 115 116 properties: 117 118 data-lanes: 119 description: | 120 This is required only in the sink port 0 endpoint which 121 connects to MIPI CSI-2 source like sensor. 122 The possible values are - 123 1 - For 1 lane enabled in IP. 124 1 2 - For 2 lanes enabled in IP. 125 1 2 3 - For 3 lanes enabled in IP. 126 1 2 3 4 - For 4 lanes enabled in IP. 127 items: 128 - const: 1 129 - const: 2 130 - const: 3 131 - const: 4 132 133 remote-endpoint: true 134 135 required: 136 - data-lanes 137 - remote-endpoint 138 139 additionalProperties: false 140 141 additionalProperties: false 142 143 port@1: 144 type: object 145 description: | 146 Output / source port node, endpoint describing modules 147 connected the CSI-2 receiver. 148 149 properties: 150 151 reg: 152 const: 1 153 154 endpoint: 155 type: object 156 157 properties: 158 159 remote-endpoint: true 160 161 required: 162 - remote-endpoint 163 164 additionalProperties: false 165 166 additionalProperties: false 167 168required: 169 - compatible 170 - reg 171 - interrupts 172 - clocks 173 - clock-names 174 - ports 175 176allOf: 177 - if: 178 required: 179 - xlnx,vfb 180 then: 181 required: 182 - xlnx,csi-pxl-format 183 else: 184 properties: 185 xlnx,csi-pxl-format: false 186 187 - if: 188 not: 189 required: 190 - xlnx,en-csi-v2-0 191 then: 192 properties: 193 xlnx,en-vcx: false 194 195additionalProperties: false 196 197examples: 198 - | 199 #include <dt-bindings/gpio/gpio.h> 200 xcsi2rxss_1: csi2rx@a0020000 { 201 compatible = "xlnx,mipi-csi2-rx-subsystem-5.0"; 202 reg = <0xa0020000 0x10000>; 203 interrupt-parent = <&gic>; 204 interrupts = <0 95 4>; 205 xlnx,csi-pxl-format = <0x2a>; 206 xlnx,vfb; 207 xlnx,en-active-lanes; 208 xlnx,en-csi-v2-0; 209 xlnx,en-vcx; 210 clock-names = "lite_aclk", "video_aclk"; 211 clocks = <&misc_clk_0>, <&misc_clk_1>; 212 video-reset-gpios = <&gpio 86 GPIO_ACTIVE_LOW>; 213 214 ports { 215 #address-cells = <1>; 216 #size-cells = <0>; 217 218 port@0 { 219 /* Sink port */ 220 reg = <0>; 221 csiss_in: endpoint { 222 data-lanes = <1 2 3 4>; 223 /* MIPI CSI-2 Camera handle */ 224 remote-endpoint = <&camera_out>; 225 }; 226 }; 227 port@1 { 228 /* Source port */ 229 reg = <1>; 230 csiss_out: endpoint { 231 remote-endpoint = <&vproc_in>; 232 }; 233 }; 234 }; 235 }; 236... 237