/* * Copyright (c) 2018-2020, NVIDIA CORPORATION. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for * more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #include "tegra194-camera-six-pr2100.dtsi" #define CAM0_PWDN TEGRA194_MAIN_GPIO(P, 4) #define CAM1_PWDN TEGRA194_MAIN_GPIO(P, 5) #define CAMERA_I2C_MUX_BUS(x) (0x1E + x) / { gpio@6000d000 { camera-control-output-high { gpio-hog; output-high; gpios = < CAM0_PWDN 0>; label = "cam1-pwdn"; }; }; en_vdd_cam: regulator@13 { compatible = "regulator-fixed-sync"; // reg = <13>; regulator-name = "en-vdd-cam"; regulator-min-microvolt = <3300000>; regulator-max-microvolt = <3300000>; regulator-always-on; }; i2c@3160000 { tca9539_gpio: tca9539@75 { compatible = "ti,tca9539"; status = "okay"; gpio-controller; #gpio-cells = <2>; reg = <0x75>; vcc-supply = <&en_vdd_cam>; tca9539_75_outlow { gpio-hog; gpios = <0 0 1 0 2 0 3 0 4 0 5 0 6 0 7 0>; output-low; label = "tca9539_75_outlow_0", "tca9539_75_outlow_1", "tca9539_75_outlow_2", "tca9539_75_outlow_3", "tca9539_75_outlow_4", "tca9539_75_outlow_5", "tca9539_75_outlow_6", "tca9539_75_outlow_7"; }; }; }; i2c@3180000 { tca9548_70: tca9548@70 { status = "okay"; compatible = "nxp,pca9548"; reg = <0x70>; #address-cells = <1>; #size-cells = <0>; skip_mux_detect = "yes"; vcc-supply = <&en_vdd_cam>; vcc_lp = "vcc"; force_bus_start = ; i2c@0 { reg = <0>; status = "okay"; i2c-mux,deselect-on-exit; #address-cells = <1>; #size-cells = <0>; rbpcv2_pr2100_a@5c { reset-gpios = <&tca9539_gpio 0 GPIO_ACTIVE_HIGH>; // reset-gpios = <&tegra_main_gpio 0 1>; }; }; }; }; gpio@2200000 { camera-control-output-low { gpio-hog; output-low; gpios = ; label = "cam0-pwdn","cam1-pwdn"; }; }; };