No picture is shown after running for a period of time

Hi All,
Why did the image suddenly stop appearing? I couldn’t recover it no matter what I did. After restarting for a while, the image stopped appearing again.Please help me take a look, thank you!

device:
orin NX

The problem is port-index=1,configuration for 2LAN。

version:

root@tegra:/home/robot# v4l2-ctl -d /dev/gmsl1 --set-ctrl sensor_mode=3 --set-fmt-video=width=1920,height=1380,pixelformat=YUYV --stream-mmap=3 --stream-skip=3 --stream-count=1 --stream-poll --stream-to=-|ffmpeg -loglevel quiet -f rawvideo -s 1920x1380 -pix_fmt yuyv422 -i - video0_output.jpeg
select timeout
root@tegra:/home/robot# 
root@tegra:/home/robot# more /var/log/syslog | grep rce | grep cpu
Aug 30 12:09:18 tegra kernel: [    6.145543] tegra186-cam-rtcpu bc00000.rtcpu: firmware version cpu=rce cmd=6 sha1=73154acbae92fa621c3d5e1b2a6e10f1075059aa
root@tegra:/home/robot# more /etc/nv_tegra_release 
# R35 (release), REVISION: 4.1, GCID: 33958178, BOARD: t186ref, EABI: aarch64, D
ATE: Tue Aug  1 19:57:35 UTC 2023
root@tegra:/home/robot# dmesg 
[ 1681.814821] debug:[223, ar0233_power_on].
[ 1681.814826] debug:[238, ar0233_power_on, 0x0].
[ 1681.837772] bwmgr API not supported
[ 1681.838211] debug:[486, ar0233_set_mode].
[ 1681.841998] debug:[494, ar0233_set_mode, mode_prop_idx:3].
[ 1681.842000] debug:[139, ar0233_write_table].
[ 1681.868754] debug:[502, ar0233_set_mode].
[ 1681.868766] debug:[511, ar0233_start_streaming].
[ 1681.868767] debug:[139, ar0233_write_table].
[ 1681.894420] tegra-camrtc-capture-vi tegra-capture-vi: corr_err: discarding frame 0, flags: 0, err_data 131072
[ 1681.896742] debug:[520, ar0233_start_streaming].
[ 1681.934422] tegra-camrtc-capture-vi tegra-capture-vi: corr_err: discarding frame 0, flags: 0, err_data 131072
[ 1681.974401] tegra-camrtc-capture-vi tegra-capture-vi: corr_err: discarding frame 0, flags: 0, err_data 131072
[ 1683.989599] debug:[529, ar0233_stop_streaming].
[ 1683.989603] debug:[139, ar0233_write_table].
[ 1683.989604] debug:[537, ar0233_stop_streaming, 0x0].
[ 1684.014742] bwmgr API not supported
[ 1684.016146] debug:[248, ar0233_power_off].
[ 1684.020227] debug:[265, ar0233_power_off, 0x0].

trace_v1.txt (43.3 MB)

dts (1).txt (477.7 KB)

hello wxsrite,

it’s due to you’ve stop_stream called, which may due to you’ve terminate the capture application.

hi, JerryChang,

root@tegra:/home/robot# v4l2-ctl -d /dev/gmsl1 --set-ctrl sensor_mode=3 --set-fmt-video=width=1920,height=1380,pixelformat=YUYV --stream-mmap=3 --stream-skip=3 --stream-count=1 --stream-poll --stream-to=-|ffmpeg -loglevel quiet -f rawvideo -s 1920x1380 -pix_fmt yuyv422 -i - video0_output.jpeg
select timeout   
root@tegra:/home/robot#

---------------> Because it times out here, and then it ends. Normally, there will be no timeout here.

hello wxsrite,

let’s narrow down the issue,
could you please simplify the capture pipeline, for instance, is it repo’ed with only fetching frames?

root@tegra:/sys/kernel/debug/dynamic_debug# cat /sys/kernel/debug/tracing/trace
# tracer: nop
#
# entries-in-buffer/entries-written: 0/0   #P:8
#
#                                _-----=> irqs-off
#                               / _----=> need-resched
#                              | / _---=> hardirq/softirq
#                              || / _--=> preempt-depth
#                              ||| /     delay
#           TASK-PID     CPU#  ||||   TIMESTAMP  FUNCTION
#              | |         |   ||||      |         |
root@tegra:/sys/kernel/debug/dynamic_debug# 
root@tegra:/sys/kernel/debug/dynamic_debug# 
root@tegra:/sys/kernel/debug/dynamic_debug# 
root@tegra:/sys/kernel/debug/dynamic_debug# v4l2-ctl -d /dev/gmsl3 --set-ctrl sensor_mode=3 --set-fmt-video=width=1920,height=1380,pixelformat=YUYV --stream-mmap=3 --stream-skip=3 --stream-count=1 
<<<<
root@tegra:/sys/kernel/debug/dynamic_debug# v4l2-ctl -d /dev/gmsl1 --set-ctrl sensor_mode=3 --set-fmt-video=width=1920,height=1380,pixelformat=YUYV --stream-mmap=3 --stream-skip=3 --stream-count=1 











^C
root@tegra:/sys/kernel/debug/dynamic_debug# 
root@tegra:/sys/kernel/debug/dynamic_debug# 
root@tegra:/sys/kernel/debug/dynamic_debug# cd 
root@tegra:~# exit
root@tegra:/home/robot# exit
robot@tegra:~$ v4l2-ctl -d /dev/gmsl1 --set-ctrl sensor_mode=3 --set-fmt-video=width=1920,height=1380,pixelformat=YUYV --stream-mmap=3 --stream-skip=3 --stream-count=1 
^C
robot@tegra:~$ cat /sys/kernel/debug/tracing/trace > trace.txt
cat: /sys/kernel/debug/tracing/trace: Permission denied
robot@tegra:~$ sudo cat /sys/kernel/debug/tracing/trace > trace.txt
robot@tegra:~$ dmesg > dmesg.txt
dmesg: read kernel buffer failed: Operation not permitted
robot@tegra:~$ sudo dmesg > dmesg.txt
robot@tegra:~$ 

log:
dmesg (2).txt (3.0 KB)

trace (2).txt (95.4 MB)