1// SPDX-License-Identifier: (GPL-2.0+ OR MIT) 2/* 3 * Copyright (c) 2023 Rockchip Electronics Co., Ltd. 4 * 5 * Version Sensor I2C_ADDR Lanes 6 * v1.0.0 os04a10 0x36 lane0~1(dphy1) 7 * sc4336 0x30 lane2~3(dphy2) 8 * v1.1.0 gc2053 0x37 lane0~1(dphy1) 9 * gc2053 0x3f lane2~3(dphy2) 10 */ 11 12&csi2_dphy_hw { 13 status = "okay"; 14}; 15 16&csi2_dphy1 { 17 status = "okay"; 18 19 ports { 20 #address-cells = <1>; 21 #size-cells = <0>; 22 23 port@0 { 24 reg = <0>; 25 #address-cells = <1>; 26 #size-cells = <0>; 27 28 csi_dphy_input0: endpoint@1 { 29 reg = <1>; 30 remote-endpoint = <&os04a10_out>; 31 data-lanes = <1 2>; 32 }; 33 34 csi_dphy_input2: endpoint@2 { 35 reg = <2>; 36 remote-endpoint = <&gc2053_out>; 37 data-lanes = <1 2>; 38 }; 39 }; 40 41 port@1 { 42 reg = <1>; 43 #address-cells = <1>; 44 #size-cells = <0>; 45 46 csi_dphy_output: endpoint@0 { 47 reg = <0>; 48 remote-endpoint = <&mipi_csi2_input>; 49 }; 50 }; 51 }; 52}; 53 54&csi2_dphy2 { 55 status = "okay"; 56 57 ports { 58 #address-cells = <1>; 59 #size-cells = <0>; 60 61 port@0 { 62 reg = <0>; 63 #address-cells = <1>; 64 #size-cells = <0>; 65 66 csi_dphy_input1: endpoint@1 { 67 reg = <1>; 68 remote-endpoint = <&sc3336_out>; 69 data-lanes = <1 2>; 70 }; 71 72 csi_dphy_input3: endpoint@2 { 73 reg = <2>; 74 remote-endpoint = <&gc2053_1_out>; 75 data-lanes = <1 2>; 76 }; 77 }; 78 79 port@1 { 80 reg = <1>; 81 #address-cells = <1>; 82 #size-cells = <0>; 83 84 csi_dphy_output1: endpoint@0 { 85 reg = <0>; 86 remote-endpoint = <&mipi1_csi2_input>; 87 }; 88 }; 89 }; 90}; 91 92&i2c4 { 93 status = "okay"; 94 clock-frequency = <400000>; 95 pinctrl-names = "default"; 96 pinctrl-0 = <&i2c4m2_xfer>; 97 98 os04a10: os04a10@36 { 99 compatible = "ovti,os04a10"; 100 status = "okay"; 101 reg = <0x36>; 102 clocks = <&cru MCLK_REF_MIPI0>; 103 clock-names = "xvclk"; 104 reset-gpios = <&gpio3 RK_PC5 GPIO_ACTIVE_LOW>; 105 pwdn-gpios = <&gpio3 RK_PD2 GPIO_ACTIVE_HIGH>; 106 pinctrl-names = "default"; 107 pinctrl-0 = <&mipi_refclk_out0>; 108 rockchip,camera-module-index = <0>; 109 rockchip,camera-module-facing = "back"; 110 rockchip,camera-module-name = "CMK-OT1607-PV1"; 111 rockchip,camera-module-lens-name = "50IRC-F16"; 112 port { 113 os04a10_out: endpoint { 114 remote-endpoint = <&csi_dphy_input0>; 115 data-lanes = <1 2>; 116 }; 117 }; 118 }; 119 120 gc2053: gc2053@37 { 121 compatible = "galaxycore,gc2053"; 122 status = "okay"; 123 reg = <0x37>; 124 clocks = <&cru MCLK_REF_MIPI0>; 125 clock-names = "xvclk"; 126 reset-gpios = <&gpio3 RK_PC5 GPIO_ACTIVE_LOW>; 127 pwdn-gpios = <&gpio3 RK_PD2 GPIO_ACTIVE_LOW>; 128 pinctrl-names = "default"; 129 pinctrl-0 = <&mipi_refclk_out0>; 130 rockchip,camera-module-index = <0>; 131 rockchip,camera-module-facing = "back"; 132 rockchip,camera-module-name = "CMK-OT2274-V10"; 133 rockchip,camera-module-lens-name = "28IRC-F20"; 134 port { 135 gc2053_out: endpoint { 136 remote-endpoint = <&csi_dphy_input2>; 137 data-lanes = <1 2>; 138 }; 139 }; 140 }; 141 142 sc4336: sc4336@30 { 143 compatible = "smartsens,sc4336"; 144 status = "okay"; 145 reg = <0x30>; 146 clocks = <&cru MCLK_REF_MIPI1>; 147 clock-names = "xvclk"; 148 reset-gpios = <&gpio3 RK_PD1 GPIO_ACTIVE_HIGH>; 149 pwdn-gpios = <&gpio3 RK_PA4 GPIO_ACTIVE_HIGH>; 150 pinctrl-names = "default"; 151 pinctrl-0 = <&mipi_refclk_out1>; 152 rockchip,camera-module-index = <1>; 153 rockchip,camera-module-facing = "back"; 154 rockchip,camera-module-name = "OT01"; 155 rockchip,camera-module-lens-name = "40IRC_F16"; 156 port { 157 sc3336_out: endpoint { 158 remote-endpoint = <&csi_dphy_input1>; 159 data-lanes = <1 2>; 160 }; 161 }; 162 }; 163 164 gc2053_1: gc2053_1@3f { 165 compatible = "galaxycore,gc2053"; 166 status = "okay"; 167 reg = <0x3f>; 168 clocks = <&cru MCLK_REF_MIPI1>; 169 clock-names = "xvclk"; 170 reset-gpios = <&gpio3 RK_PD1 GPIO_ACTIVE_LOW>; 171 pwdn-gpios = <&gpio3 RK_PA4 GPIO_ACTIVE_LOW>; 172 pinctrl-names = "default"; 173 pinctrl-0 = <&mipi_refclk_out1>; 174 rockchip,camera-module-index = <1>; 175 rockchip,camera-module-facing = "back"; 176 rockchip,camera-module-name = "CMK-OT2274-V10"; 177 rockchip,camera-module-lens-name = "28IRC-F20"; 178 port { 179 gc2053_1_out: endpoint { 180 remote-endpoint = <&csi_dphy_input3>; 181 data-lanes = <1 2>; 182 }; 183 }; 184 }; 185}; 186 187&mipi0_csi2 { 188 status = "okay"; 189 190 ports { 191 #address-cells = <1>; 192 #size-cells = <0>; 193 194 port@0 { 195 reg = <0>; 196 #address-cells = <1>; 197 #size-cells = <0>; 198 199 mipi_csi2_input: endpoint@1 { 200 reg = <1>; 201 remote-endpoint = <&csi_dphy_output>; 202 }; 203 }; 204 205 port@1 { 206 reg = <1>; 207 #address-cells = <1>; 208 #size-cells = <0>; 209 210 mipi_csi2_output: endpoint@0 { 211 reg = <0>; 212 remote-endpoint = <&cif_mipi_in>; 213 }; 214 }; 215 }; 216}; 217 218&mipi1_csi2 { 219 status = "okay"; 220 221 ports { 222 #address-cells = <1>; 223 #size-cells = <0>; 224 225 port@0 { 226 reg = <0>; 227 #address-cells = <1>; 228 #size-cells = <0>; 229 230 mipi1_csi2_input: endpoint@1 { 231 reg = <1>; 232 remote-endpoint = <&csi_dphy_output1>; 233 }; 234 }; 235 236 port@1 { 237 reg = <1>; 238 #address-cells = <1>; 239 #size-cells = <0>; 240 241 mipi1_csi2_output: endpoint@0 { 242 reg = <0>; 243 remote-endpoint = <&cif_mipi_in1>; 244 }; 245 }; 246 }; 247}; 248 249&rkcif { 250 status = "okay"; 251 pinctrl-names = "default"; 252 pinctrl-0 = <&mipi_pins>; 253}; 254 255&rkcif_mipi_lvds { 256 status = "okay"; 257 258 port { 259 /* MIPI CSI-2 endpoint */ 260 cif_mipi_in: endpoint { 261 remote-endpoint = <&mipi_csi2_output>; 262 }; 263 }; 264}; 265 266&rkcif_mipi_lvds_sditf { 267 status = "okay"; 268 269 port { 270 /* MIPI CSI-2 endpoint */ 271 mipi_lvds_sditf: endpoint { 272 remote-endpoint = <&isp_in>; 273 }; 274 }; 275}; 276 277&rkcif_mipi_lvds1 { 278 status = "okay"; 279 280 port { 281 /* MIPI CSI-2 endpoint */ 282 cif_mipi_in1: endpoint { 283 remote-endpoint = <&mipi1_csi2_output>; 284 }; 285 }; 286}; 287 288&rkcif_mipi_lvds1_sditf { 289 status = "okay"; 290 291 port { 292 /* MIPI CSI-2 endpoint */ 293 mipi_lvds1_sditf: endpoint { 294 remote-endpoint = <&isp_in1>; 295 }; 296 }; 297}; 298 299&rkisp { 300 status = "okay"; 301}; 302 303&rkisp_vir0 { 304 status = "okay"; 305 306 port@0 { 307 isp_in: endpoint { 308 remote-endpoint = <&mipi_lvds_sditf>; 309 }; 310 }; 311}; 312 313&rkisp_vir1 { 314 status = "okay"; 315 316 port@0 { 317 isp_in1: endpoint { 318 remote-endpoint = <&mipi_lvds1_sditf>; 319 }; 320 }; 321}; 322