ARM64: DT: Add auto detect support for E3333 board
Frank Chen [Thu, 3 Mar 2016 01:52:22 +0000 (17:52 -0800)]
Add auto detect support for E3333 (ov5693 x6) camera
board.

Bug 1729926

Change-Id: I589c228ef911f09fd9c2e3186f3f47e3094db9ad
Signed-off-by: Frank Chen <frankc@nvidia.com>
Reviewed-on: http://git-master/r/1011399
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Jihoon Bang <jbang@nvidia.com>
Reviewed-by: Hayden Du <haydend@nvidia.com>

arch/arm64/boot/dts/tegra210-p4573-2180.dts
arch/arm64/boot/dts/tegra210-platforms/tegra210-camera-e3326-a00.dtsi
arch/arm64/boot/dts/tegra210-platforms/tegra210-camera-e3333-a00.dtsi
arch/arm64/boot/dts/tegra210-platforms/tegra210-jetson-cv-camera-modules.dtsi
arch/arm64/boot/dts/tegra210-plugin-manager/tegra210-jetson-cv-camera-plugin-manager.dtsi

index 5918836..2e09730 100644 (file)
        plugin-manager {
                /delete-node/ fragment-e3323@0;
                /delete-node/ fragment-e3322@0;
+               /delete-node/ fragment-e3333@0;
        };
 
        host1x {
index 6db2e15..e527831 100644 (file)
@@ -28,7 +28,7 @@
                                port@0 {
                                        reg = <0>;
                                        e3326_vi_in0: endpoint {
-                                               remote-endpoint = <&ov5693_out0>;
+                                               remote-endpoint = <&e3326_ov5693_out0>;
                                        };
                                };
                        };
 
                                        port@0 {
                                                reg = <0>;
-                                               ov5693_out0: endpoint {
+                                               e3326_ov5693_out0: endpoint {
                                                        csi-port = <2>;
                                                        bus-width = <2>;
                                                        remote-endpoint = <&e3326_vi_in0>;
index a22ee13..8c5d63e 100644 (file)
@@ -66,7 +66,6 @@
                };
 
                i2c@546c0000 {
-                       nvidia,clock-always-on;
                        avdd_dsi_csi-supply = <&max77620_gpio7>;
 
                        status = "okay";
                                                        #size-cells = <0>;
                                                        port@0 {
                                                                reg = <0>;
-                                                               ov5693_out0: endpoint {
+                                                               e3333_ov5693_out0: endpoint {
                                                                        csi-port = <0>;
                                                                        bus-width = <2>;
                                                                        remote-endpoint = <&e3333_vi_in0>;
                                                        #size-cells = <0>;
                                                        port@0 {
                                                                reg = <0>;
-                                                               ov5693_out1: endpoint {
+                                                               e3333_ov5693_out1: endpoint {
                                                                        csi-port = <1>;
                                                                        bus-width = <2>;
                                                                        remote-endpoint = <&e3333_vi_in1>;
                                                        #size-cells = <0>;
                                                        port@0 {
                                                                reg = <0>;
-                                                               ov5693_out2: endpoint {
+                                                               e3333_ov5693_out2: endpoint {
                                                                        csi-port = <2>;
                                                                        bus-width = <2>;
                                                                        remote-endpoint = <&e3333_vi_in2>;
                                                        #size-cells = <0>;
                                                        port@0 {
                                                                reg = <0>;
-                                                               ov5693_out3: endpoint {
+                                                               e3333_ov5693_out3: endpoint {
                                                                        csi-port = <3>;
                                                                        bus-width = <2>;
                                                                        remote-endpoint = <&e3333_vi_in3>;
                                                        #size-cells = <0>;
                                                        port@0 {
                                                                reg = <0>;
-                                                               ov5693_out4: endpoint {
+                                                               e3333_ov5693_out4: endpoint {
                                                                        csi-port = <4>;
                                                                        bus-width = <2>;
                                                                        remote-endpoint = <&e3333_vi_in4>;
                                                        #size-cells = <0>;
                                                        port@0 {
                                                                reg = <0>;
-                                                               ov5693_out5: endpoint {
+                                                               e3333_ov5693_out5: endpoint {
                                                                        csi-port = <5>;
                                                                        bus-width = <2>;
                                                                        remote-endpoint = <&e3333_vi_in5>;
index 70d4352..d7f6cab 100644 (file)
@@ -12,6 +12,7 @@
  *
  */
 
+#include "tegra210-platforms/tegra210-jetson-cv-camera-e3333-a00.dtsi"
 #include "tegra210-platforms/tegra210-jetson-cv-camera-e3322-a00.dtsi"
 #include "tegra210-platforms/tegra210-jetson-cv-camera-e3323-a00.dtsi"
 #include "tegra210-platforms/tegra210-jetson-cv-camera-e3326-a00.dtsi"
                                        e3322_cam0: imx219_a@10 {
                                                status = "disabled";
                                        };
+                                       e3333_cam0: ov5693_a@36 {
+                                               status = "disabled";
+                                       };
                                };
                                i2c@1 {
                                        e3322_cam1: imx219_b@10 {
                                                status = "disabled";
                                        };
+                                       e3333_cam1: ov5693_b@36 {
+                                               status = "disabled";
+                                       };
                                };
                                i2c@2 {
                                        e3322_cam2: imx219_c@10 {
                                                status = "disabled";
                                        };
+                                       e3333_cam2: ov5693_c@36 {
+                                               status = "disabled";
+                                       };
                                };
                                i2c@3 {
                                        e3322_cam3: imx219_d@10 {
                                                status = "disabled";
                                        };
+                                       e3333_cam3: ov5693_d@36 {
+                                               status = "disabled";
+                                       };
                                };
                                i2c@4 {
                                        e3322_cam4: imx219_e@10 {
                                                status = "disabled";
                                        };
+                                       e3333_cam4: ov5693_e@36 {
+                                               status = "disabled";
+                                       };
                                };
                                i2c@5 {
                                        e3322_cam5: imx219_f@10 {
                                                status = "disabled";
                                        };
+                                       e3333_cam5: ov5693_f@36 {
+                                               status = "disabled";
+                                       };
+                               };
+                       };
+                       tca6408_21: tca6408@21 {
+                               default {
+                                       gpio-output-low = <0 1 2 3 4 5 6 7>;
                                };
                        };
                };
index 7b3abba..5dd23df 100644 (file)
                                };
                        };
                };
+
+               /* E3333 camera board */
+               fragment-e3333@0 {
+                       ids = "3333-1000-000", "3333-1000-100";
+                       /* Enable E3333 camera 0 */
+                       override@0 {
+                               target = <&e3333_cam0>;
+                               _overlay_ {
+                                       status = "okay";
+                               };
+                       };
+                       override@1 {
+                               target = <&cam_module0>;
+                               _overlay_ {
+                                       status = "okay";
+                                       badge = "e3333_bottomleft_P5V27C";
+                                       position = "bottomleft";
+                                       orientation = "1";
+                               };
+                       };
+                       override@2 {
+                               target = <&cam_module0_drivernode0>;
+                               _overlay_ {
+                                       status = "okay";
+                                       pcl_id = "v4l2_sensor";
+                                       proc-device-tree = "/proc/device-tree/host1x/i2c@546c0000/tca9548@77/i2c@0/ov5693_a@36";
+                               };
+                       };
+                       /* Enable E3333 camera 1 */
+                       override@3 {
+                               target = <&e3333_cam1>;
+                               _overlay_ {
+                                       status = "okay";
+                               };
+                       };
+                       override@4 {
+                               target = <&cam_module1>;
+                               _overlay_ {
+                                       status = "okay";
+                                       badge = "e3333_centerleft_P5V27C";
+                                       position = "centerleft";
+                                       orientation = "1";
+                               };
+                       };
+                       override@5 {
+                               target = <&cam_module1_drivernode0>;
+                               _overlay_ {
+                                       status = "okay";
+                                       pcl_id = "v4l2_sensor";
+                                       proc-device-tree = "/proc/device-tree/host1x/i2c@546c0000/tca9548@77/i2c@1/ov5693_b@36";
+                               };
+                       };
+                       /* Enable E3333 camera 2 */
+                       override@6 {
+                               target = <&e3333_cam2>;
+                               _overlay_ {
+                                       status = "okay";
+                               };
+                       };
+                       override@7 {
+                               target = <&cam_module2>;
+                               _overlay_ {
+                                       status = "okay";
+                                       badge = "e3333_centerright_P5V27C";
+                                       position = "centerright";
+                                       orientation = "1";
+                               };
+                       };
+                       override@8 {
+                               target = <&cam_module2_drivernode0>;
+                               _overlay_ {
+                                       status = "okay";
+                                       pcl_id = "v4l2_sensor";
+                                       proc-device-tree = "/proc/device-tree/host1x/i2c@546c0000/tca9548@77/i2c@2/ov5693_c@36";
+                               };
+                       };
+                       /* Enable E3333 camera 3 */
+                       override@9 {
+                               target = <&e3333_cam3>;
+                               _overlay_ {
+                                       status = "okay";
+                               };
+                       };
+                       override@10 {
+                               target = <&cam_module3>;
+                               _overlay_ {
+                                       status = "okay";
+                                       badge = "e3333_topleft_P5V27C";
+                                       position = "topleft";
+                                       orientation = "1";
+                               };
+                       };
+                       override@11 {
+                               target = <&cam_module3_drivernode0>;
+                               _overlay_ {
+                                       status = "okay";
+                                       pcl_id = "v4l2_sensor";
+                                       proc-device-tree = "/proc/device-tree/host1x/i2c@546c0000/tca9548@77/i2c@3/ov5693_d@36";
+                               };
+                       };
+                       /* Enable E3333 camera 4 */
+                       override@12 {
+                               target = <&e3333_cam4>;
+                               _overlay_ {
+                                       status = "okay";
+                               };
+                       };
+                       override@13 {
+                               target = <&cam_module4>;
+                               _overlay_ {
+                                       status = "okay";
+                                       badge = "e3333_bottomright_P5V27C";
+                                       position = "bottomright";
+                                       orientation = "1";
+                               };
+                       };
+                       override@14 {
+                               target = <&cam_module4_drivernode0>;
+                               _overlay_ {
+                                       status = "okay";
+                                       pcl_id = "v4l2_sensor";
+                                       proc-device-tree = "/proc/device-tree/host1x/i2c@546c0000/tca9548@77/i2c@4/ov5693_e@36";
+                               };
+                       };
+                       /* Enable E3333 camera 5 */
+                       override@15 {
+                               target = <&e3333_cam5>;
+                               _overlay_ {
+                                       status = "okay";
+                               };
+                       };
+                       override@16 {
+                               target = <&cam_module5>;
+                               _overlay_ {
+                                       status = "okay";
+                                       badge = "e3333_topright_P5V27C";
+                                       position = "topright";
+                                       orientation = "1";
+                               };
+                       };
+                       override@17 {
+                               target = <&cam_module5_drivernode0>;
+                               _overlay_ {
+                                       status = "okay";
+                                       pcl_id = "v4l2_sensor";
+                                       proc-device-tree = "/proc/device-tree/host1x/i2c@546c0000/tca9548@77/i2c@5/ov5693_f@36";
+                               };
+                       };
+                       /* Enable VI ports */
+                       override@18 {
+                               target = <&vi_base>;
+                               _overlay_ {
+                                       num-channels=<6>;
+                               };
+                       };
+                       override@19 {
+                               target = <&vi_port0>;
+                               _overlay_ {
+                                       status = "okay";
+                               };
+                       };
+                       override@20 {
+                               target = <&e3333_vi_in0>;
+                               _overlay_ {
+                                       status = "okay";
+                                       remote-endpoint = <&e3333_ov5693_out0>;
+                               };
+                       };
+                       override@21 {
+                               target = <&vi_port1>;
+                               _overlay_ {
+                                       status = "okay";
+                               };
+                       };
+                       override@22 {
+                               target = <&vi_in1>;
+                               _overlay_ {
+                                       status = "okay";
+                                       remote-endpoint = <&e3333_ov5693_out1>;
+                               };
+                       };
+                       override@23 {
+                               target = <&vi_port2>;
+                               _overlay_ {
+                                       status = "okay";
+                               };
+                       };
+                       override@24 {
+                               target = <&vi_in2>;
+                               _overlay_ {
+                                       status = "okay";
+                                       remote-endpoint = <&e3333_ov5693_out2>;
+                               };
+                       };
+                       override@25 {
+                               target = <&vi_port3>;
+                               _overlay_ {
+                                       status = "okay";
+                               };
+                       };
+                       override@26 {
+                               target = <&vi_in3>;
+                               _overlay_ {
+                                       status = "okay";
+                                       remote-endpoint = <&e3333_ov5693_out3>;
+                               };
+                       };
+                       override@27 {
+                               target = <&vi_port4>;
+                               _overlay_ {
+                                       status = "okay";
+                               };
+                       };
+                       override@28 {
+                               target = <&vi_in4>;
+                               _overlay_ {
+                                       status = "okay";
+                                       remote-endpoint = <&e3333_ov5693_out4>;
+                               };
+                       };
+                       override@29 {
+                               target = <&vi_port5>;
+                               _overlay_ {
+                                       status = "okay";
+                               };
+                       };
+                       override@30 {
+                               target = <&vi_in5>;
+                               _overlay_ {
+                                       status = "okay";
+                                       remote-endpoint = <&e3333_ov5693_out5>;
+                               };
+                       };
+                       /* Enable TCA6408 GPIO expander */
+                       override@31 {
+                               target = <&cam_tca6408_21>;
+                               _overlay_ {
+                                       status = "okay";
+                               };
+                       };
+                       /* Enable TCA9548 I2C mux */
+                       override@32 {
+                               target = <&cam_tca9548_77>;
+                               _overlay_ {
+                                       status = "okay";
+                               };
+                       };
+                       /* Disable E3326 camera board */
+                       override@33 {
+                               target = <&e3326_cam0>;
+                               _overlay_ {
+                                       status = "disabled";
+                               };
+                       };
+               };
        };
 };