Hi,
We are porting an HDMI-to-MIPI-CSI-2 function on Jetson Xavier NX platform.
The L4T version is R32.4.3.
We had successfully seen the preview of 720P@60FPS by referring to this topic.
We used the v4l2-ctl command to get some frames.
v4l2-ctl --device /dev/video0 --stream-mmap --set-fmt-video=width=1280,height=720,pixelformat=UYVY
And we used the following gstreamer command to get the preview.
gst-launch-1.0 v4l2src device=/dev/video0 ! 'video/x-raw,format=UYVY,width=1280,height=720,framerate=60/1' ! \
nvvidconv ! 'video/x-raw(memory:NVMM),format=I420,width=1920,height=1080' ! nvoverlaysink
The 720P preview is OK when the bus-width is <2> in the device tree.
nvcsi@15a00000 {
num-channels = <1>;
#address-cells = <1>;
#size-cells = <0>;
csi_chan0: channel@0 {
reg = <0>;
ports {
#address-cells = <1>;
#size-cells = <0>;
port@0 {
reg = <0>;
tc358743_csi_in0: endpoint@0 {
port-index = <0>;
bus-width = <2>;
remote-endpoint = <&tc358743_out0>;
};
};
port@1 {
reg = <1>;
tc358743_csi_out0: endpoint@1 {
remote-endpoint = <&tc358743_vi_in0>;
};
};
};
};
};
We try to move on by setting the bus-width from <2> to <4>.
However, after changing the bus-width to <4>, we cannot get frames by using the v4l2-ctl command.
tc358743_csi_in0: endpoint@0 {
port-index = <0>;
- bus-width = <2>;
+ bus-width = <4>;
remote-endpoint = <&tc358743_out0>;
};
In the dmesg, we saw the following reset log every 2.5 seconds when the v4l2-ctl command is running.
[ 92.513060] tegra194-vi5 15c10000.vi: no reply from camera processor
[ 92.513218] tegra194-vi5 15c10000.vi: uncorr_err: request timed out after 2500 ms
[ 92.513404] tegra194-vi5 15c10000.vi: err_rec: attempting to reset the capture channel
[ 92.515911] tegra194-vi5 15c10000.vi: err_rec: successfully reset the capture channel
We use the following scripts to trace the VI related log.
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
In the trace log, we see these two lines which are NOT showing up when the bus-width is set as <2>.
kworker/1:2-1737 [001] .... 87.441401: rtcpu_nvcsi_intr: tstamp:3062917566 class:GLOBAL type:PHY_INTR0 phy:0 cil:0 st:0 vc:0 status:0x00000110
kworker/1:2-1737 [001] .... 87.441402: rtcpu_nvcsi_intr: tstamp:3062917566 class:CORRECTABLE_ERR type:PHY_INTR phy:0 cil:0 st:0 vc:0 status:0x00000110
The full trace logs are uploaded.
nvcsi_bw2.log (61.8 KB)
nvcsi_bw4.log (33.2 KB)
We are now not sure where we should keep debugging/digging.
Please advise how the 720P@60FPS can work with 4-lane NVCSI.