/* * Copyright (C) 2015 GuangZhou Tronlong co., LTD - http://www.tronlong.com * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 as * published by the Free Software Foundation. */ /dts-v1/; #include "tl3588-evm.dts" #define CAMERA3_ENABLE_IMX219 1 #define CAMERA4_ENABLE_IMX219 1 #define CAMERA5_ENABLE_IMX219 1 #define CAMERA6_ENABLE_IMX219 1 / { model = "TL3588-EVM-IMX219"; imx219_clk: imx219-clk { compatible = "fixed-clock"; #clock-cells = <0>; clock-frequency = <24000000>; clock-output-names = "imx219_clk"; }; }; /* camera3 */ #if CAMERA3_ENABLE_IMX219 &i2c1 { status = "okay"; imx219_3: imx219@10 { compatible = "sony,imx219"; reg = <0x10>; clocks = <&imx219_clk>; status = "okay"; reset-gpios = <&gpio2 RK_PC3 GPIO_ACTIVE_LOW>; rockchip,camera-module-index = <0>; rockchip,camera-module-facing = "back"; rockchip,camera-module-name = "CMK-OT1980-PX1"; rockchip,camera-module-lens-name = "SHG102"; port { camera3_out: endpoint { link-frequencies = /bits/ 64 <456000000>; remote-endpoint = <&mipi_dphy1_in_ucam0>; data-lanes = <1 2>; }; }; }; }; &csi2_dphy0_hw { status = "okay"; }; &csi2_dphy1 { status = "okay"; ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; #address-cells = <1>; #size-cells = <0>; mipi_dphy1_in_ucam0: endpoint@1 { reg = <1>; remote-endpoint = <&camera3_out>; data-lanes = <1 2>; }; }; port@1 { reg = <1>; #address-cells = <1>; #size-cells = <0>; csi_dphy1_out: endpoint@0 { reg = <0>; remote-endpoint = <&mipi2_csi2_input>; }; }; }; }; &mipi2_csi2_hw { status = "okay"; }; &mipi2_csi2 { status = "okay"; ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; #address-cells = <1>; #size-cells = <0>; mipi2_csi2_input: endpoint@1 { reg = <1>; remote-endpoint = <&csi_dphy1_out>; }; }; port@1 { reg = <1>; #address-cells = <1>; #size-cells = <0>; mipi2_csi2_output: endpoint@0 { reg = <0>; remote-endpoint = <&cif_mipi2_in0>; }; }; }; }; &rkcif_mipi_lvds2 { status = "okay"; port { cif_mipi2_in0: endpoint { remote-endpoint = <&mipi2_csi2_output>; }; }; }; &rkcif_mipi_lvds2_sditf { status = "okay"; port { mipi_lvds2_sditf: endpoint { remote-endpoint = <&isp0_vir2>; }; }; }; &rkisp0_vir2 { status = "okay"; port { #address-cells = <1>; #size-cells = <0>; isp0_vir2: endpoint@0 { reg = <0>; remote-endpoint = <&mipi_lvds2_sditf>; }; }; }; #endif /* CAMERA3_ENABLE_IMX219 */ /* camera4 */ #if CAMERA4_ENABLE_IMX219 &i2c3 { status = "okay"; imx219_4: imx219@10 { compatible = "sony,imx219"; reg = <0x10>; clocks = <&imx219_clk>; status = "okay"; reset-gpios = <&gpio4 RK_PA2 GPIO_ACTIVE_LOW>; rockchip,camera-module-index = <1>; rockchip,camera-module-facing = "back"; rockchip,camera-module-name = "CMK-OT1980-PX1"; rockchip,camera-module-lens-name = "SHG102"; port { camera4_out: endpoint { link-frequencies = /bits/ 64 <456000000>; remote-endpoint = <&mipi_dphy2_in_ucam0>; data-lanes = <1 2>; }; }; }; }; &csi2_dphy0_hw { status = "okay"; }; &csi2_dphy2 { status = "okay"; ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; #address-cells = <1>; #size-cells = <0>; mipi_dphy2_in_ucam0: endpoint@1 { reg = <1>; remote-endpoint = <&camera4_out>; data-lanes = <3 4>; }; }; port@1 { reg = <1>; #address-cells = <1>; #size-cells = <0>; csi_dphy2_out: endpoint@0 { reg = <0>; remote-endpoint = <&mipi3_csi2_input>; }; }; }; }; &mipi3_csi2_hw { status = "okay"; }; &mipi3_csi2 { status = "okay"; ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; #address-cells = <1>; #size-cells = <0>; mipi3_csi2_input: endpoint@1 { reg = <1>; remote-endpoint = <&csi_dphy2_out>; }; }; port@1 { reg = <1>; #address-cells = <1>; #size-cells = <0>; mipi3_csi2_output: endpoint@0 { reg = <0>; remote-endpoint = <&cif_mipi3_in0>; }; }; }; }; &rkcif_mipi_lvds3 { status = "okay"; port { cif_mipi3_in0: endpoint { remote-endpoint = <&mipi3_csi2_output>; }; }; }; &rkcif_mipi_lvds3_sditf { status = "okay"; port { mipi_lvds3_sditf: endpoint { remote-endpoint = <&isp1_vir0>; }; }; }; &rkisp1_vir0 { status = "okay"; port { #address-cells = <1>; #size-cells = <0>; isp1_vir0: endpoint@0 { reg = <0>; remote-endpoint = <&mipi_lvds3_sditf>; }; }; }; #endif /* CAMERA4_ENABLE_IMX219 */ /* camera5 */ #if CAMERA5_ENABLE_IMX219 &i2c4 { status = "okay"; imx219_5: imx219@10 { compatible = "sony,imx219"; reg = <0x10>; clocks = <&imx219_clk>; status = "okay"; reset-gpios = <&gpio4 RK_PC3 GPIO_ACTIVE_LOW>; rockchip,camera-module-index = <2>; rockchip,camera-module-facing = "back"; rockchip,camera-module-name = "CMK-OT1980-PX1"; rockchip,camera-module-lens-name = "SHG102"; port { camera5_out: endpoint { link-frequencies = /bits/ 64 <456000000>; remote-endpoint = <&mipi_dphy4_in_ucam0>; data-lanes = <1 2>; }; }; }; }; &csi2_dphy1_hw { status = "okay"; }; &csi2_dphy4 { status = "okay"; ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; #address-cells = <1>; #size-cells = <0>; mipi_dphy4_in_ucam0: endpoint@1 { reg = <1>; remote-endpoint = <&camera5_out>; data-lanes = <1 2>; }; }; port@1 { reg = <1>; #address-cells = <1>; #size-cells = <0>; csi_dphy4_out: endpoint@0 { reg = <0>; remote-endpoint = <&mipi4_csi2_input>; }; }; }; }; &mipi4_csi2_hw { status = "okay"; }; &mipi4_csi2 { status = "okay"; ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; #address-cells = <1>; #size-cells = <0>; mipi4_csi2_input: endpoint@1 { reg = <1>; remote-endpoint = <&csi_dphy4_out>; }; }; port@1 { reg = <1>; #address-cells = <1>; #size-cells = <0>; mipi4_csi2_output: endpoint@0 { reg = <0>; remote-endpoint = <&cif_mipi4_in0>; }; }; }; }; &rkcif_mipi_lvds4 { status = "okay"; port { cif_mipi4_in0: endpoint { remote-endpoint = <&mipi4_csi2_output>; }; }; }; &rkcif_mipi_lvds4_sditf { status = "okay"; port { mipi_lvds4_sditf: endpoint { remote-endpoint = <&isp1_vir1>; }; }; }; &rkisp1_vir1 { status = "okay"; port { #address-cells = <1>; #size-cells = <0>; isp1_vir1: endpoint@0 { reg = <0>; remote-endpoint = <&mipi_lvds4_sditf>; }; }; }; #endif /* CAMERA5_ENABLE_IMX219 */ /* camera6 */ #if CAMERA6_ENABLE_IMX219 &i2c7 { status = "okay"; imx219_6: imx219@10 { compatible = "sony,imx219"; reg = <0x10>; clocks = <&imx219_clk>; status = "okay"; reset-gpios = <&gpio4 RK_PA0 GPIO_ACTIVE_LOW>; rockchip,camera-module-index = <3>; rockchip,camera-module-facing = "back"; rockchip,camera-module-name = "CMK-OT1980-PX1"; rockchip,camera-module-lens-name = "SHG102"; port { camera6_out: endpoint { link-frequencies = /bits/ 64 <456000000>; remote-endpoint = <&mipi_dphy5_in_ucam0>; data-lanes = <1 2>; }; }; }; }; &csi2_dphy1_hw { status = "okay"; }; &csi2_dphy5 { status = "okay"; ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; #address-cells = <1>; #size-cells = <0>; mipi_dphy5_in_ucam0: endpoint@1 { reg = <1>; remote-endpoint = <&camera6_out>; data-lanes = <3 4>; }; }; port@1 { reg = <1>; #address-cells = <1>; #size-cells = <0>; csi_dphy5_out: endpoint@0 { reg = <0>; remote-endpoint = <&mipi5_csi2_input>; }; }; }; }; &mipi5_csi2_hw { status = "okay"; }; &mipi5_csi2 { status = "okay"; ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; #address-cells = <1>; #size-cells = <0>; mipi5_csi2_input: endpoint@1 { reg = <1>; remote-endpoint = <&csi_dphy5_out>; }; }; port@1 { reg = <1>; #address-cells = <1>; #size-cells = <0>; mipi5_csi2_output: endpoint@0 { reg = <0>; remote-endpoint = <&cif_mipi5_in0>; }; }; }; }; &rkcif_mipi_lvds5 { status = "okay"; port { cif_mipi5_in0: endpoint { remote-endpoint = <&mipi5_csi2_output>; }; }; }; &rkcif_mipi_lvds5_sditf { status = "okay"; port { mipi_lvds5_sditf: endpoint { remote-endpoint = <&isp1_vir2>; }; }; }; &rkisp1_vir2 { status = "okay"; port { #address-cells = <1>; #size-cells = <0>; isp1_vir2: endpoint@0 { reg = <0>; remote-endpoint = <&mipi_lvds5_sditf>; }; }; }; #endif /* CAMERA6_ENABLE_IMX219 */ /* common */ &rkcif { status = "okay"; }; &rkcif_mmu { status = "okay"; }; &rkisp0 { status = "okay"; }; &isp0_mmu { status = "okay"; }; &rkisp1 { status = "okay"; }; &isp1_mmu { status = "okay"; }; &gpio2 { pinctrl-names = "default"; pinctrl-0 = <&camera3_pwdn>; camera3-pwdn-set { gpio-hog; gpios = <19 GPIO_ACTIVE_HIGH>; output-high; }; }; &gpio4 { pinctrl-names = "default"; pinctrl-0 = <&camera4_pwdn &camera5_pwdn &camera6_pwdn>; camera4-pwdn-set { gpio-hog; gpios = <2 GPIO_ACTIVE_HIGH>; output-high; }; camera5-pwdn-set { gpio-hog; gpios = <19 GPIO_ACTIVE_HIGH>; output-high; }; camera6-pwdn-set { gpio-hog; gpios = <0 GPIO_ACTIVE_HIGH>; output-high; }; }; &pinctrl { mipi_csi { camera3_pwdn: camera3-pwdn { rockchip,pins = <2 RK_PC3 RK_FUNC_GPIO &pcfg_pull_up>; }; camera4_pwdn: camera4-pwdn { rockchip,pins = <4 RK_PA2 RK_FUNC_GPIO &pcfg_pull_up>; }; camera5_pwdn: camera5-pwdn { rockchip,pins = <4 RK_PC3 RK_FUNC_GPIO &pcfg_pull_up>; }; camera6_pwdn: camera6-pwdn { rockchip,pins = <4 RK_PA0 RK_FUNC_GPIO &pcfg_pull_up>; }; }; };