I have a GMSL adapter board that connects to the NVIDIA Jetson via MIPI CSI. I will configure this adapter board through another SoC, and the NVIDIA board only needs to receive the MIPI data. How should I write the driver for NVIDIA? My NVIDIA board is Orin NX and I’m using Jetpack 6.2.
// SPDX-License-Identifier: GPL-2.0-only
// SPDX-FileCopyrightText: Copyright (c) 2018-2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
/dts-v1/;
/plugin/;
define CAM0_RST TEGRA234_MAIN_GPIO(H, 3)
define CAM0_PWDN TEGRA234_MAIN_GPIO(H, 6)
define CAM1_PWDN TEGRA234_MAIN_GPIO(AC, 0)
define CAM_I2C_MUX TEGRA234_AON_GPIO(CC, 3)
include <dt-bindings/tegra234-p3767-0000-common.h>
/ {
overlay-name = “Jetson Camera zuojisi”;
jetson-header-name = “Jetson 24pin CSI Connector”;
compatible = JETSON_COMPATIBLE_P3768;
fragment@0 {
target-path = “/”;
_overlay_ {
zuojisi {
base {
label = “xcbase 20250517”;
};
branch {
label = “xcDeserializer4.0.01_4CAM_CAM1_4LANE 20260208”;
};
};
tegra-capture-vi {
num-channels = <4>;
ports {
#address-cells = <1>;
#size-cells = <0>;
status = “okay”;
/* Camera A - VC0 on CAM1 */
port@0 {
status = “okay”;
reg = <0>;
z_cam_a_vi_in0: endpoint {
status = “okay”;
vc-id = <0>;
port-index = <2>; /* CAM1 */
bus-width = <4>; /* 4 Lane */
remote-endpoint = <&z_cam_a_csi_out0>;
};
};
/* Camera B - VC1 on CAM1 */
port@1 {
status = “okay”;
reg = <1>;
z_cam_b_vi_in1: endpoint {
status = “okay”;
vc-id = <1>;
port-index = <2>;
bus-width = <4>;
remote-endpoint = <&z_cam_b_csi_out1>;
};
};
/* Camera C - VC2 on CAM1 */
port@2 {
status = “okay”;
reg = <2>;
z_cam_c_vi_in2: endpoint {
status = “okay”;
vc-id = <2>;
port-index = <2>;
bus-width = <4>;
remote-endpoint = <&z_cam_c_csi_out2>;
};
};
/* Camera D - VC3 on CAM1 */
port@3 {
status = “okay”;
reg = <3>;
z_cam_d_vi_in3: endpoint {
status = “okay”;
vc-id = <3>;
port-index = <2>;
bus-width = <4>;
remote-endpoint = <&z_cam_d_csi_out3>;
};
};
};
};
tegra-camera-platform {
compatible = “nvidia, tegra-camera-platform”;
num_csi_lanes = <4>;
max_lane_speed = <2000000>; /* 2Gbps */
min_bits_per_pixel = <16>;
vi_peak_byte_per_pixel = <2>;
vi_bw_margin_pct = <25>;
max_pixel_rate = <10000000>; /* 1920*1536*30 */
isp_peak_byte_per_pixel = <2>;
isp_bw_margin_pct = <25>;
};
bus@0{
host1x@13e00000 {
nvcsi@15a00000 {
num-channels = <4>;
#address-cells = <1>;
#size-cells = <0>;
/* Channel 0: Camera A */
channel@0 {
status = “okay”;
reg = <0>;
ports {
status = “okay”;
#address-cells = <1>;
#size-cells = <0>;
port@0 {
status = “okay”;
reg = <0>;
z_cam_a_csi_in0: endpoint@0 {
status = “okay”;
port-index = <2>;
bus-width = <4>;
remote-endpoint = <&z_cam_a_cam_out0>;
};
};
port@1 {
status = “okay”;
reg = <1>;
z_cam_a_csi_out0: endpoint@1 {
status = “okay”;
remote-endpoint = <&z_cam_a_vi_in0>;
};
};
};
};
/* Channel 1: Camera B */
channel@1 {
status = “okay”;
reg = <1>;
ports {
status = “okay”;
#address-cells = <1>;
#size-cells = <0>;
port@0 {
status = “okay”;
reg = <0>;
z_cam_b_csi_in1: endpoint@2 {
status = “okay”;
port-index = <2>;
bus-width = <4>;
remote-endpoint = <&z_cam_b_cam_out1>;
};
};
port@1 {
status = “okay”;
reg = <1>;
z_cam_b_csi_out1: endpoint@3 {
status = “okay”;
remote-endpoint = <&z_cam_b_vi_in1>;
};
};
};
};
/* Channel 2: Camera C */
channel@2 {
status = “okay”;
reg = <2>;
ports {
status = “okay”;
#address-cells = <1>;
#size-cells = <0>;
port@0 {
status = “okay”;
reg = <0>;
z_cam_c_csi_in2: endpoint@4 {
status = “okay”;
port-index = <2>;
bus-width = <4>;
remote-endpoint = <&z_cam_c_cam_out2>;
};
};
port@1 {
status = “okay”;
reg = <1>;
z_cam_c_csi_out2: endpoint@5 {
status = “okay”;
remote-endpoint = <&z_cam_c_vi_in2>;
};
};
};
};
/* Channel 3: Camera D */
channel@3 {
status = “okay”;
reg = <3>;
ports {
status = “okay”;
#address-cells = <1>;
#size-cells = <0>;
port@0 {
status = “okay”;
reg = <0>;
z_cam_d_csi_in3: endpoint@6 {
status = “okay”;
port-index = <2>;
bus-width = <4>;
remote-endpoint = <&z_cam_d_cam_out3>;
};
};
port@1 {
status = “okay”;
reg = <1>;
z_cam_d_csi_out3: endpoint@7 {
status = “okay”;
remote-endpoint = <&z_cam_d_vi_in3>;
};
};
};
};
};
};
/* === cam_i2cmux 完全保留原始架构 === */
cam_i2cmux {
status = “okay”;
compatible = “i2c-mux-gpio”;
#address-cells = <1>;
#size-cells = <0>;
mux-gpios = <&gpio_aon CAM_I2C_MUX GPIO_ACTIVE_HIGH>;
i2c-parent = <&cam_i2c>;
i2c@0 {
reg = <0>;
#address-cells = <1>;
#size-cells = <0>;
status = “okay”;
z_dser_0: z_max96724 {
status = “okay”;
compatible = “zuojisi,z_max96724”;
reg = <0x27>;
is-master;
};
/* === Camera A === */
z_cam_a {
status = “okay”;
def-addr = <0x51>;
nvidia,gmsl-dser-device = <&z_dser_0>;
des-link = “A”;
compatible = “zuojisi,z_imx390_5200_9295”;
reg = <0x10>;
physical_w = “15.0”;
physical_h = “12.5”;
sensor_model = “cam_a”;
post_crop_frame_drop = “0”;
use_decibel_gain = “true”;
use_sensor_mode_id = “true”;
mode0 {
mclk_khz = “24000”;
num_lanes = “4”;
tegra_sinterface = “serial_c”; /* CAM1 */
vc_id = “0”; /* === 保持原始不变 === */
discontinuous_clk = “no”;
dpcm_enable = “false”;
cil_settletime = “0”;
dynamic_pixel_bit_depth = “16”;
csi_pixel_bit_depth = “16”;
mode_type = “yuv”;
pixel_phase = “uyvy”;
active_w = “1920”;
active_h = “1536”;
readout_orientation = “0”;
line_length = “0”;
inherent_gain = “1”;
pix_clk_hz = “176947200”;
serdes_pix_clk_hz = “800000000”;
gain_factor = “10”;
min_gain_val = “0”;
max_gain_val = “0”;
step_gain_val = “1”;
default_gain = “0”;
min_hdr_ratio = “1”;
max_hdr_ratio = “1”;
framerate_factor = “1000000”;
min_framerate = “30000000”;
max_framerate = “30000000”;
step_framerate = “1”;
default_framerate = “30000000”;
exposure_factor = “1000000”;
min_exp_time = “33”;
max_exp_time = “33333”;
step_exp_time = “1”;
default_exp_time = “33333”;
embedded_metadata_height = “0”;
};
ports {
#address-cells = <1>;
#size-cells = <0>;
port@0 {
reg = <0>;
z_cam_a_cam_out0: endpoint {
vc-id = <0>;
port-index = <2>;
bus-width = <4>;
remote-endpoint = <&z_cam_a_csi_in0>;
};
};
};
gmsl-link {
num-ser-lanes = <4>;
streams = “yuv16”;
};
};
/* === Camera B === */
z_cam_b {
status = “okay”;
def-addr = <0x51>;
nvidia,gmsl-dser-device = <&z_dser_0>;
des-link = “B”;
compatible = “zuojisi,z_imx390_5200_9295”;
reg = <0x11>;
physical_w = “15.0”;
physical_h = “12.5”;
sensor_model = “cam_b”;
post_crop_frame_drop = “0”;
use_decibel_gain = “true”;
use_sensor_mode_id = “true”;
mode0 {
mclk_khz = “24000”;
num_lanes = “4”;
tegra_sinterface = “serial_c”;
vc_id = “1”; /* === 保持原始不变 === */
discontinuous_clk = “no”;
dpcm_enable = “false”;
cil_settletime = “0”;
dynamic_pixel_bit_depth = “16”;
csi_pixel_bit_depth = “16”;
mode_type = “yuv”;
pixel_phase = “uyvy”;
active_w = “1920”;
active_h = “1536”;
readout_orientation = “0”;
line_length = “0”;
inherent_gain = “1”;
pix_clk_hz = “176947200”;
serdes_pix_clk_hz = “800000000”;
gain_factor = “10”;
min_gain_val = “0”;
max_gain_val = “0”;
step_gain_val = “1”;
default_gain = “0”;
min_hdr_ratio = “1”;
max_hdr_ratio = “1”;
framerate_factor = “1000000”;
min_framerate = “30000000”;
max_framerate = “30000000”;
step_framerate = “1”;
default_framerate = “30000000”;
exposure_factor = “1000000”;
min_exp_time = “33”;
max_exp_time = “33333”;
step_exp_time = “1”;
default_exp_time = “33333”;
embedded_metadata_height = “0”;
};
ports {
#address-cells = <1>;
#size-cells = <0>;
port@0 {
reg = <0>;
z_cam_b_cam_out1: endpoint {
vc-id = <1>;
port-index = <2>;
bus-width = <4>;
remote-endpoint = <&z_cam_b_csi_in1>;
};
};
};
gmsl-link {
num-ser-lanes = <4>;
streams = “yuv16”;
};
};
/* === Camera C === */
z_cam_c {
status = “okay”;
def-addr = <0x51>;
nvidia,gmsl-dser-device = <&z_dser_0>;
des-link = “C”;
compatible = “zuojisi,z_imx390_5200_9295”;
reg = <0x12>;
physical_w = “15.0”;
physical_h = “12.5”;
sensor_model = “cam_c”;
post_crop_frame_drop = “0”;
use_decibel_gain = “true”;
use_sensor_mode_id = “true”;
mode0 {
mclk_khz = “24000”;
num_lanes = “4”;
tegra_sinterface = “serial_c”;
vc_id = “2”; /* === 保持原始不变 === */
discontinuous_clk = “no”;
dpcm_enable = “false”;
cil_settletime = “0”;
dynamic_pixel_bit_depth = “16”;
csi_pixel_bit_depth = “16”;
mode_type = “yuv”;
pixel_phase = “uyvy”;
active_w = “1920”;
active_h = “1536”;
readout_orientation = “0”;
line_length = “0”;
inherent_gain = “1”;
pix_clk_hz = “176947200”;
serdes_pix_clk_hz = “800000000”;
gain_factor = “10”;
min_gain_val = “0”;
max_gain_val = “0”;
step_gain_val = “1”;
default_gain = “0”;
min_hdr_ratio = “1”;
max_hdr_ratio = “1”;
framerate_factor = “1000000”;
min_framerate = “30000000”;
max_framerate = “30000000”;
step_framerate = “1”;
default_framerate = “30000000”;
exposure_factor = “1000000”;
min_exp_time = “33”;
max_exp_time = “33333”;
step_exp_time = “1”;
default_exp_time = “33333”;
embedded_metadata_height = “0”;
};
ports {
#address-cells = <1>;
#size-cells = <0>;
port@0 {
reg = <0>;
z_cam_c_cam_out2: endpoint {
vc-id = <2>;
port-index = <2>;
bus-width = <4>;
remote-endpoint = <&z_cam_c_csi_in2>;
};
};
};
gmsl-link {
num-ser-lanes = <4>;
streams = “yuv16”;
};
};
/* === Camera D === */
z_cam_d {
status = “okay”;
def-addr = <0x51>;
nvidia,gmsl-dser-device = <&z_dser_0>;
des-link = “D”;
compatible = “zuojisi,z_imx390_5200_9295”;
reg = <0x13>;
physical_w = “15.0”;
physical_h = “12.5”;
sensor_model = “cam_d”;
post_crop_frame_drop = “0”;
use_decibel_gain = “true”;
use_sensor_mode_id = “true”;
mode0 {
mclk_khz = “24000”;
num_lanes = “4”;
tegra_sinterface = “serial_c”;
vc_id = “3”; /* === 保持原始不变 === */
discontinuous_clk = “no”;
dpcm_enable = “false”;
cil_settletime = “0”;
dynamic_pixel_bit_depth = “16”;
csi_pixel_bit_depth = “16”;
mode_type = “yuv”;
pixel_phase = “uyvy”;
active_w = “1920”;
active_h = “1536”;
readout_orientation = “0”;
line_length = “0”;
inherent_gain = “1”;
pix_clk_hz = “176947200”;
serdes_pix_clk_hz = “800000000”;
gain_factor = “10”;
min_gain_val = “0”;
max_gain_val = “0”;
step_gain_val = “1”;
default_gain = “0”;
min_hdr_ratio = “1”;
max_hdr_ratio = “1”;
framerate_factor = “1000000”;
min_framerate = “30000000”;
max_framerate = “30000000”;
step_framerate = “1”;
default_framerate = “30000000”;
exposure_factor = “1000000”;
min_exp_time = “33”;
max_exp_time = “33333”;
step_exp_time = “1”;
default_exp_time = “33333”;
embedded_metadata_height = “0”;
};
ports {
#address-cells = <1>;
#size-cells = <0>;
port@0 {
reg = <0>;
z_cam_d_cam_out3: endpoint {
vc-id = <3>;
port-index = <2>;
bus-width = <4>;
remote-endpoint = <&z_cam_d_csi_in3>;
};
};
};
gmsl-link {
num-ser-lanes = <4>;
streams = “yuv16”;
};
};
};
};
};
};
};
};
/* zuojisi */
include <linux/gpio.h>
include <linux/module.h>
include <linux/of.h>
include <linux/of_device.h>
include <linux/of_gpio.h>
include <linux/uaccess.h>
include <linux/slab.h>
include <linux/fs.h>
include <media/camera_common.h>
include <linux/module.h>
include “z_max96724.h”
define max96724_TX11_PIPE_X_EN_ADDR 0x90B
define max96724_TX45_PIPE_X_DST_CTRL_ADDR 0x92D
define max96724_PIPE_X_SRC_0_MAP_ADDR 0x90D
define max96724_PHY_CLK (16)
struct max96724 {
struct i2c_client *i2c_client;
struct regmap *regmap;
struct mutex lock;
u8 link_lock_status;
u8 ismaster;
};
define CHECKNULL(x) if(x==NULL){ \
dev_err(NULL, “zuojisi %s: ##x## NULL ptr\n”,_func_); \
return -EINVAL; \
}
/* ========== FAKE I2C FUNCTIONS - Always return success ========== */
/* ========== EXPORTED APIs ========== */
int z_max96724_lock_link(struct device *dev)
{
struct max96724 *priv = NULL;
CHECKNULL(dev);
priv = dev_get_drvdata(dev);
CHECKNULL(priv);
mutex_lock(&priv->lock);
dev_info(dev,“zuojisi: mutex lock”);
return 0;
}
EXPORT_SYMBOL(z_max96724_lock_link);
int z_max96724_unlock_link(struct device *dev)
{
struct max96724 *priv = NULL;
CHECKNULL(dev);
priv = dev_get_drvdata(dev);
CHECKNULL(priv);
dev_info(dev,“zuojisi: mutex unlock”);
mutex_unlock(&priv->lock);
return 0;
}
EXPORT_SYMBOL(z_max96724_unlock_link);
int z_max96724_monopolize_link(struct device *dev, int link)
{
struct max96724 *priv = NULL;
CHECKNULL(dev);
priv = dev_get_drvdata(dev);
CHECKNULL(priv);
dev_info(dev, “zuojisi: %s: monopolize link_%c (FAKE)\n”, _func_, ‘A’+link);
return 0;
}
EXPORT_SYMBOL(z_max96724_monopolize_link);
int z_max96724_enable_link(struct device *dev, int link)
{
struct max96724 *priv = NULL;
CHECKNULL(dev);
priv = dev_get_drvdata(dev);
CHECKNULL(priv);
dev_info(dev, “zuojisi: %s: enable link_%c (FAKE)\n”, _func_, ‘A’+link);
priv->link_lock_status |= (1<<link);
return 0;
}
EXPORT_SYMBOL(z_max96724_enable_link);
int z_max96724_restore_link(struct device *dev)
{
struct max96724 *priv = NULL;
CHECKNULL(dev);
priv = dev_get_drvdata(dev);
CHECKNULL(priv);
dev_info(dev, “zuojisi: restore links (FAKE)\n”);
return 0;
}
EXPORT_SYMBOL(z_max96724_restore_link);
int z_max96724_check_link_status(struct device *dev, int link)
{
struct max96724 *priv = NULL;
CHECKNULL(dev);
priv = dev_get_drvdata(dev);
CHECKNULL(priv);
/* Always report as NOT occupied */
return 0;
}
EXPORT_SYMBOL(z_max96724_check_link_status);
int z_max96724_set_link_bandwidth(struct device *dev, int link, int gbps)
{
struct max96724 *priv = NULL;
CHECKNULL(dev);
priv = dev_get_drvdata(dev);
CHECKNULL(priv);
dev_info(dev, “zuojisi: set link_%c to %dGbps (FAKE)\n”,link+‘A’,gbps);
return 0;
}
EXPORT_SYMBOL(z_max96724_set_link_bandwidth);
/* ========== PIPELINE SETUP ========== */
static int max96724_setup_pipeline(struct device *dev,struct gmsl_link_ctx *g_ctx)
{
struct max96724 *priv = NULL;
int pipe_id = 0;
u32 i = 0;
u8 dst_vc = 0;
CHECKNULL(dev);
CHECKNULL(g_ctx);
priv = dev_get_drvdata(dev);
CHECKNULL(priv);
dev_info(dev,“zuojisi:96724: num_streams=%d (FAKE setup)\n”,g_ctx->num_streams);
for (i = 0; i < g_ctx->num_streams; i++) {
pipe_id = g_ctx->des_link;
dev_info(dev, “zuojisi: pipe_%d receive stream_id=%d, datatype=0x%x (FAKE)\n”,
pipe_id, i, g_ctx->streams[i]);
dst_vc = g_ctx->des_link;
dev_info(dev, “zuojisi: mapping pipe_%d → dst_vc=%d (FAKE)\n”, pipe_id, dst_vc);
}
return 0;
}
int z_max96724_start_streaming(struct device *dev, struct gmsl_link_ctx *g_ctx)
{
struct max96724 *priv = NULL;
int err;
CHECKNULL(dev);
CHECKNULL(g_ctx);
priv = dev_get_drvdata(dev);
CHECKNULL(priv);
dev_info(dev,“zuojisi: 96724 start streaming, link=%c - enter (FAKE)\n”,‘A’+g_ctx->des_link);
mutex_lock(&priv->lock);
err = max96724_setup_pipeline(dev, g_ctx);
if (err) {
mutex_unlock(&priv->lock);
return err;
}
mutex_unlock(&priv->lock);
dev_info(dev,“zuojisi: 96724 start streaming - exit (FAKE)\n”);
return 0;
}
EXPORT_SYMBOL(z_max96724_start_streaming);
int z_max96724_stop_streaming(struct device *dev, struct gmsl_link_ctx *g_ctx)
{
struct max96724 *priv = NULL;
CHECKNULL(dev);
CHECKNULL(g_ctx);
priv = dev_get_drvdata(dev);
CHECKNULL(priv);
dev_info(dev,“zuojisi: 96724 stop streaming, link_%c - enter (FAKE)\n”,‘A’+g_ctx->des_link);
mutex_lock(&priv->lock);
dev_info(dev,“zuojisi: 96724 stop streaming - exit (FAKE)\n”);
mutex_unlock(&priv->lock);
return 0;
}
EXPORT_SYMBOL(z_max96724_stop_streaming);
/* ========== OF MATCH ========== */
const struct of_device_id max96724_of_match[] = {
{ .compatible = “zuojisi,z_max96724”, },
{ },
};
MODULE_DEVICE_TABLE(of, max96724_of_match);
static int max96724_parse_dt(struct max96724 *priv,
struct i2c_client *client)
{
struct device_node *node = client->dev.of_node;
const struct of_device_id *match;
if (!node)
return -EINVAL;
match = of_match_device(max96724_of_match, &client->dev);
if (!match) {
dev_err(&client->dev, “Failed to find matching dt id\n”);
return -EFAULT;
}
return 0;
}
static struct regmap_config max96724_regmap_config =@0x0x{
.reg_bits = 16,
.val_bits = 8,
.cache_type = REGCACHE_RBTREE,
};
static int max96724_probe(struct i2c_client *client,
const struct i2c_device_id *id)
{
struct max96724 *priv;
int err = 0;
dev_info(&client->dev, “zuojisi: [max96724]: FAKE probing GMSL Deserializer @0x%x\n”,client->addr);
priv = devm_kzalloc(&client->dev, sizeof(*priv), GFP_KERNEL);
priv->i2c_client = client;
priv->regmap = devm_regmap_init_i2c(priv->i2c_client,
&max96724_regmap_config);
if (IS_ERR(priv->regmap)) {
dev_err(&client->dev,
“regmap init failed: %ld\n”, PTR_ERR(priv->regmap));
priv->regmap = NULL;
}
err = max96724_parse_dt(priv, client);
if (err) {
dev_err(&client->dev, “zuojisi: unable to parse dt\n”);
return -EFAULT;
}
mutex_init(&priv->lock);
dev_set_drvdata(&client->dev, priv);
dev_info(&client->dev, “zuojisi: %s: FAKE success (no I2C communication)\n”, _func_);
return err;
}
static int max96724_remove(struct i2c_client *client)
{
struct max96724 *priv;
if (client != NULL) {
priv = dev_get_drvdata(&client->dev);
if (priv)
mutex_destroy(&priv->lock);
}
return 0;
}
static const struct i2c_device_id max96724_id[] = {
{ “max96724”, 0 },
{ },
};
MODULE_DEVICE_TABLE(i2c, max96724_id);
static struct i2c_driver max96724_i2c_driver = {
.driver = {
.name = “z_max96724”,
.owner = THIS_MODULE,
.of_match_table = of_match_ptr(max96724_of_match),
},
.probe = max96724_probe,
.remove = max96724_remove,
.id_table = max96724_id,
};
static int __init max96724_init(void)
{
return i2c_add_driver(&max96724_i2c_driver);
}
static void __exit max96724_exit(void)
{
i2c_del_driver(&max96724_i2c_driver);
}
module_init(max96724_init);
module_exit(max96724_exit);
MODULE_DESCRIPTION(“GMSL Deserializer driver z_max96724 (FAKE I2C)”);
MODULE_AUTHOR(“zuojisi zuojisi@163.com”);
MODULE_LICENSE(“GPL v2”);
/*
* z_imx390_5200_9295.c - z_imx390_5200_9295 sensor driver
* MODIFIED: FAKE I2C for Orin NX, 4 cameras on CAM1
*/
include <linux/slab.h>
include <linux/uaccess.h>
include <linux/gpio.h>
include <linux/module.h>
include <linux/seq_file.h>
include <linux/of.h>
include <linux/of_device.h>
include <linux/of_gpio.h>
include “z_max96724.h”
include <media/tegracam_core.h>
include “z_imx390_5200_9295_mode_tbls.h”
define MAX9295_ALTER_ADDR_BASE 0x20
const struct of_device_id z_imx390_5200_9295_of_match[] = {
{ .compatible = “zuojisi,z_imx390_5200_9295”,},
{ },
};
MODULE_DEVICE_TABLE(of, z_imx390_5200_9295_of_match);
static const u32 ctrl_cid_list[] = {
TEGRA_CAMERA_CID_SENSOR_MODE_ID,
};
struct z_imx390_5200_9295 {
struct i2c_client *i2c_client;
const struct i2c_device_id *id;
struct v4l2_subdev *subdev;
struct device *dser_dev;
struct camera_common_data *s_data;
struct tegracam_device *tc_dev;
struct gmsl_link_ctx g_ctx;
u32 def_addr;
u32 act_addr;
u32 des_link;
};
static const struct regmap_config sensor_regmap_config = {
.reg_bits = 16,
.val_bits = 8,
.cache_type = REGCACHE_RBTREE,
#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 4, 0)
.use_single_rw = true,
#else
.use_single_read = true,
.use_single_write = true,
};
static struct mutex serdes_lock__;
static int test_mode;
module_param(test_mode, int, 0644);
/* ========== FAKE I2C FUNCTIONS ========== */
static int z_imx390_5200_9295_read_reg(struct camera_common_data *s_data,
u16 addr, u8 *val)
{
*val = 0;
dev_info(s_data->dev,“zuojisi:z_imx390_5200_9295:FAKE r addr(0x%04x)<-0x00\n”,addr);
usleep_range(100, 110);
return 0;
}
static int z_imx390_5200_9295_write_reg(struct camera_common_data *s_data,
u16 addr, u8 val)
{
dev_info(s_data->dev,“zuojisi:z_imx390_5200_9295:FAKE w addr(0x%04x)->0x%02x\n”,addr,val);
usleep_range(100, 110);
return 0;
}
/* ========== POWER OPS ========== */
static int z_imx390_5200_9295_power_on(struct camera_common_data *s_data)
{
dev_info(s_data->dev, “zuojisi: %s (FAKE)\n”, _func_);
return 0;
}
static int z_imx390_5200_9295_power_off(struct camera_common_data *s_data)
{
dev_info(s_data->dev, “zuojisi: %s (FAKE)\n”, _func_);
return 0;
}
static int z_imx390_5200_9295_power_get(struct tegracam_device *tc_dev)
{
return 0;
}
static int z_imx390_5200_9295_power_put(struct tegracam_device *tc_dev)
{
return 0;
}
static int z_imx390_5200_9295_set_group_hold(struct tegracam_device *tc_dev, bool val)
{
dev_info(tc_dev->dev,“zuojisi: %s (FAKE)\n”,_func_);
return 0;
}
static struct tegracam_ctrl_ops z_imx390_5200_9295_ctrl_ops = {
.numctrls = ARRAY_SIZE(ctrl_cid_list),
.ctrl_cid_list = ctrl_cid_list,
.set_group_hold = z_imx390_5200_9295_set_group_hold,
};
static struct camera_common_pdata *z_imx390_5200_9295_parse_dt(struct tegracam_device *tc_dev)
{
struct device *dev = tc_dev->dev;
struct device_node *node = dev->of_node;
struct camera_common_pdata *board_priv_pdata;
const struct of_device_id *match;
if (!node)
return NULL;
match = of_match_device(z_imx390_5200_9295_of_match, dev);
if (!match) {
dev_err(dev, “Failed to find matching dt id\n”);
return NULL;
}
board_priv_pdata = devm_kzalloc(dev, sizeof(*board_priv_pdata), GFP_KERNEL);
return board_priv_pdata;
}
static int z_imx390_5200_9295_set_mode(struct tegracam_device *tc_dev)
{
dev_info(tc_dev->dev,“zuojisi:z_imx390_5200_9295 set mode (FAKE)\n”);
return 0;
}
static int z_imx390_5200_9295_start_streaming(struct tegracam_device *tc_dev)
{
struct z_imx390_5200_9295 *priv = (struct z_imx390_5200_9295 *)tegracam_get_privdata(tc_dev);
struct device *dev = tc_dev->dev;
int err;
mutex_lock(&serdes_lock__);
dev_info(dev,“zuojisi: z_imx390_5200_9295 start streaming link=%c - enter (FAKE)\n”, ‘A’+priv->des_link);
/* Skip all MAX9295 configuration */
err = z_max96724_start_streaming(priv->dser_dev, &priv->g_ctx);
if (err)
goto exit;
dev_info(dev,“zuojisi: z_imx390_5200_9295 start streaming - exit (FAKE)\n”);
mutex_unlock(&serdes_lock__);
return 0;
exit:
mutex_unlock(&serdes_lock__);
if(err){
dev_err(dev, “zuojisi: %s: error setting stream\n”, _func_);
}
return err;
}
static int z_imx390_5200_9295_stop_streaming(struct tegracam_device *tc_dev)
{
struct device *dev = tc_dev->dev;
struct z_imx390_5200_9295 *priv = (struct z_imx390_5200_9295 *)tegracam_get_privdata(tc_dev);
dev_info(dev,“zuojisi:z_imx390_5200_9295 stop streaming (FAKE)\n”);
z_max96724_stop_streaming(priv->dser_dev, &priv->g_ctx);
return 0;
}
static struct camera_common_sensor_ops z_imx390_5200_9295_common_ops = {
.numfrmfmts = ARRAY_SIZE(z_imx390_5200_9295_frmfmt),
.frmfmt_table = z_imx390_5200_9295_frmfmt,
.power_on = z_imx390_5200_9295_power_on,
.power_off = z_imx390_5200_9295_power_off,
.write_reg = z_imx390_5200_9295_write_reg,
.read_reg = z_imx390_5200_9295_read_reg,
.parse_dt = z_imx390_5200_9295_parse_dt,
.power_get = z_imx390_5200_9295_power_get,
.power_put = z_imx390_5200_9295_power_put,
.set_mode = z_imx390_5200_9295_set_mode,
.start_streaming = z_imx390_5200_9295_start_streaming,
.stop_streaming = z_imx390_5200_9295_stop_streaming,
};
static int z_imx390_5200_9295_open(struct v4l2_subdev *sd, struct v4l2_subdev_fh *fh)
{
return 0;
}
static const struct v4l2_subdev_internal_ops z_imx390_5200_9295_subdev_internal_ops = {
.open = z_imx390_5200_9295_open,
};
/* ========== BOARD SETUP ========== */
static int z_imx390_5200_9295_board_setup(struct z_imx390_5200_9295 *priv)
{
struct device *dev = &priv->i2c_client->dev;
struct device_node *node = dev->of_node;
struct device_node *dser_node;
struct i2c_client *dser_i2c = NULL;
struct device_node *gmsl;
int value = 0xFFFF;
const char *str_value1[2],*str_value;
int i;
int err;
err = of_property_read_u32(node, “reg”, &priv->act_addr);
if (err < 0) {
dev_err(dev, “zuojisi: reg not found\n”);
goto error;
}
err = of_property_read_u32(node, “def-addr”,
&priv->def_addr);
if (err < 0) {
dev_err(dev, “zuojisi: def-addr not found\n”);
goto error;
}
priv->g_ctx.ser_dev = dev;
dser_node = of_parse_phandle(node, “nvidia,gmsl-dser-device”, 0);
if (dser_node == NULL) {
dev_err(dev,
“zuojisi: missing %s handle\n”, “nvidia,gmsl-dser-device”);
err = -EINVAL;
goto error;
}
dser_i2c = of_find_i2c_device_by_node(dser_node);
of_node_put(dser_node);
if (dser_i2c == NULL) {
dev_err(dev, “zuojisi: missing deserializer dev handle\n”);
err = -EINVAL;
goto error;
}
if (dser_i2c->dev.driver == NULL) {
dev_err(dev, “zuojisi: missing deserializer driver\n”);
err = -EINVAL;
goto error;
}
priv->dser_dev = &dser_i2c->dev;
priv->g_ctx.des_dev = &dser_i2c->dev;
err = of_property_read_string(node, “des-link”, &str_value);
if (err < 0) {
dev_err(dev, “zuojisi: des-link property is not found\n”);
return -EINVAL;
}
dev_info(dev, “zuojisi: link is %s\n”,str_value);
priv->des_link = str_value[0]-‘A’;
priv->g_ctx.des_link = priv->des_link;
/* populate g_ctx from DT */
gmsl = of_get_child_by_name(node, “gmsl-link”);
if (gmsl == NULL) {
dev_err(dev, “zuojisi: missing gmsl-link device node\n”);
err = -EINVAL;
goto error;
}
err = of_property_read_u32(gmsl, “num-ser-lanes”, &value);
if (err < 0) {
dev_err(dev, “zuojisi: No num-lanes info\n”);
goto error;
}
priv->g_ctx.num_ser_csi_lanes = value;
priv->g_ctx.num_streams =
of_property_count_strings(gmsl, “streams”);
if (priv->g_ctx.num_streams <= 0) {
dev_err(dev, “zuojisi: No streams found\n”);
err = -EINVAL;
goto error;
}
for (i = 0; i < priv->g_ctx.num_streams; i++) {
of_property_read_string_index(gmsl, “streams”, i,
&str_value1[i]);
if (!str_value1[i]) {
dev_err(dev, “zuojisi: invalid stream info\n”);
goto error;
}
if (!strcmp(str_value1[i], “raw12”)) {
priv->g_ctx.streams[i] =
GMSL_CSI_DT_RAW_12;
} else if (!strcmp(str_value1[i], “embed”)) {
priv->g_ctx.streams[i] =
GMSL_CSI_DT_EMBED;
} else if (!strcmp(str_value1[i], “ued-u1”)) {
priv->g_ctx.streams[i] =
GMSL_CSI_DT_UED_U1;
} else if (!strcmp(str_value1[i], “yuv16”)) {
priv->g_ctx.streams[i] =
GMSL_CSI_DT_YUV16;
} else {
dev_err(dev, “zuojisi: invalid stream data type\n”);
goto error;
}
}
priv->g_ctx.sensor_dev = dev;
return 0;
error:
dev_err(dev, “zuojisi: board setup failed\n”);
if(err==0) err=-EINVAL;
return err;
}
/* ========== PROBE ========== */
static int @0x@0ximx390_5200_9295_probe(struct i2c_client *client,
const struct i2c_device_id *id)
{
struct device *dev = &client->dev;
struct device_node *node = dev->of_node;
struct tegracam_device *tc_dev;
struct z_imx390_5200_9295 *priv;
int err;
dev_info(dev, “zuojisi: probing v4l2 sensor @0x%x (FAKE I2C)\n”,client->addr);
if (!IS_ENABLED(CONFIG_OF) || !node)
return -EINVAL;
priv = devm_kzalloc(dev, sizeof(struct z_imx390_5200_9295), GFP_KERNEL);
if (!priv) {
dev_err(dev, “zuojisi: unable to allocate memory!\n”);
return -ENOMEM;
}
tc_dev = devm_kzalloc(dev,
sizeof(struct tegracam_device), GFP_KERNEL);
if (!tc_dev)
return -ENOMEM;
priv->i2c_client = tc_dev->client = client;
tc_dev->dev = dev;
strncpy(tc_dev->name, “z_imx390_5200_9295”, sizeof(tc_dev->name));
tc_dev->dev_regmap_config = &sensor_regmap_config;
tc_dev->sensor_ops = &z_imx390_5200_9295_common_ops;
tc_dev->v4l2sd_internal_ops = &z_imx390_5200_9295_subdev_internal_ops;
tc_dev->tcctrl_ops = &z_imx390_5200_9295_ctrl_ops;
err = z_imx390_5200_9295_board_setup(priv);
if (err) {
dev_err(dev, “zuojisi: board setup failed\n”);
return err;
}
z_max96724_lock_link(priv->dser_dev);
if ( z_max96724_check_link_status(priv->dser_dev, priv->des_link) ){
z_max96724_unlock_link(priv->dser_dev);
dev_err(dev, “zuojisi: link_%c is occupied\n”,‘A’+priv->des_link);
return -EINVAL;
}
err = tegracam_device_register(tc_dev);
if (err) {
z_max96724_unlock_link(priv->dser_dev);
dev_err(dev, “zuojisi: tegra camera driver registration failed\n”);
return err;
}
priv->tc_dev = tc_dev;
priv->s_data = tc_dev->s_data;
priv->subdev = &tc_dev->s_data->subdev;
tegracam_set_privdata(tc_dev, (void *)priv);
z_max96724_monopolize_link(priv->dser_dev, priv->des_link);
/* Skip all I2C initialization - other SoC handles it */
dev_info(dev, “zuojisi: Skipping all I2C sensor init (FAKE mode)\n”);
z_max96724_enable_link(priv->dser_dev, priv->des_link);
z_max96724_restore_link(priv->dser_dev);
z_max96724_unlock_link(priv->dser_dev);
err = tegracam_v4l2subdev_register(tc_dev, true);
if (err) {
dev_err(dev, “zuojisi: tegra camera subdev registration failed\n”);
return err;
}
dev_info(&client->dev, “zuojisi:Detected z_imx390_5200_9295 sensor (FAKE mode)\n”);
return 0;
}
static int z_imx390_5200_9295_remove(struct i2c_client *client)
{
struct camera_commo@@0xx_data *s_data = to_camera_common_data(&client->dev);
struct z_imx390_5200_9295 *priv = (struct z_imx390_5200_9295 *)s_data->priv;
tegracam_v4l2subdev_unregister(priv->tc_dev);
tegracam_device_unregister(priv->tc_dev);
dev_info(&client->dev,“zuojisi, z_imx390_5200_9295_remove sensor @0x%x.\n”,client->addr);
return 0;
}
static const struct i2c_device_id z_imx390_5200_9295_id[] = {
{ “z_imx390_5200_9295”, 0 },
{ }
};
MODULE_DEVICE_TABLE(i2c, z_imx390_5200_9295_id);
static struct i2c_driver z_imx390_5200_9295_i2c_driver = {
.driver = {
.name = “z_imx390_5200_9295”,
.owner = THIS_MODULE,
.of_match_table = of_match_ptr(z_imx390_5200_9295_of_match),
},
.probe = z_imx390_5200_9295_probe,
.remove = z_imx390_5200_9295_remove,
.id_table = z_imx390_5200_9295_id,
};
static int __init z_imx390_5200_9295_init(void)
{
mutex_init(&serdes_lock__);
return i2c_add_driver(&z_imx390_5200_9295_i2c_driver);
}
static void __exit z_imx390_5200_9295_exit(void)
{
mutex_destroy(&serdes_lock__);
i2c_del_driver(&z_imx390_5200_9295_i2c_driver);
}
late_initcall(z_imx390_5200_9295_init);
module_exit(z_imx390_5200_9295_exit);
MODULE_DESCRIPTION(“Media Controller driver for z_imx390_5200_9295 (FAKE I2C)”);
MODULE_AUTHOR(“zuojisi@163.com”);
MODULE_LICENSE(“GPL v2”);
vi-output, z_im-5079 [003] … 1715.109986: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
kworker/7:2-184 \[007\] ....... 1715.159274: rtcpu_vinotify_event: tstamp:54404995900 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1740957553984 data:0x799e300010000000
kworker/7:2-184 \[007\] ....... 1715.159277: rtcpu_vinotify_event: tstamp:54404996042 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1740957591808 data:0x0000000031000001
kworker/7:2-184 \[007\] ....... 1715.159278: rtcpu_vinotify_event: tstamp:54404996197 cch:0 vi:1 tag:VIFALC_ACTIONLST channel:0x23 frame:0 vi_tstamp:1740957611328 data:0x0000000007020001
kworker/7:2-184 \[007\] ....... 1715.159279: rtcpu_vinotify_event: tstamp:54404996334 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1740958622816 data:0x799e2d0010000000
kworker/7:2-184 \[007\] ....... 1715.159280: rtcpu_vinotify_event: tstamp:54404996488 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1740958661280 data:0x0000000031000002
kworker/7:2-184 \[007\] ....... 1717.571164: rtcpu_nvcsi_intr: tstamp:54481761270 class:GLOBAL type:PHY_INTR0 phy:1 cil:0 st:0 vc:0 status:0x01c00000
kworker/7:2-184 \[007\] ....... 1717.571168: rtcpu_nvcsi_intr: tstamp:54481761270 class:GLOBAL type:PHY_INTR0 phy:1 cil:1 st:0 vc:0 status:0x00c00000
kworker/7:2-184 \[007\] ....... 1717.627394: rtcpu_vinotify_error: tstamp:54482880375 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743452050432 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.627399: rtcpu_vinotify_event: tstamp:54483121774 cch:-1 vi:1 tag:FS channel:0x00 frame:0 vi_tstamp:1743451995488 data:0x0000000000000012
kworker/7:2-184 \[007\] ....... 1717.627399: rtcpu_vinotify_event: tstamp:54483121930 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743452050432 data:0x00000000000003c9
vi-output, z_im-5080 [006] … 1717.668125: tegra_channel_capture_setup: vnc_id 0 W 1920 H 1536 fmt 13
vi-output, z_im-5079 [003] … 1717.668640: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
vi-output, z_im-5079 [003] … 1717.669716: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
kworker/7:2-184 \[007\] ....... 1717.683184: rtcpu_vinotify_error: tstamp:54483922016 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743485382752 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.683188: rtcpu_vinotify_event: tstamp:54484098254 cch:-1 vi:1 tag:FE channel:0x00 frame:0 vi_tstamp:1743481556480 data:0x0000000000000022
kworker/7:2-184 \[007\] ....... 1717.683189: rtcpu_vinotify_event: tstamp:54484098407 cch:-1 vi:1 tag:FS channel:0x00 frame:0 vi_tstamp:1743485327808 data:0x0000000000000012
kworker/7:2-184 \[007\] ....... 1717.683190: rtcpu_vinotify_event: tstamp:54484098543 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743485382752 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.683190: rtcpu_vinotify_event: tstamp:54484917625 cch:-1 vi:1 tag:FE channel:0x00 frame:0 vi_tstamp:1743514888928 data:0x0000000000000022
kworker/7:2-184 \[007\] ....... 1717.683191: rtcpu_vinotify_event: tstamp:54484917764 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1743517278624 data:0x799e300010000000
kworker/7:2-184 \[007\] ....... 1717.683192: rtcpu_vinotify_error: tstamp:54484963652 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743518715200 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.739168: rtcpu_vinotify_event: tstamp:54485368019 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1743517420192 data:0x0000000031000001
kworker/7:2-184 \[007\] ....... 1717.739170: rtcpu_vinotify_event: tstamp:54485368162 cch:0 vi:1 tag:VIFALC_ACTIONLST channel:0x23 frame:0 vi_tstamp:1743517439712 data:0x0000000007020001
kworker/7:2-184 \[007\] ....... 1717.739171: rtcpu_vinotify_event: tstamp:54485368316 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1743518356096 data:0x799e2d0010000000
kworker/7:2-184 \[007\] ....... 1717.739171: rtcpu_vinotify_event: tstamp:54485368455 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1743518397536 data:0x0000000031000002
kworker/7:2-184 \[007\] ....... 1717.739172: rtcpu_vinotify_event: tstamp:54485368604 cch:-1 vi:1 tag:FS channel:0x00 frame:0 vi_tstamp:1743518660224 data:0x0000000000000012
kworker/7:2-184 \[007\] ....... 1717.739173: rtcpu_vinotify_event: tstamp:54485368735 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743518715200 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.739174: rtcpu_vinotify_error: tstamp:54486005283 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743552047456 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.739175: rtcpu_vinotify_event: tstamp:54486344505 cch:-1 vi:1 tag:FE channel:0x00 frame:0 vi_tstamp:1743548221216 data:0x0000000000000022
kworker/7:2-184 \[007\] ....... 1717.739176: rtcpu_vinotify_event: tstamp:54486344641 cch:-1 vi:1 tag:FS channel:0x00 frame:0 vi_tstamp:1743551992544 data:0x0000000000000012
kworker/7:2-184 \[007\] ....... 1717.739177: rtcpu_vinotify_event: tstamp:54486344793 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743552047456 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.739177: rtcpu_vinotify_error: tstamp:54487046922 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743585379968 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.795170: rtcpu_vinotify_event: tstamp:54487321043 cch:-1 vi:1 tag:FE channel:0x00 frame:0 vi_tstamp:1743581553696 data:0x0000000000000022
kworker/7:2-184 \[007\] ....... 1717.795173: rtcpu_vinotify_event: tstamp:54487321192 cch:-1 vi:1 tag:FS channel:0x00 frame:0 vi_tstamp:1743585325024 data:0x0000000000000012
kworker/7:2-184 \[007\] ....... 1717.795173: rtcpu_vinotify_event: tstamp:54487321325 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743585379968 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.795176: rtcpu_vinotify_error: tstamp:54488088556 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743618712256 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.795176: rtcpu_vinotify_event: tstamp:54488297488 cch:-1 vi:1 tag:FE channel:0x00 frame:0 vi_tstamp:1743614885984 data:0x0000000000000022
kworker/7:2-184 \[007\] ....... 1717.795177: rtcpu_vinotify_event: tstamp:54488297621 cch:-1 vi:1 tag:FS channel:0x00 frame:0 vi_tstamp:1743618657280 data:0x0000000000000012
kworker/7:2-184 \[007\] ....... 1717.795177: rtcpu_vinotify_event: tstamp:54488297778 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743618712256 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.851336: rtcpu_vinotify_event: tstamp:54489009599 cch:-1 vi:1 tag:FE channel:0x00 frame:0 vi_tstamp:1743648218464 data:0x0000000000000022
kworker/7:2-184 \[007\] ....... 1717.851340: rtcpu_vinotify_error: tstamp:54489130199 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743652044736 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.851341: rtcpu_vinotify_event: tstamp:54489470116 cch:-1 vi:1 tag:FS channel:0x00 frame:0 vi_tstamp:1743651989792 data:0x0000000000000012
kworker/7:2-184 \[007\] ....... 1717.851342: rtcpu_vinotify_event: tstamp:54489470252 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743652044736 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.851343: rtcpu_vinotify_error: tstamp:54490171834 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743685377024 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.851344: rtcpu_vinotify_event: tstamp:54490446612 cch:-1 vi:1 tag:FE channel:0x00 frame:0 vi_tstamp:1743681550752 data:0x0000000000000022
kworker/7:2-184 \[007\] ....... 1717.851344: rtcpu_vinotify_event: tstamp:54490446747 cch:-1 vi:1 tag:FS channel:0x00 frame:0 vi_tstamp:1743685322048 data:0x0000000000000012
kworker/7:2-184 \[007\] ....... 1717.851345: rtcpu_vinotify_event: tstamp:54490446899 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743685377024 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.907165: rtcpu_vinotify_error: tstamp:54491213473 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743718709504 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.907167: rtcpu_vinotify_event: tstamp:54491423088 cch:-1 vi:1 tag:FE channel:0x00 frame:0 vi_tstamp:1743714883264 data:0x0000000000000022
kworker/7:2-184 \[007\] ....... 1717.907168: rtcpu_vinotify_event: tstamp:54491423240 cch:-1 vi:1 tag:FS channel:0x00 frame:0 vi_tstamp:1743718654560 data:0x0000000000000012
kworker/7:2-184 \[007\] ....... 1717.907169: rtcpu_vinotify_event: tstamp:54491423375 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743718709504 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.907169: rtcpu_vinotify_error: tstamp:54492255108 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743752041792 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.963333: rtcpu_vinotify_event: tstamp:54492399580 cch:-1 vi:1 tag:FE channel:0x00 frame:0 vi_tstamp:1743748215520 data:0x0000000000000022
kworker/7:2-184 \[007\] ....... 1717.963335: rtcpu_vinotify_event: tstamp:54492399717 cch:-1 vi:1 tag:FS channel:0x00 frame:0 vi_tstamp:1743751986848 data:0x0000000000000012
kworker/7:2-184 \[007\] ....... 1717.963337: rtcpu_vinotify_event: tstamp:54492399868 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743752041792 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.963340: rtcpu_vinotify_error: tstamp:54493296741 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743785374112 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1717.963340: rtcpu_vinotify_event: tstamp:54493376073 cch:-1 vi:1 tag:FE channel:0x00 frame:0 vi_tstamp:1743781547872 data:0x0000000000000022
kworker/7:2-184 \[007\] ....... 1717.963341: rtcpu_vinotify_event: tstamp:54493376222 cch:-1 vi:1 tag:FS channel:0x00 frame:0 vi_tstamp:1743785319200 data:0x0000000000000012
kworker/7:2-184 \[007\] ....... 1717.963342: rtcpu_vinotify_event: tstamp:54493376354 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743785374112 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1718.019172: rtcpu_vinotify_error: tstamp:54494339360 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743818706560 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1718.019176: rtcpu_vinotify_event: tstamp:54494339666 cch:-1 vi:1 tag:FE channel:0x00 frame:0 vi_tstamp:1743814880320 data:0x0000000000000022
kworker/7:2-184 \[007\] ....... 1718.019176: rtcpu_vinotify_event: tstamp:54494339800 cch:-1 vi:1 tag:FS channel:0x00 frame:0 vi_tstamp:1743818651616 data:0x0000000000000012
kworker/7:2-184 \[007\] ....... 1718.019177: rtcpu_vinotify_event: tstamp:54494791641 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743818706560 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1718.019178: rtcpu_vinotify_event: tstamp:54495280501 cch:-1 vi:1 tag:FE channel:0x00 frame:0 vi_tstamp:1743848212576 data:0x0000000000000022
kworker/7:2-184 \[007\] ....... 1718.019179: rtcpu_vinotify_error: tstamp:54495380027 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743852038848 data:0x00000000000003c9
kworker/7:2-184 \[007\] ....... 1718.019180: rtcpu_vinotify_event: tstamp:54495769114 cch:-1 vi:1 tag:FS channel:0x00 frame:0 vi_tstamp:1743851983872 data:0x0000000000000012
kworker/7:2-184 \[007\] ....... 1718.019181: rtcpu_vinotify_event: tstamp:54495769250 cch:-1 vi:1 tag:CHANSEL_NOMATCH channel:0x04 frame:0 vi_tstamp:1743852038848 data:0x00000000000003c9
vi-output, z_im-5080 [006] … 1720.228274: tegra_channel_capture_setup: vnc_id 0 W 1920 H 1536 fmt 13
vi-output, z_im-5079 [003] … 1720.228508: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
vi-output, z_im-5079 [003] … 1720.229598: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
kworker/7:2-184 \[007\] ....... 1720.271080: rtcpu_vinotify_event: tstamp:54565105623 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1746077144832 data:0x799e300010000000
kworker/7:2-184 \[007\] ....... 1720.271083: rtcpu_vinotify_event: tstamp:54565105759 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1746077182688 data:0x0000000031000001
kworker/7:2-184 \[007\] ....... 1720.271084: rtcpu_vinotify_event: tstamp:54565105912 cch:0 vi:1 tag:VIFALC_ACTIONLST channel:0x23 frame:0 vi_tstamp:1746077202208 data:0x0000000007020001
kworker/7:2-184 \[007\] ....... 1720.271085: rtcpu_vinotify_event: tstamp:54565106057 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1746078244608 data:0x799e2d0010000000
kworker/7:2-184 \[007\] ....... 1720.271086: rtcpu_vinotify_event: tstamp:54565106209 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1746078283072 data:0x0000000031000002
vi-output, z_im-5080 [004] … 1722.788104: tegra_channel_capture_setup: vnc_id 0 W 1920 H 1536 fmt 13
vi-output, z_im-5079 [003] … 1722.788464: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
vi-output, z_im-5079 [003] … 1722.789552: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
kworker/7:2-184 \[007\] ....... 1722.846968: rtcpu_vinotify_event: tstamp:54645184579 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1748637108256 data:0x799e300010000000
kworker/7:2-184 \[007\] ....... 1722.846971: rtcpu_vinotify_event: tstamp:54645184736 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1748637146144 data:0x0000000031000001
kworker/7:2-184 \[007\] ....... 1722.846972: rtcpu_vinotify_event: tstamp:54645184871 cch:0 vi:1 tag:VIFALC_ACTIONLST channel:0x23 frame:0 vi_tstamp:1748637165632 data:0x0000000007020001
kworker/7:2-184 \[007\] ....... 1722.846973: rtcpu_vinotify_event: tstamp:54645185023 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1748638179904 data:0x799e2d0010000000
kworker/7:2-184 \[007\] ....... 1722.846974: rtcpu_vinotify_event: tstamp:54645185167 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1748638218368 data:0x0000000031000002
vi-output, z_im-5080 [004] … 1725.348144: tegra_channel_capture_setup: vnc_id 0 W 1920 H 1536 fmt 13
vi-output, z_im-5079 [003] … 1725.348293: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
vi-output, z_im-5079 [003] … 1725.349261: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
kworker/7:2-184 \[007\] ....... 1725.374859: rtcpu_vinotify_event: tstamp:54724908566 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1751196951072 data:0x799e300010000000
kworker/7:2-184 \[007\] ....... 1725.374863: rtcpu_vinotify_event: tstamp:54724908707 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1751196988928 data:0x0000000031000001
kworker/7:2-184 \[007\] ....... 1725.374864: rtcpu_vinotify_event: tstamp:54725360920 cch:0 vi:1 tag:VIFALC_ACTIONLST channel:0x23 frame:0 vi_tstamp:1751197087808 data:0x0000000007020001
kworker/7:2-184 \[007\] ....... 1725.374865: rtcpu_vinotify_event: tstamp:54725361059 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1751197909088 data:0x799e2d0010000000
kworker/7:2-184 \[007\] ....... 1725.374865: rtcpu_vinotify_event: tstamp:54725361214 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1751197947552 data:0x0000000031000002
vi-output, z_im-5080 [004] … 1727.908049: tegra_channel_capture_setup: vnc_id 0 W 1920 H 1536 fmt 13
vi-output, z_im-5079 [003] … 1727.908201: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
vi-output, z_im-5079 [003] … 1727.909129: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
kworker/7:2-184 \[007\] ....... 1727.910771: rtcpu_vinotify_event: tstamp:54804951244 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1753756885696 data:0x799e300010000000
kworker/7:2-184 \[007\] ....... 1727.910774: rtcpu_vinotify_event: tstamp:54804951398 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1753756923520 data:0x0000000031000001
kworker/7:2-184 \[007\] ....... 1727.910774: rtcpu_vinotify_event: tstamp:54804951533 cch:0 vi:1 tag:VIFALC_ACTIONLST channel:0x23 frame:0 vi_tstamp:1753756943040 data:0x0000000007020001
kworker/7:2-184 \[007\] ....... 1727.910775: rtcpu_vinotify_event: tstamp:54804951685 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1753757763456 data:0x799e2d0010000000
kworker/7:2-184 \[007\] ....... 1727.910775: rtcpu_vinotify_event: tstamp:54804951817 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1753757801920 data:0x0000000031000002
vi-output, z_im-5080 [004] … 1730.468098: tegra_channel_capture_setup: vnc_id 0 W 1920 H 1536 fmt 13
vi-output, z_im-5079 [003] … 1730.468251: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
vi-output, z_im-5079 [003] … 1730.469338: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
kworker/7:2-184 \[007\] ....... 1730.486668: rtcpu_vinotify_event: tstamp:54885030383 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1756316885056 data:0x799e300010000000
kworker/7:2-184 \[007\] ....... 1730.486672: rtcpu_vinotify_event: tstamp:54885030521 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1756316922912 data:0x0000000031000001
kworker/7:2-184 \[007\] ....... 1730.486673: rtcpu_vinotify_event: tstamp:54885030677 cch:0 vi:1 tag:VIFALC_ACTIONLST channel:0x23 frame:0 vi_tstamp:1756316945216 data:0x0000000007020001
kworker/7:2-184 \[007\] ....... 1730.486674: rtcpu_vinotify_event: tstamp:54885030812 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1756317956768 data:0x799e2d0010000000
kworker/7:2-184 \[007\] ....... 1730.486674: rtcpu_vinotify_event: tstamp:54885030965 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1756317995232 data:0x0000000031000002
vi-output, z_im-5080 [004] … 1733.027992: tegra_channel_capture_setup: vnc_id 0 W 1920 H 1536 fmt 13
vi-output, z_im-5079 [003] … 1733.029457: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
vi-output, z_im-5079 [003] … 1733.029608: vi_task_submit: class_id:48 ch:0 syncpt_id:31 syncpt_thresh:388 pid:5079 tid:5079
kworker/7:2-184 \[007\] ....... 1733.074556: rtcpu_vinotify_event: tstamp:54964945904 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1758878097824 data:0x799e300010000000
kworker/7:2-184 \[007\] ....... 1733.074560: rtcpu_vinotify_event: tstamp:54964946065 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1758878135680 data:0x0000000031000001
kworker/7:2-184 \[007\] ....... 1733.074561: rtcpu_vinotify_event: tstamp:54964946201 cch:0 vi:1 tag:VIFALC_ACTIONLST channel:0x23 frame:0 vi_tstamp:1758878182784 data:0x0000000007020001
kworker/7:2-184 \[007\] ....... 1733.074562: rtcpu_vinotify_event: tstamp:54965402499 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp:1758878322912 data:0x799e2d0010000000
kworker/7:2-184 \[007\] ....... 1733.074563: rtcpu_vinotify_event: tstamp:54965402638 cch:0 vi:1 tag:VIFALC_TDSTATE channel:0x23 frame:0 vi_tstamp