#include "dt-bindings/gpio/tegra194-gpio.h" #include "dt-bindings/clock/tegra194-clock.h" /{ host1x { vi@15c10000 { num-channels = <1>; ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; status = "okay"; xavier_vi_in0: endpoint { status = "okay"; port-index = <2>; bus-width = <4>; remote-endpoint = <&xavier_csi_out0>; }; }; }; }; nvcsi@15a00000 { num-channels = <1>; #address-cells = <1>; #size-cells = <0>; channel@0 { reg = <0>; ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; xavier_csi_in0: endpoint@0 { port-index = <2>; bus-width = <4>; remote-endpoint = <&ds90ub960_csi_out0>; }; }; port@1 { reg = <1>; xavier_csi_out0: endpoint@1 { remote-endpoint = <&xavier_vi_in0>; }; }; }; }; }; }; i2c@c240000 { status = "okay"; #address-cells = <1>; #size-cells = <0>; ds90ub960_a@30 { compatible = "ti,ds90ub960_q1"; reg = <0x30>; devnode = "video0"; clocks = <&bpmp_clks TEGRA194_CLK_EXTPERIPH2>, <&bpmp_clks TEGRA194_CLK_EXTPERIPH1>; clock-names = "extperiph2", "pllp_grtba"; mclk = "extperiph2"; pocctl-gpios = <&tegra_main_gpio TEGRA194_MAIN_GPIO(A, 0) GPIO_ACTIVE_LOW>; /* Physical dimensions of sensor */ physical_w = "5.76"; /*may *2 according to ds90ub960 settings*/ physical_h = "3.24"; /*may *2 according to ds90ub960 settings*/ /* Defines number of frames to be dropped by driver internally after applying */ /* sensor crop settings. Some sensors send corrupt frames after applying */ /* crop co-ordinates */ post_crop_frame_drop = "0"; /* Define any required hw resources needed by driver */ /* ie. clocks, io pins, power sources */ //avdd-reg = "vana"; //iovdd-reg = "vif"; /* Convert Gain to unit of dB (decibel) befor passing to kernel driver */ use_decibel_gain = "true"; /* if true, delay gain setting by one frame to be in sync with exposure */ //delayed_gain = "true"; /* enable CID_SENSOR_MODE_ID for sensor modes selection */ use_sensor_mode_id = "true"; sensor_model ="ds90ub960"; mode0 {/*mode DS90UB960_MODE_1920X1080_CROP_30FPS*/ mclk_khz = "25000"; num_lanes = "4"; tegra_sinterface = "serial_a"; phy_mode = "DPHY"; discontinuous_clk = "no"; dpcm_enable = "false"; cil_settletime = "0"; dynamic_pixel_bit_depth = "12"; csi_pixel_bit_depth = "12";//"16"; mode_type = "bayer";//"yuv"; pixel_phase = "rggb";//"yuyv";// active_w = "1920"; active_h = "1080"; readout_orientation = "180"; line_length = "1920"; inherent_gain = "1"; mclk_multiplier = "20"; pix_clk_hz = "742500000";/*This value is calculated based on input clock (mclk) and PLL settings from sensor*/ /*mode table. Please refer to sensor data sheet for how to calculate this value.*/ min_gain_val = "1.0"; /* dB */ max_gain_val = "16"; /* dB */ min_hdr_ratio = "1"; max_hdr_ratio = "1"; min_framerate = "6"; max_framerate = "30"; min_exp_time = "30"; max_exp_time = "660000"; embedded_metadata_height = "0"; }; ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; ds90ub960_csi_out0: endpoint { port-index = <2>; bus-width = <4>; remote-endpoint = <&xavier_csi_in0>; }; }; }; }; }; tegra-camera-platform { compatible = "nvidia, tegra-camera-platform"; /** * Physical settings to calculate max ISO BW * * num_csi_lanes = <>; * Total number of CSI lanes when all cameras are active * * max_lane_speed = <>; * Max lane speed in Kbit/s * * min_bits_per_pixel = <>; * Min bits per pixel * * vi_peak_byte_per_pixel = <>; * Max byte per pixel for the VI ISO case * * vi_bw_margin_pct = <>; * Vi bandwidth margin in percentage * * max_pixel_rate = <>; * Max pixel rate in Kpixel/s for the ISP ISO case * Set this to the highest pix_clk_hz out of all available modes. * * isp_peak_byte_per_pixel = <>; * Max byte per pixel for the ISP ISO case * * isp_bw_margin_pct = <>; * Isp bandwidth margin in percentage */ num_csi_lanes = <12>; max_lane_speed = <1620000>; min_bits_per_pixel = <10>; vi_peak_byte_per_pixel = <2>; vi_bw_margin_pct = <25>; //max_pixel_rate = <160000>; isp_peak_byte_per_pixel = <5>; isp_bw_margin_pct = <25>; modules { module0 { badge = "ds90ub960"; position = "front"; orientation = "1"; drivernode0 { /* Declare PCL support driver (classically known as guid) */ pcl_id = "v4l2_sensor"; /* Driver v4l2 device name */ devname = "ds90ub960 2-2c-6c"; /* Declare the device-tree hierarchy to driver instance */ proc-device-tree = "/proc/device-tree/i2c@c240000/ds90ub960_a@30"; }; }; }; }; };