Question about tc358743 v4lv2 driver v1 and v2 version

recentlly we have a driver tc358743 requirement
I have following the doc about https://docs.nvidia.com/jetson/archives/l4t-archived/l4t-3271/#page/Tegra%20Linux%20Driver%20Package%20Development%20Guide/camera_sensor_prog.48.1.html#

and implement the v4l2 driver v1

I have successfully get the /dev/video0 and check the hdmi input are succesfully capture

mmc@ubuntu:~$ sudo v4l2-ctl --log-status -d /dev/video0
[sudo] password for mmc:
 
Status Log:
 
   [ 1796.285802] tegra194-vi5 15c10000.vi: =================  START STATUS  =================
   [ 1796.293047] tc358743 2-000f: tc358743_get_edid i2c_rd return 0
   [ 1796.293057] tc358743 2-000f: tc358743_get_edid done
   [ 1796.293064] tc358743 2-000f: -----Chip status-----
   [ 1796.293282] tc358743 2-000f: Chip ID:0x00
   [ 1796.293500] tc358743 2-000f: Chip revision:0x00
   [ 1796.293546] tc358743 2-000f: Reset: IR: 1, CEC: 1, CSI TX: 0, HDMI: 0
   [ 1796.293552] tc358743 2-000f: Sleep mode: off
   [ 1796.293558] tc358743 2-000f: Cable detected (+5V power): yes
   [ 1796.293743] tc358743 2-000f: DDC lines enabled: yes
   [ 1796.293927] tc358743 2-000f: Hotplug enabled: yes
   [ 1796.294143] tc358743 2-000f: CEC enabled: no
   [ 1796.294150] tc358743 2-000f: -----Signal status-----
   [ 1796.294155] tc358743 2-000f: TMDS signal detected: yes
   [ 1796.294161] tc358743 2-000f: Stable sync signal: yes
   [ 1796.294166] tc358743 2-000f: PHY PLL locked: yes
   [ 1796.294172] tc358743 2-000f: PHY DE detected: yes
   [ 1796.296605] tc358743 2-000f: 458:tc358743_get_detected_timings: width 1920 heigh 1080 interlaced 0
   [ 1796.296619] tc358743 2-000f: Detected format: 1920x1080p60.0 (2200x1125)
   [ 1796.296627] tc358743 2-000f: horizontal: fp = 0, -sync = 280, bp = 0
   [ 1796.296634] tc358743 2-000f: vertical: fp = 0, -sync = 45, bp = 0
   [ 1796.296642] tc358743 2-000f: pixelclock: 148500000
   [ 1796.296652] tc358743 2-000f: flags (0x0):
   [ 1796.296659] tc358743 2-000f: standards (0x0):
   [ 1796.296667] tc358743 2-000f: Configured format: 1920x1080p60.0 (2200x1125)
   [ 1796.296674] tc358743 2-000f: horizontal: fp = 88, +sync = 44, bp = 148
   [ 1796.296680] tc358743 2-000f: vertical: fp = 4, +sync = 5, bp = 36
   [ 1796.296687] tc358743 2-000f: pixelclock: 148500000
   [ 1796.296696] tc358743 2-000f: flags (0x12): CAN_REDUCE_FPS CE_VIDEO
   [ 1796.296702] tc358743 2-000f: standards (0x3): CEA DMT
   [ 1796.296708] tc358743 2-000f: -----CSI-TX status-----
   [ 1796.296715] tc358743 2-000f: Lanes needed: 2
   [ 1796.296981] tc358743 2-000f: Lanes in use: 2
   [ 1796.297192] tc358743 2-000f: Waiting for particular sync signal: no
   [ 1796.297401] tc358743 2-000f: Transmit mode: no
   [ 1796.297611] tc358743 2-000f: Receive mode: no
   [ 1796.297821] tc358743 2-000f: Stopped: no
   [ 1796.297828] tc358743 2-000f: Color space: YCbCr 422 16-bit
   [ 1796.298014] tc358743 2-000f: -----HDMI status-----
   [ 1796.298020] tc358743 2-000f: HDCP encrypted content: no
   [ 1796.298027] tc358743 2-000f: Input color space: RGB limited range
   [ 1796.298211] tc358743 2-000f: AV Mute: off
   [ 1796.298402] tc358743 2-000f: Deep color mode: 8-bits per channel
   [ 1796.299201] tc358743 2-000f: HDMI infoframe: Auxiliary Video Information (AVI), version 2, length 13
   [ 1796.299212] tc358743 2-000f:     colorspace: RGB
   [ 1796.299220] tc358743 2-000f:     scan mode: Underscan
   [ 1796.299227] tc358743 2-000f:     colorimetry: No Data
   [ 1796.299234] tc358743 2-000f:     picture aspect: 16:9
   [ 1796.299241] tc358743 2-000f:     active aspect: Same as Picture
   [ 1796.299248] tc358743 2-000f:     itc: IT Content
   [ 1796.299256] tc358743 2-000f:     extended colorimetry: xvYCC 601
   [ 1796.299264] tc358743 2-000f:     quantization range: Default
   [ 1796.299274] tc358743 2-000f:     nups: Unknown Non-uniform Scaling
   [ 1796.299281] tc358743 2-000f:     video code: 16
   [ 1796.299289] tc358743 2-000f:     ycc quantization range: Limited
   [ 1796.299296] tc358743 2-000f:     hdmi content type: Graphics
   [ 1796.299309] tc358743 2-000f:     pixel repeat: 0
   [ 1796.299316] tc358743 2-000f:     bar top 0, bottom 0, left 0, right 0
   [ 1796.299324] tegra194-vi5 15c10000.vi: ==================  END STATUS  ==================

but we I try to capture video . it same trigger the kernel oops

v4l2-ctl --set-fmt-video=width=1920,height=1080,pixelformat=RG12 --stream-mmap  --stream-count=100 -d /dev/video0
[  145.778114] tc358743 2-000f: Calling tc358743_g_input_status
[  145.778495] tc358743 2-000f: tc358743_g_input_status: status =0x0
[  145.778501] tc358743 2-000f: Now getting and setting dv timings
[  145.778502] tc358743 2-000f: Calling tc358743_query_dv_timings
[  145.780846] tc358743 2-000f: 458:tc358743_get_detected_timings: width 1920 heigh 1080 interlaced 0
[  145.780851] tc358743 2-000f: tc358743_query_dv_timings: 1920x1080p60.0 (2200x1125)
[  145.780854] tc358743 2-000f: 1111 tc358743_s_dv_timings
[  145.780856] tc358743 2-000f: tc358743_s_dv_timings: no change
[  145.780865] tc358743 2-000f: Calling tc358743_query_dv_timings
[  145.783328] tc358743 2-000f: 458:tc358743_get_detected_timings: width 1920 heigh 1080 interlaced 0
[  145.783334] tc358743 2-000f: tc358743_query_dv_timings: 1920x1080p60.0 (2200x1125)
[  145.783348] tc358743 2-000f: Calling tc358743_g_dv_timings
[  145.794676] extcon-disp-state external-connection:disp-state: cable 47 state 0
[  145.794681] Extcon AUX1(HDMI) disable
[  145.796625] Unable to handle kernel NULL pointer dereference at virtual address 000000a0
[  145.796628] Mem abort info:
[  145.796632]   ESR = 0x96000005
[  145.796635]   Exception class = DABT (current EL), IL = 32 bits
[  145.796660]   SET = 0, FnV = 0
[  145.796664]   EA = 0, S1PTW = 0
[  145.796666] Data abort info:
[  145.796669]   ISV = 0, ISS = 0x00000005
[  145.796671]   CM = 0, WnR = 0
[  145.796676] user pgtable: 4k pages, 39-bit VAs, pgd = ffffffc1cf365000
[  145.796685] [00000000000000a0] *pgd=0000000000000000, *pud=0000000000000000
[  145.796690] Internal error: Oops: 96000005 [#1] PREEMPT SMP
[  145.796695] Modules linked in:
[  145.796711] CPU: 2 PID: 17296 Comm: v4l2-ctl Not tainted 4.9.253 #15
[  145.796713] Hardware name: NVIDIA Jetson Xavier NX Developer Kit (DT)
[  145.796715] task: ffffffc1cc190000 task.stack: ffffffc1cf2d4000
[  145.796726] PC is at tegra_camera_update_clknbw+0x28/0x2a8
[  145.796733] LR is at tegra_channel_set_stream+0x1a8/0x4f0
[  145.796736] pc : [<ffffff8008527b58>] lr : [<ffffff8008b3c7d0>] pstate: 20400045
[  145.796738] sp : ffffffc1cf2d79e0
[  145.796745] x29: ffffffc1cf2d79e0 x28: ffffffc1f25f1018
[  145.796751] x27: ffffffc1e0f6d800 x26: 0000000000000001
[  145.796756] x25: ffffff8009ffe158 x24: 0000000000000001
[  145.796763] x23: ffffffc1f25f1018 x22: ffffffc1cf2d7d10
[  145.796769] x21: 0000000000000001 x20: 0000000000000000
[  145.796775] x19: ffffffc1f25f1018 x18: 0000000000000400
[  145.796781] x17: 0000007f7a912328 x16: 0000000000000000
[  145.796787] x15: 000000000000011f x14: 00000000000003ea
[  145.796793] x13: 000000000000000f x12: 0000000000000038
[  145.796798] x11: 0101010101010101 x10: 00000000000000a6
[  145.796807] x9 : 0000000000000002 x8 : 0000000000000000
[  145.796813] x7 : 00000000000003ea x6 : ffffffc1f5b80e40
[  145.796819] x5 : 0000000000000002 x4 : 0000000000000000
[  145.796825] x3 : ffffff8009e9b2c0 x2 : 0000000000000040
[  145.796831] x1 : 0000000000000001 x0 : 0000000000000000
[  145.796832]
[  145.796836] Process v4l2-ctl (pid: 17296, stack limit = 0xffffffc1cf2d4000)
[  145.796839] Call trace:
[  145.796845] [<ffffff8008527b58>] tegra_camera_update_clknbw+0x28/0x2a8
[  145.796849] [<ffffff8008b3c7d0>] tegra_channel_set_stream+0x1a8/0x4f0
[  145.796855] [<ffffff8008b4748c>] vi5_channel_start_streaming+0x2dc/0x4c8
[  145.796861] [<ffffff8008b3905c>] tegra_channel_start_streaming+0x3c/0x50
[  145.796866] [<ffffff8008b310f4>] vb2_start_streaming+0x6c/0x158
[  145.796871] [<ffffff8008b32ecc>] vb2_core_streamon+0x16c/0x1a0
[  145.796876] [<ffffff8008b35fac>] vb2_streamon+0x54/0x88
[  145.796880] [<ffffff8008b36034>] vb2_ioctl_streamon+0x54/0x60
[  145.796885] [<ffffff8008b0fbdc>] v4l_streamon+0x3c/0x50
[  145.796890] [<ffffff8008b14cdc>] __video_do_ioctl+0x204/0x2c8
[  145.796896] [<ffffff8008b14688>] video_usercopy+0x2a0/0x6a0
[  145.796903] [<ffffff8008b14ac4>] video_ioctl2+0x3c/0x50
[  145.796907] [<ffffff8008b0e528>] v4l2_ioctl+0x88/0x118
[  145.796914] [<ffffff8008271830>] do_vfs_ioctl+0xb0/0x8d8
[  145.796917] [<ffffff80082720e4>] SyS_ioctl+0x8c/0xa8
[  145.796924] [<ffffff8008083900>] el0_svc_naked+0x34/0x38

also when I use v4l2-compliance tool to scan the driver it also trigger crash

mmc@ubuntu:~$ sudo v4l2-compliance -d /dev/video0
v4l2-compliance SHA   : not available
 
Driver Info:
        Driver name   : tegra-video
        Card type     : vi-output, tc358743 2-000f
        Bus info      : platform:15c10000.vi:4
        Driver version: 4.9.253
        Capabilities  : 0x84200001
                Video Capture
                Streaming
                Extended Pix Format
                Device Capabilities
        Device Caps   : 0x04200001
                Video Capture
                Streaming
                Extended Pix Format
 
Compliance test for device /dev/video0 (not using libv4l2):
 
Required ioctls:
        test VIDIOC_QUERYCAP: OK
 
Allow for multiple opens:
        test second video open: OK
        test VIDIOC_QUERYCAP: OK
        test VIDIOC_G/S_PRIORITY: OK
        test for unlimited opens: OK
 
[  419.037080] tc358743 2-000f: tc358743_query_dv_timings: @@@@@ timings detected error
Debug ioctls:
        test VIDIOC_DBG_G/S_REGISTER: OK (Not Supported)
        test VIDIOC_LOG_STATUS: OK
 
Input ioctls:
        test VIDIOC_G/S_TUNER/ENUM_FREQ_BANDS: OK (Not Supported)
        test VIDIOC_G/S_FREQUENCY: OK (Not Supported)
        test VIDIOC_S_HW_FREQ_SEEK: OK (Not Supported)
        test VIDIOC_ENUMAUDIO: OK (Not Supported)
[  419.052819] tc358743 2-000f: tc358743_query_dv_timings: @@@@@ timings detected error
        test VIDIOC_G/S/ENUMINPUT: OK
[  419.055674] tc358743 2-000f: tc358743_query_dv_timings: @@@@@ timings detected error
        test VIDIOC_G/S_AUDIO: OK (Not Supported)
        Inputs: 1 Audio Inputs: 0 Tuners: 0
 
Output ioctls:
        test VIDIOC_G/S_MODULATOR: OK (Not Supported)
        test VIDIOC_G/S_FREQUENCY: OK (Not Supported)
        test VIDIOC_ENUMAUDOUT: OK (Not Supported)
        test VIDIOC_G/S/ENUMOUTPUT: OK (Not Supported)
        test VIDIOC_G/S_AUDOUT: OK (Not Supported)
        Outputs: 0 Audio Outputs: 0 Modulators: 0
 
Input/Output configuration ioctls:
[  419.094580] tc358743 2-000f: tc358743_query_dv_timings: @@@@@ timings detected error
        test VIDIOC_ENUM/G/S/QUERY_STD: OK (Not Supported)
[  419.107088] tc358743 2-000f: tc358743_query_dv_timings: @@@@@ timings detected error
[  419.644686] tc358743 2-000f: tc358743_s_dv_timings: timings out of range
                fail: v4l2-test-io-config.cpp(221): doioctl(node, VIDIOC_S_DV_TIMINGS, &timings)
                fail: v4l2-test-io-config.cpp(253): Timings check failed for input 0.
        test VIDIOC_ENUM/G/S/QUERY_DV_TIMINGS: FAIL
[  419.648648] tc358743 2-000f: tc358743_query_dv_timings: @@@@@ timings detected error
        test VIDIOC_DV_TIMINGS_CAP: OK
[  419.651710] tc358743 2-000f: tc358743_query_dv_timings: @@@@@ timings detected error
                fail: v4l2-test-io-config.cpp(361): !ret && check_0(edid.reserved, sizeof(edid.reserved))
                fail: v4l2-test-io-config.cpp(431): EDID check failed for input 0.
        test VIDIOC_G/S_EDID: FAIL
 
Test input 0:
 
[  419.654605] tc358743 2-000f: tc358743_query_dv_timings: @@@@@ timings detected error
        Control ioctls:
                test VIDIOC_QUERY_EXT_CTRL/QUERYMENU: OK
                test VIDIOC_QUERYCTRL: OK
                test VIDIOC_G/S_CTRL: OK
[  419.657729] Unable to handle kernel NULL pointer dereference at virtual address 000001e8
[  419.658660] Mem abort info:
[  419.659500]   ESR = 0x96000005
[  419.660282]   Exception class = DABT (current EL), IL = 32 bits
[  419.661340]   SET = 0, FnV = 0
[  419.661916]   EA = 0, S1PTW = 0
[  419.663358] Data abort info:
[  419.666368]   ISV = 0, ISS = 0x00000005
[  419.669961]   CM = 0, WnR = 0
[  419.673180] user pgtable: 4k pages, 39-bit VAs, pgd = ffffffc1d35ff000
[  419.679315] [00000000000001e8] *pgd=0000000000000000, *pud=0000000000000000
[  419.686878] Internal error: Oops: 96000005 [#1] PREEMPT SMP
[  419.692375] Modules linked in:
[  419.695203] CPU: 1 PID: 25835 Comm: v4l2-compliance Not tainted 4.9.253 #6
[  419.701735] Hardware name: NVIDIA Jetson Xavier NX Developer Kit (DT)
[  419.707865] task: ffffffc1cb766200 task.stack: ffffffc1d3588000
[  419.714080] PC is at tegra_vi5_g_volatile_ctrl+0x48/0x120
[  419.719499] LR is at tegra_vi5_g_volatile_ctrl+0x2c/0x120
[  419.724666] pc : [<ffffff8008b47808>] lr : [<ffffff8008b477ec>] pstate: 40400145
[  419.732448] sp : ffffffc1d358bac0
[  419.735777] x29: ffffffc1d358bac0 x28: ffffffc1e092aa00
[  419.741710] x27: 000000000f000000 x26: 0000000000000000
[  419.747488] x25: ffffff8009ffe7f8 x24: 0000000000000047
[  419.752921] x23: 0000000000000001 x22: 0000000000000018
[  419.758535] x21: ffffffc1d358bb60 x20: ffffffc1f4d9c420
[  419.764225] x19: ffffffc1e092aa00 x18: 0000000000000001
[  419.769854] x17: 0000007f95706600 x16: ffffff8008272058
[  419.775284] x15: ffffffffffffffff x14: ffffffc1d358bac0
[  419.781236] x13: ffffffc1d358b9c5 x12: 0000000000000000
[  419.786679] x11: ffffffc1d358b980 x10: ffffffc1d358b980
[  419.792634] x9 : 0000000000000002 x8 : 0000000000000002
[  419.798161] x7 : ffffff8008fd7180 x6 : 0000000000000090
[  419.803670] x5 : 000000000000008d x4 : 0000000000000001
[  419.809022] x3 : 00000000009a2033 x2 : 0000000000000000
[  419.814622] x1 : ffffffc1cb766200 x0 : 00000000009a2032
[  419.819969]
[  419.820736] Process v4l2-compliance (pid: 25835, stack limit = 0xffffffc1d3588000)
[  419.827913] Call trace:
[  419.830197] [<ffffff8008b47808>] tegra_vi5_g_volatile_ctrl+0x48/0x120
[  419.836317] [<ffffff8008b1e16c>] v4l2_g_ext_ctrls+0x22c/0x2f0
[  419.841913] [<ffffff8008b16538>] v4l_g_ext_ctrls+0xa0/0xd8
[  419.846729] [<ffffff8008b14c64>] __video_do_ioctl+0x204/0x2c8
[  419.852327] [<ffffff8008b14610>] video_usercopy+0x2a0/0x6a0
[  419.857405] [<ffffff8008b14a4c>] video_ioctl2+0x3c/0x50
[  419.862475] [<ffffff8008b0e4b0>] v4l2_ioctl+0x88/0x118
[  419.867033] [<ffffff8008271830>] do_vfs_ioctl+0xb0/0x8d8
[  419.872364] [<ffffff80082720e4>] SyS_ioctl+0x8c/0xa8
[  419.876918] [<ffffff8008083900>] el0_svc_naked+0x34/0x38
[  419.881991] ---[ end trace 83dd3ffb111130ce ]---

I have read the document that v4l2 have two version driver . and v1 is no support right now ?
and I try to porting the driver to v2 version but more problem show .

the doc say
V4L2 Control Ops

V4L2 control ops communicate with the V4L2 framework. These operations are handled automatically in the Jetson V4L2 Camera Framework, and need not be added to individual sensor driver:

•v4l2_ctrl_ops

•v4l2_subdev_ops

•v4l2_subdev_video_ops

•v4l2_subdev_core_ops

•v4l2_subdev_pad_ops

for one example how can I implement the log_status ops function now ?

any help would be appreciate

hello mmcuav_dev,

you may see-also developer guide for understanding V4L2 Kernel Driver (Version 1.0) and V4L2 Kernel Driver (Version 2.0).
actually, as you can see in the reference driver, both 1.0 and 2.0 were supported.

you may review your DT sources for such NULL pointer failure.
BTW, may I also know which JetPack release you’re working with?

Hi JerryChang,

very appreciate for your quick response .

I use jetpack 4.6.2 which L4T is R32.7.2

may I kown more about how can I determine the kernel NULL pointer dereference at virtual address 000000a0 is cause by DT sources ?

thanks.

please trace tegra_vi5_g_volatile_ctrl for which entry is loaded to cause NULL pointer.

sure . thanks again

Hi @JerryChang

thank you for your kind help.

now I have fixed crash when calling tegra_vi5_g_volatile_ctrl

and I can success call

sudo v4l2-compliance -d /dev/video0
v4l2-compliance 1.23.0-4976, 64 bits, 64-bit time_t
v4l2-compliance SHA: 6bd5d9c82a53 2022-11-25 14:59:11
 
Compliance test for tegra-video device /dev/video0:
 
Driver Info:
        Driver name      : tegra-video
        Card type        : vi-output, tc358743 2-000f
        Bus info         : platform:15c10000.vi:4
        Driver version   : 4.9.253
        Capabilities     : 0x84200001
                Video Capture
                Streaming
                Extended Pix Format
                Device Capabilities
        Device Caps      : 0x04200001
                Video Capture
                Streaming
                Extended Pix Format
Media Driver Info:
        Driver name      : tegra194-vi5
        Model            : NVIDIA Tegra Video Input Device
        Serial           :
        Bus info         :
        Media version    : 0.1.0
        Hardware revision: 0x00000003 (3)
        Driver version   : 0.0.0
Interface Info:
        ID               : 0x03000008
        Type             : V4L Video
Entity Info:
        ID               : 0x00000006 (6)
        Name             : vi-output, tc358743 2-000f
        Function         : V4L2 I/O
        Pad 0x01000007   : Sink
          Link 0x0200000c: from remote pad 0x1000005 of entity '15a00000.nvcsi--1' (Unknown sub-device (0002000a)): Data, Enabled
 
Required ioctls:
        test MC information (see 'Media Driver Info' above): OK
        test VIDIOC_QUERYCAP: OK
                fail: v4l2-compliance.cpp(800): doioctl(node, ioc, nullptr) != ENOTTY
        test invalid ioctls: FAIL
 
Allow for multiple opens:
        test second /dev/video0 open: OK
        test VIDIOC_QUERYCAP: OK
        test VIDIOC_G/S_PRIORITY: OK
        test for unlimited opens: OK
 
Debug ioctls:
        test VIDIOC_DBG_G/S_REGISTER: OK (Not Supported)
        test VIDIOC_LOG_STATUS: OK
 
Input ioctls:
        test VIDIOC_G/S_TUNER/ENUM_FREQ_BANDS: OK (Not Supported)
        test VIDIOC_G/S_FREQUENCY: OK (Not Supported)
        test VIDIOC_S_HW_FREQ_SEEK: OK (Not Supported)
        test VIDIOC_ENUMAUDIO: OK (Not Supported)
        test VIDIOC_G/S/ENUMINPUT: OK
        test VIDIOC_G/S_AUDIO: OK (Not Supported)
        Inputs: 1 Audio Inputs: 0 Tuners: 0
 
Output ioctls:
        test VIDIOC_G/S_MODULATOR: OK (Not Supported)
        test VIDIOC_G/S_FREQUENCY: OK (Not Supported)
        test VIDIOC_ENUMAUDOUT: OK (Not Supported)
        test VIDIOC_G/S/ENUMOUTPUT: OK (Not Supported)
        test VIDIOC_G/S_AUDOUT: OK (Not Supported)
        Outputs: 0 Audio Outputs: 0 Modulators: 0
 
Input/Output configuration ioctls:
        test VIDIOC_ENUM/G/S/QUERY_STD: OK (Not Supported)
        test VIDIOC_ENUM/G/S/QUERY_DV_TIMINGS: OK
        test VIDIOC_DV_TIMINGS_CAP: OK
                fail: v4l2-test-io-config.cpp(518): !ret && check_0(edid.reserved, sizeof(edid.reserved))
                fail: v4l2-test-io-config.cpp(625): EDID check failed for input 0.
        test VIDIOC_G/S_EDID: FAIL
 
Control ioctls (Input 0):
        test VIDIOC_QUERY_EXT_CTRL/QUERYMENU: OK
        test VIDIOC_QUERYCTRL: OK
        test VIDIOC_G/S_CTRL:
        test VIDIOC_G/S_CTRL: OK
        test TRY_EXT_CTRLS/S_CTRL:
                fail: v4l2-test-controls.cpp(848): did not check against size
        test VIDIOC_G/S/TRY_EXT_CTRLS: FAIL
        test DQEVENT:
        test VIDIOC_(UN)SUBSCRIBE_EVENT/DQEVENT: OK
        test VIDIOC_G/S_JPEGCOMP: OK (Not Supported)
        Standard Controls: 4 Private Controls: 10
        Standard Compound Controls: 0 Private Compound Controls: 7
 
Format ioctls (Input 0):
        test VIDIOC_ENUM_FMT/FRAMESIZES/FRAMEINTERVALS: OK
                fail: v4l2-test-formats.cpp(1362): ret && node->has_frmintervals
        test VIDIOC_G/S_PARM: FAIL
        test VIDIOC_G_FBUF: OK (Not Supported)
        test VIDIOC_G_FMT: OK
        test VIDIOC_TRY_FMT: OK
        test VIDIOC_S_FMT: OK
        test VIDIOC_G_SLICED_VBI_CAP: OK (Not Supported)
        test Cropping: OK (Not Supported)
        test Composing: OK (Not Supported)
        test Scaling: OK (Not Supported)
 
Codec ioctls (Input 0):
        test VIDIOC_(TRY_)ENCODER_CMD: OK (Not Supported)
        test VIDIOC_G_ENC_INDEX: OK (Not Supported)
        test VIDIOC_(TRY_)DECODER_CMD: OK (Not Supported)
 
Buffer ioctls (Input 0):
                fail: v4l2-test-buffers.cpp(751): q.create_bufs(node, 1, &fmt) != EINVAL
        test VIDIOC_REQBUFS/CREATE_BUFS/QUERYBUF: FAIL
        test VIDIOC_EXPBUF: OK
        test Requests: OK (Not Supported)
 
Total for tegra-video device /dev/video0: 46, Succeeded: 41, Failed: 5, Warnings: 0

and also

sudo v4l2-ctl -d /dev/video0 --log-status

Status Log:

   [  838.532534] tegra194-vi5 15c10000.vi: =================  START STATUS  =================
   [  838.540191] tc358743 2-000f: tc358743_get_edid i2c_rd return 0
  [  838.543667] tc358743 2-000f: tc358743_get_edid done
   [  838.543692] tc358743 2-000f: -----Chip status-----
   [  838.544863] tc358743 2-000f: Chip ID:0x00
   [  838.545135] tc358743 2-000f: Chip revision:0x00
   [  838.545146] tc358743 2-000f: Reset: IR: 1, CEC: 1, CSI TX: 0, HDMI: 0
   [  838.545153] tc358743 2-000f: Sleep mode: off
   [  838.545159] tc358743 2-000f: Cable detected (+5V power): yes
   [  838.545367] tc358743 2-000f: DDC lines enabled: yes
   [  838.545558] tc358743 2-000f: Hotplug enabled: yes
   [  838.545810] tc358743 2-000f: CEC enabled: no
   [  838.545819] tc358743 2-000f: -----Signal status-----
   [  838.545830] tc358743 2-000f: TMDS signal detected: yes
   [  838.545836] tc358743 2-000f: Stable sync signal: yes
   [  838.545841] tc358743 2-000f: PHY PLL locked: yes
   [  838.545847] tc358743 2-000f: PHY DE detected: yes
   [  838.545854] tc358743 2-000f: function no_signal
   [  838.546072] tc358743 2-000f: function no_sync
   [  838.548495] tc358743 2-000f: 465:tc358743_get_detected_timings: width 1920 heigh 1080 interlaced 0
   [  838.548510] tc358743 2-000f: Detected format: 1920x1080p60.0 (2200x1125)
   [  838.548516] tc358743 2-000f: horizontal: fp = 0, -sync = 280, bp = 0
   [  838.548521] tc358743 2-000f: vertical: fp = 0, -sync = 45, bp = 0
   [  838.548529] tc358743 2-000f: pixelclock: 148500000
   [  838.548535] tc358743 2-000f: flags (0x0):
   [  838.548547] tc358743 2-000f: standards (0x0):
   [  838.548554] tc358743 2-000f: Configured format: 1920x1080p60.0 (2200x1125)
   [  838.548565] tc358743 2-000f: horizontal: fp = 0, -sync = 280, bp = 0
   [  838.548570] tc358743 2-000f: vertical: fp = 0, -sync = 45, bp = 0
   [  838.548610] tc358743 2-000f: pixelclock: 148500000
   [  838.548616] tc358743 2-000f: flags (0x0):
   [  838.548623] tc358743 2-000f: standards (0x0):
   [  838.548626] tc358743 2-000f: -----CSI-TX status-----
   [  838.548631] tc358743 2-000f: function tc358743_num_csi_lanes_needed
   [  838.548638] tc358743 2-000f: Lanes needed: 2
   [  838.548643] tc358743 2-000f: function tc358743_num_csi_lanes_in_use
   [  838.549076] tc358743 2-000f: Lanes in use: 2
   [  838.549317] tc358743 2-000f: Waiting for particular sync signal: no
   [  838.549531] tc358743 2-000f: Transmit mode: no
   [  838.549741] tc358743 2-000f: Receive mode: no
   [  838.549955] tc358743 2-000f: Stopped: no
   [  838.549960] tc358743 2-000f: Color space: YCbCr 422 16-bit
   [  838.549966] tc358743 2-000f: function is_hdmi
   [  838.550148] tc358743 2-000f: -----HDMI status-----
   [  838.550152] tc358743 2-000f: HDCP encrypted content: no
   [  838.550157] tc358743 2-000f: Input color space: RGB limited range
   [  838.550161] tc358743 2-000f: function is_hdmi
   [  838.550354] tc358743 2-000f: AV Mute: off
   [  838.550551] tc358743 2-000f: Deep color mode: 8-bits per channel
   [  838.550557] tc358743 2-000f: function print_avi_infoframe
   [  838.550562] tc358743 2-000f: function is_hdmi
   [  838.551353] tc358743 2-000f: HDMI infoframe: Auxiliary Video Information (AVI), version 2, length 13
   [  838.551364] tc358743 2-000f:     colorspace: RGB
   [  838.551369] tc358743 2-000f:     scan mode: Underscan
   [  838.551374] tc358743 2-000f:     colorimetry: No Data
   [  838.551378] tc358743 2-000f:     picture aspect: 16:9
   [  838.551387] tc358743 2-000f:     active aspect: Same as Picture
   [  838.551396] tc358743 2-000f:     itc: IT Content
   [  838.551401] tc358743 2-000f:     extended colorimetry: xvYCC 601
   [  838.551405] tc358743 2-000f:     quantization range: Default
   [  838.551410] tc358743 2-000f:     nups: Unknown Non-uniform Scaling
   [  838.551414] tc358743 2-000f:     video code: 16
   [  838.551418] tc358743 2-000f:     ycc quantization range: Limited
   [  838.551422] tc358743 2-000f:     hdmi content type: Graphics
   [  838.551427] tc358743 2-000f:     pixel repeat: 0
   [  838.551433] tc358743 2-000f:     bar top 0, bottom 0, left 0, right 0
   [  838.551439] tegra194-vi5 15c10000.vi: ==================  END STATUS  ==================

but when i try to catch video with

gst-launch-1.0 v4l2src device=/dev/video0 ! 'video/x-raw,format=UYVY,width=1280,height=720' ! \
nvvidconv ! omxh264enc ! mpegtsmux ! filesink location=test.ts

i got nothing output in the test.ts

and now I am doubt about the csi connection and the device tree configure whether I make it right

here is my custom board csi connect
image

and the device tree I set to it is


  
         vi@15c10000  {
            num-channels = <1>;
            ports {
                #address-cells = <1>;
                #size-cells = <0>;
                tc358743_vi_port2: port@0 {
                    status = "okay";
                    reg = <0>;
                    tc358743_vi_in0: endpoint {
                        status = "okay";
                        port-index = <4>;
                        csi-port = <4>;  /* CSI-E */
                        bus-width = <4>; /* Use CSI-EF*/
                        remote-endpoint = <&tc358743_csi_out0>;
                    };
                };
            };
        };

  
  nvcsi@15a00000 {
    num-channels = <1>;
    #address-cells = <1>;
    #size-cells = <0>;
    channel@0 {
            reg = <0>;
            status = "okay";
            ports {
                #address-cells = <1>;
                #size-cells = <0>;
                port@0 {
                    status = "okay";
                    reg = <0>;
                    tc358743_csi_in0: endpoint@0 {
                        status = "okay";
                        port-index = <4>;
                        csi-port = <4>;
                        bus-width = <4>;
                        remote-endpoint = <&tc358743_out0>;
                    };
                };
                port@1 {
                    status = "okay";
                    reg = <1>;
                    tc358743_csi_out0: endpoint@1 {
                    status = "okay";
                    remote-endpoint = <&tc358743_vi_in0>;
                };
            };
        };
    };
};
};

  i2c@3180000 {  /* I2C_0, "adapter" 0 */
        status = "okay";
        #address-cells = <1>;
        #size-cells = <0>;
        
        tc358743@0f {
            ...
            ports {
                status = "okay";
                #address-cells = <1>;
                #size-cells = <0>;
                
                port@0 {
                    status = "okay";
                    reg = <0>;
                    tc358743_out0: endpoint {
                        port-index = <4>; /* CSI E */
                        bus-width = <4>; /* Use CSI-E F */
                        data-lanes = <1 2 3 4>;
                        clock-lanes = <4>; # CLOCK E 
                        clock-noncontinuous;
                        link-frequencies = /bits/ 64 <297000000>;
                        remote-endpoint = <&tc358743_csi_in0>;
                    };
                };
            };
        };
    };

which csi port and vi port index are 4 ,means CSI E F and also clock-lanes = <4> which meas CLOCK E

I am not sure if it is right for that configuration .

Thanks again.

hello mmcuav_dev,

that device tree connections looks correct.
could you please have v4l2 standard controls to access the stream.
for example,
$ v4l2-ctl -d /dev/video0 --set-fmt-video=width=1280,height=720,pixelformat=UYVY --stream-mmap --stream-count=100

and…
please also follow below steps to enable VI tracing logs.
for example,

echo 1 > /sys/kernel/debug/tracing/tracing_on
echo 30720 > /sys/kernel/debug/tracing/buffer_size_kb
echo 1 > /sys/kernel/debug/tracing/events/tegra_rtcpu/enable
echo 1 > /sys/kernel/debug/tracing/events/freertos/enable
echo 2 > /sys/kernel/debug/camrtc/log-level
echo > /sys/kernel/debug/tracing/trace
cat /sys/kernel/debug/tracing/trace
# or, to review dynamic tracing log
# cat /sys/kernel/debug/tracing/trace_pipe

Hi JerryChang,

I have follow the command as you mention

v4l2-ctl -d /dev/video0 --log-status

Status Log:

   [   69.481335] tegra194-vi5 15c10000.vi: =================  START STATUS  =================
   [   69.488583] tc358743 2-000f: tc358743_get_edid i2c_rd return 0
   [   69.489078] tc358743 2-000f: tc358743_get_edid done
   [   69.489080] tc358743 2-000f: -----Chip status-----
   [   69.489290] tc358743 2-000f: Chip ID:0x00
   [   69.489499] tc358743 2-000f: Chip revision:0x00
   [   69.489501] tc358743 2-000f: Reset: IR: 1, CEC: 1, CSI TX: 0, HDMI: 0
   [   69.489502] tc358743 2-000f: Sleep mode: off
   [   69.489504] tc358743 2-000f: Cable detected (+5V power): yes
   [   69.489685] tc358743 2-000f: DDC lines enabled: yes
   [   69.489869] tc358743 2-000f: Hotplug enabled: yes
   [   69.490074] tc358743 2-000f: CEC enabled: no
   [   69.490076] tc358743 2-000f: -----Signal status-----
   [   69.490077] tc358743 2-000f: TMDS signal detected: yes
   [   69.490079] tc358743 2-000f: Stable sync signal: yes
   [   69.490080] tc358743 2-000f: PHY PLL locked: yes
   [   69.490081] tc358743 2-000f: PHY DE detected: yes
   [   69.490083] tc358743 2-000f: function no_signal
   [   69.490262] tc358743 2-000f: function no_sync
   [   69.492401] tc358743 2-000f: 465:tc358743_get_detected_timings: width 1920 heigh 1080 interlaced 0
   [   69.492406] tc358743 2-000f: Detected format: 1920x1080p60.0 (2200x1125)
   [   69.492408] tc358743 2-000f: horizontal: fp = 0, -sync = 280, bp = 0
   [   69.492409] tc358743 2-000f: vertical: fp = 0, -sync = 45, bp = 0
   [   69.492412] tc358743 2-000f: pixelclock: 148500000
   [   69.492416] tc358743 2-000f: flags (0x0):
   [   69.492418] tc358743 2-000f: standards (0x0):
   [   69.492420] tc358743 2-000f: Configured format: 1920x1080p60.0 (2200x1125)
   [   69.492442] tc358743 2-000f: horizontal: fp = 88, +sync = 44, bp = 148
   [   69.492444] tc358743 2-000f: vertical: fp = 4, +sync = 5, bp = 36
   [   69.492446] tc358743 2-000f: pixelclock: 148500000
   [   69.492448] tc358743 2-000f: flags (0x12): CAN_REDUCE_FPS CE_VIDEO
   [   69.492451] tc358743 2-000f: standards (0x3): CEA DMT
   [   69.492452] tc358743 2-000f: -----CSI-TX status-----
   [   69.492454] tc358743 2-000f: function tc358743_num_csi_lanes_needed
   [   69.492455] tc358743 2-000f: Lanes needed: 2
   [   69.492457] tc358743 2-000f: function tc358743_num_csi_lanes_in_use
   [   69.492712] tc358743 2-000f: Lanes in use: 2
   [   69.492920] tc358743 2-000f: Waiting for particular sync signal: no
   [   69.493125] tc358743 2-000f: Transmit mode: no
   [   69.493332] tc358743 2-000f: Receive mode: no
   [   69.493536] tc358743 2-000f: Stopped: no
   [   69.493537] tc358743 2-000f: Color space: YCbCr 422 16-bit
   [   69.493539] tc358743 2-000f: function is_hdmi
   [   69.493737] tc358743 2-000f: -----HDMI status-----
   [   69.493740] tc358743 2-000f: HDCP encrypted content: no
   [   69.493742] tc358743 2-000f: Input color space: RGB limited range
   [   69.493743] tc358743 2-000f: function is_hdmi
   [   69.493924] tc358743 2-000f: AV Mute: off
   [   69.494103] tc358743 2-000f: Deep color mode: 8-bits per channel
   [   69.494105] tc358743 2-000f: function print_avi_infoframe
   [   69.494107] tc358743 2-000f: function is_hdmi
   [   69.494875] tc358743 2-000f: HDMI infoframe: Auxiliary Video Information (AVI), version 2, length 13
   [   69.494897] tc358743 2-000f:     colorspace: RGB
   [   69.494900] tc358743 2-000f:     scan mode: Underscan
   [   69.494902] tc358743 2-000f:     colorimetry: No Data
   [   69.494904] tc358743 2-000f:     picture aspect: 16:9
   [   69.494907] tc358743 2-000f:     active aspect: Same as Picture
   [   69.494908] tc358743 2-000f:     itc: IT Content
   [   69.494910] tc358743 2-000f:     extended colorimetry: xvYCC 601
   [   69.494912] tc358743 2-000f:     quantization range: Default
   [   69.494914] tc358743 2-000f:     nups: Unknown Non-uniform Scaling
   [   69.494917] tc358743 2-000f:     video code: 16
   [   69.494919] tc358743 2-000f:     ycc quantization range: Limited
   [   69.494921] tc358743 2-000f:     hdmi content type: Graphics
   [   69.494923] tc358743 2-000f:     pixel repeat: 0
   [   69.494925] tc358743 2-000f:     bar top 0, bottom 0, left 0, right 0
   [   69.494928] tegra194-vi5 15c10000.vi: ==================  END STATUS  ==================

It seems I can no get any useful information from the output .

hello mmcuav_dev,

it looks like VI engine side did not receive any validate signaling.
you should at least have start-of-frame and end-of-frame coming to CSI brick.

is it possible to enable test-pattern-generator of this tc358743 bridge driver?
this may helps to narrow down the issue.

I am no sure what test-pattern-generator is something like ? maybe it is something like make tc358743 to continue generate csi signal without v4l2 to command it to start transmmit . Whatever now with your help I can sure that the device tree configure is right , the problem can be narrow to csi transmite part .

then I can check the csi output signal or something else method .

thank you for your kindly help.

hello mmcuav_dev,

test-pattern-generator is one functionality on that bridge chip, it’s able to send color bars to CSI brick by itself.
please check CSI output signal, VI engine should see frames if there’s high speed signaling.

for debugging.
you may also follow below commands to boost all the VI/CSI/ISP clocks to eliminate clock config related issues.
for example,

sudo su
echo 1 > /sys/kernel/debug/bpmp/debug/clk/vi/mrq_rate_locked
echo 1 > /sys/kernel/debug/bpmp/debug/clk/isp/mrq_rate_locked
echo 1 > /sys/kernel/debug/bpmp/debug/clk/nvcsi/mrq_rate_locked
echo 1 > /sys/kernel/debug/bpmp/debug/clk/emc/mrq_rate_locked
cat /sys/kernel/debug/bpmp/debug/clk/vi/max_rate |tee /sys/kernel/debug/bpmp/debug/clk/vi/rate
cat /sys/kernel/debug/bpmp/debug/clk/isp/max_rate | tee /sys/kernel/debug/bpmp/debug/clk/isp/rate
cat /sys/kernel/debug/bpmp/debug/clk/nvcsi/max_rate | tee /sys/kernel/debug/bpmp/debug/clk/nvcsi/rate
cat /sys/kernel/debug/bpmp/debug/clk/emc/max_rate | tee /sys/kernel/debug/bpmp/debug/clk/emc/rate

Hi @JerryChang

A long time try . I have’t get the video yet . Here I have some question about nvcsi/vi port link .

Because my hardware use CSI E F and CSI E clock .

In my device tree I assign with


  
         vi@15c10000  {
            num-channels = <1>;
            ports {
                #address-cells = <1>;
                #size-cells = <0>;
                tc358743_vi_port2: port@0 {
                    status = "okay";
                    reg = <0>;
                    tc358743_vi_in0: endpoint {
                        status = "okay";
                        port-index = <4>;
                        csi-port = <4>;  /* CSI-E */
                        bus-width = <4>; /* Use CSI-EF*/
                        remote-endpoint = <&tc358743_csi_out0>;
                    };
                };
            };
        };

  
  nvcsi@15a00000 {
    num-channels = <1>;
    #address-cells = <1>;
    #size-cells = <0>;
    channel@0 {
            reg = <0>;
            status = "okay";
            ports {
                #address-cells = <1>;
                #size-cells = <0>;
                port@0 {
                    status = "okay";
                    reg = <0>;
                    tc358743_csi_in0: endpoint@0 {
                        status = "okay";
                        port-index = <4>;
                        csi-port = <4>;
                        bus-width = <4>;
                        remote-endpoint = <&tc358743_out0>;
                    };
                };
                port@1 {
                    status = "okay";
                    reg = <1>;
                    tc358743_csi_out0: endpoint@1 {
                    status = "okay";
                    remote-endpoint = <&tc358743_vi_in0>;
                };
            };
        };
    };
};
};

  i2c@3180000 {  /* I2C_0, "adapter" 0 */
        status = "okay";
        #address-cells = <1>;
        #size-cells = <0>;
        
        tc358743@0f {
            ...
            ports {
                status = "okay";
                #address-cells = <1>;
                #size-cells = <0>;
                
                port@0 {
                    status = "okay";
                    reg = <0>;
                    tc358743_out0: endpoint {
                        port-index = <4>; /* CSI E */
                        bus-width = <4>; /* Use CSI-E F */
                        data-lanes = <1 2 3 4>;
                        clock-lanes = <4>; # CLOCK E 
                        clock-noncontinuous;
                        link-frequencies = /bits/ 64 <297000000>;
                        remote-endpoint = <&tc358743_csi_in0>;
                    };
                };
            };
        };
    };

but I have find any csi-port or clock-lanes when tegra194-camera-imx185_v1-a00.dtsi

and it has

	mode4 {/*mode IMX185_MODE_1920X1080_CROP_HDR_30FPS*/
					mclk_khz = "37125";
					num_lanes = "4";
					tegra_sinterface = "serial_a";
					phy_mode = "DPHY";
					discontinuous_clk = "no";

tegra_sinterface and phy_mode defination whihc I am no assign in tc358743 . is it correct ?

here is my complete device tree file
tegra194-xavier-tc358743.dtsi (5.3 KB)

update


root@ubuntu:/home/mmc# cat /sys/kernel/debug/bpmp/debug/clk/vi/max_rate |tee /sys/kernel/debug/bpmp/debug/clk/vi/rate
460800000
root@ubuntu:/home/mmc# cat /sys/kernel/debug/bpmp/debug/clk/vi/max_rate |tee /sys/kernel/debug/bpmp/debug/clk/vi/rate
460800000
root@ubuntu:/home/mmc# echo 1 > /sys/kernel/debug/bpmp/debug/clk/vi/mrq_rate_locked
root@ubuntu:/home/mmc# cat /sys/kernel/debug/bpmp/debug/clk/vi/max_rate |tee /sys/kernel/debug/bpmp/debug/clk/vi/rate
460800000
root@ubuntu:/home/mmc# cat /sys/kernel/debug/bpmp/debug/clk/vi/max_rate |tee /sys/kernel/debug/bpmp/debug/clk/vi/rate
460800000
root@ubuntu:/home/mmc# echo 1 > /sys/kernel/debug/bpmp/debug/clk/isp/mrq_rate_locked
root@ubuntu:/home/mmc# echo 1 > /sys/kernel/debug/bpmp/debug/clk/nvcsi/mrq_rate_locked
root@ubuntu:/home/mmc# echo 1 > /sys/kernel/debug/bpmp/debug/clk/emc/mrq_rate_locked
root@ubuntu:/home/mmc# cat /sys/kernel/debug/bpmp/debug/clk/vi/max_rate |tee /sys/kernel/debug/bpmp/debug/clk/vi/rate
460800000
root@ubuntu:/home/mmc# cat /sys/kernel/debug/bpmp/debug/clk/isp/max_rate | tee /sys/kernel/debug/bpmp/debug/clk/isp/rate
576000000
root@ubuntu:/home/mmc# cat /sys/kernel/debug/bpmp/debug/clk/nvcsi/max_rate | tee /sys/kernel/debug/bpmp/debug/clk/nvcsi/rate
314000000
root@ubuntu:/home/mmc# cat /sys/kernel/debug/bpmp/debug/clk/emc/max_rate | tee /sys/kernel/debug/bpmp/debug/clk/emc/rate
1866000000
root@ubuntu:/home/mmc# 

and also


echo 1 > /sys/kernel/debug/tracing/tracing_on
echo 30720 > /sys/kernel/debug/tracing/buffer_size_kb
echo 1 > /sys/kernel/debug/tracing/events/tegra_rtcpu/enable
echo 1 > /sys/kernel/debug/tracing/events/freertos/enable
echo 2 > /sys/kernel/debug/camrtc/log-level
echo > /sys/kernel/debug/tracing/trace
cat /sys/kernel/debug/tracing/trace
# or, to review dynamic tracing log
# cat /sys/kernel/debug/tracing/trace_pipe

get me


kworker/1:2-1391  [001] ....   457.941678: rtos_queue_peek_from_isr_failed: tstamp:14604589320 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   458.114385: rtos_queue_peek_from_isr_failed: tstamp:14609589321 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   458.169709: rtos_queue_send_from_isr_failed: tstamp:14611129828 queue:0x0bcb2b38
     kworker/1:2-1391  [001] ....   458.169912: rtos_queue_send_from_isr_failed: tstamp:14611129972 queue:0x0bcb73a0
     kworker/1:2-1391  [001] ....   458.169928: rtos_queue_send_from_isr_failed: tstamp:14611130119 queue:0x0bcb8f20
     kworker/1:2-1391  [001] ....   458.169940: rtos_queue_send_from_isr_failed: tstamp:14611130258 queue:0x0bcb9ce0
     kworker/1:2-1391  [001] ....   458.169953: rtos_queue_send_from_isr_failed: tstamp:14611130398 queue:0x0bcbaaa0
     kworker/1:2-1391  [001] ....   458.169965: rtos_queue_send_from_isr_failed: tstamp:14611130599 queue:0x0bcb2ad0
     kworker/1:2-1391  [001] ....   458.169976: rtos_queue_send_from_isr_failed: tstamp:14611130728 queue:0x0bcb2b38
     kworker/1:2-1391  [001] ....   458.169988: rtos_queue_send_from_isr_failed: tstamp:14611130858 queue:0x0bcb7338
     kworker/1:2-1391  [001] ....   458.170000: rtos_queue_send_from_isr_failed: tstamp:14611130986 queue:0x0bcb73a0
     kworker/1:2-1391  [001] ....   458.170011: rtos_queue_send_from_isr_failed: tstamp:14611131120 queue:0x0bcb8eb8
     kworker/1:2-1391  [001] ....   458.170023: rtos_queue_send_from_isr_failed: tstamp:14611131244 queue:0x0bcb8f20
     kworker/1:2-1391  [001] ....   458.170137: rtos_queue_send_from_isr_failed: tstamp:14611131374 queue:0x0bcb9c78
     kworker/1:2-1391  [001] ....   458.170152: rtos_queue_send_from_isr_failed: tstamp:14611131499 queue:0x0bcb9ce0
     kworker/1:2-1391  [001] ....   458.170165: rtos_queue_send_from_isr_failed: tstamp:14611131627 queue:0x0bcbaa38
     kworker/1:2-1391  [001] ....   458.170460: rtos_queue_send_from_isr_failed: tstamp:14611131753 queue:0x0bcbaaa0
     kworker/1:2-1391  [001] ....   458.170474: rtos_queue_send_from_isr_failed: tstamp:14611151947 queue:0x0bcb2b38
     kworker/1:2-1391  [001] ....   458.170485: rtos_queue_send_from_isr_failed: tstamp:14611152091 queue:0x0bcb73a0
     kworker/1:2-1391  [001] ....   458.170497: rtos_queue_send_from_isr_failed: tstamp:14611152235 queue:0x0bcb8f20
     kworker/1:2-1391  [001] ....   458.170509: rtos_queue_send_from_isr_failed: tstamp:14611152374 queue:0x0bcb9ce0
     kworker/1:2-1391  [001] ....   458.170521: rtos_queue_send_from_isr_failed: tstamp:14611152511 queue:0x0bcbaaa0
     kworker/1:2-1391  [001] ....   458.170533: rtos_queue_send_from_isr_failed: tstamp:14611190160 queue:0x0bcb2b38
     kworker/1:2-1391  [001] ....   458.170552: rtos_queue_send_from_isr_failed: tstamp:14611190304 queue:0x0bcb73a0
     kworker/1:2-1391  [001] ....   458.170569: rtos_queue_send_from_isr_failed: tstamp:14611190448 queue:0x0bcb8f20
     kworker/1:2-1391  [001] ....   458.170582: rtos_queue_send_from_isr_failed: tstamp:14611190587 queue:0x0bcb9ce0
     kworker/1:2-1391  [001] ....   458.170598: rtos_queue_send_from_isr_failed: tstamp:14611190726 queue:0x0bcbaaa0
     kworker/1:2-1391  [001] ....   458.170613: rtos_queue_send_from_isr_failed: tstamp:14611208191 queue:0x0bcb2b38
     kworker/1:2-1391  [001] ....   458.170910: rtos_queue_send_from_isr_failed: tstamp:14611208333 queue:0x0bcb73a0
     kworker/1:2-1391  [001] ....   458.170928: rtos_queue_send_from_isr_failed: tstamp:14611208477 queue:0x0bcb8f20
     kworker/1:2-1391  [001] ....   458.170944: rtos_queue_send_from_isr_failed: tstamp:14611208616 queue:0x0bcb9ce0
     kworker/1:2-1391  [001] ....   458.170966: rtos_queue_send_from_isr_failed: tstamp:14611208753 queue:0x0bcbaaa0
     kworker/1:2-1391  [001] ....   458.170986: rtcpu_string: tstamp:14611209180 id:0x04010000 str:"Configuring VI GoS.
"
     kworker/1:2-1391  [001] ....   458.171109: rtcpu_string: tstamp:14611209372 id:0x04010000 str:"VM GOS[#0] addr=0xc2100000
"
     kworker/1:2-1391  [001] ....   458.171234: rtcpu_string: tstamp:14611209617 id:0x04010000 str:"VM GOS[#1] addr=0xc2101000
"
     kworker/1:2-1391  [001] ....   458.171303: rtcpu_string: tstamp:14611209849 id:0x04010000 str:"VM GOS[#2] addr=0xc2102000
"
     kworker/1:2-1391  [001] ....   458.171377: rtcpu_string: tstamp:14611210072 id:0x04010000 str:"VM GOS[#3] addr=0xc2103000
"
     kworker/1:2-1391  [001] ....   458.171446: rtcpu_string: tstamp:14611210311 id:0x04010000 str:"VM GOS[#4] addr=0xc2104000
"
     kworker/1:2-1391  [001] ....   458.171516: rtcpu_string: tstamp:14611210534 id:0x04010000 str:"VM GOS[#5] addr=0xc2105000
"
     kworker/1:2-1391  [001] ....   458.171583: rtos_queue_send_from_isr_failed: tstamp:14611217646 queue:0x0bcb2b38
     kworker/1:2-1391  [001] ....   458.171595: rtos_queue_send_from_isr_failed: tstamp:14611217787 queue:0x0bcb73a0
     kworker/1:2-1391  [001] ....   458.171607: rtos_queue_send_from_isr_failed: tstamp:14611217931 queue:0x0bcb8f20
     kworker/1:2-1391  [001] ....   458.171618: rtos_queue_send_from_isr_failed: tstamp:14611218070 queue:0x0bcb9ce0
     kworker/1:2-1391  [001] ....   458.171630: rtos_queue_send_from_isr_failed: tstamp:14611218208 queue:0x0bcbaaa0
     kworker/1:2-1391  [001] ....   458.171646: rtcpu_vinotify_event: tstamp:14611394853 tag:RESERVED_18 channel:0x23 frame:0 vi_tstamp:16587472544 data:0x10000000
     kworker/1:2-1391  [001] ....   458.171660: rtcpu_vinotify_event: tstamp:14611395010 tag:RESERVED_18 channel:0x23 frame:0 vi_tstamp:16587480736 data:0x31000001
     kworker/1:2-1391  [001] ....   458.171678: rtcpu_vinotify_event: tstamp:14611395142 tag:RESERVED_19 channel:0x23 frame:0 vi_tstamp:16587482880 data:0x07020001
     kworker/1:2-1391  [001] ....   458.171694: rtcpu_vinotify_event: tstamp:14611395290 tag:RESERVED_18 channel:0x23 frame:0 vi_tstamp:16587516224 data:0x10000000
     kworker/1:2-1391  [001] ....   458.171711: rtcpu_vinotify_event: tstamp:14611395418 tag:RESERVED_18 channel:0x23 frame:0 vi_tstamp:16587524512 data:0x31000002
     kworker/1:2-1391  [001] ....   458.281723: rtos_queue_peek_from_isr_failed: tstamp:14614589321 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   458.393697: rtos_queue_peek_from_isr_failed: tstamp:14619589321 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   458.561679: rtos_queue_peek_from_isr_failed: tstamp:14624589316 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   458.729654: rtos_queue_peek_from_isr_failed: tstamp:14629589323 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   458.897642: rtos_queue_peek_from_isr_failed: tstamp:14634589320 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   459.065787: rtos_queue_peek_from_isr_failed: tstamp:14639589316 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   459.233661: rtos_queue_peek_from_isr_failed: tstamp:14644589323 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   459.401686: rtos_queue_peek_from_isr_failed: tstamp:14649589319 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   459.513664: rtos_queue_peek_from_isr_failed: tstamp:14654589321 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   459.681639: rtos_queue_peek_from_isr_failed: tstamp:14659589320 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   459.849677: rtos_queue_peek_from_isr_failed: tstamp:14664589320 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   460.017629: rtos_queue_peek_from_isr_failed: tstamp:14669589320 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   460.185655: rtos_queue_peek_from_isr_failed: tstamp:14674589321 queue:0x0bcbb8b8
     kworker/1:2-1391  [001] ....   460.353740: rtos_queue_peek_from_isr_failed: tstamp:14679589320 queue:0x0bcbb8b8

hello mmcuav_dev,

below settings are unnecessary since you’re using bridge driver.

you should configure device tree correctly for setting up TC358743 -> NVCSI -> VI port bindings.
you may see-also developer guide for To verify the port binding result to review the device topology.

according those VI tracing logs.
it seems there’re valid timestamps on the CSI channel, however, it doesn’t contain start-of-frame, and end-of-frame which indicate a capture frame.

@JerryChang Hi

after a long time try . I successfully get the 1080p60 stream .

Here are my code repo GitHub - askariz/tc358743_nx_driver if are help to some other guy

and still I have some problem about the driver .

like h2c it is intterupt only work at the startup stage . but nerver happend again


mmc@ubuntu:~$ sudo cat /proc/interrupts
[sudo] password for mmc:
           CPU0       CPU1       CPU2       CPU3       CPU4       CPU5
388:          4          0          0          0          0          0  tegra-gpio 196 Edge      tc358743

and also when I try with 720p It seems no work with a full greeen screen

the delay of h2c is aroud 174ms . is it normal

and also if there can be more detail meterial about the whole pipeline about nvcsi and vi like how the rtos mcu work , how to debug it ? how the log is meanning

best regards .

hello mmcuav_dev,

since there’s some progress. suggest we mark this as solved and initial another new thread to follow-up your 720p issue.
you may also attach the latest kernel failures and also VI tracing logs.
thanks

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.