Problem of getting data from MIPI CSI Jetson TX2

Hi everyone,
Currently, we try to develop FPGA for getting 4K SDI/HDMI input to CSI of TX2. We use two MIPI to send data from FPGA to TX2. However, when we try to get data input:

  • Half of screen shows still image -> green screen -> still image -> green screen … (it happen periodically)
  • Half of screen has no data, always shows green screen

The attached file is my screen when getting data

Are there anyone have any idea about this problem?
All suggestions are appreciated.

Best regards,
Quang

hello Quang_OpenStack,

We use two MIPI to send data from FPGA to TX2
we also had reference driver for that, we had support TC358840 bridge driver to combine two csi bricks as an input.

please check below kernel sources,
thanks

$TOP/kernel_src/kernel/nvidia/drivers/media/i2c/tc358840.c
$TOP/kernel_src/hardware/nvidia/platform/t18x/quill/kernel-dts/quill-modules/tegra186-camera-imx274.dtsi

Dear Jerry Chang,
We are now also using TC358840 bridge driver as reference and we got this problem.
Do you have any idea about how to check this problem?

Thank in advance,
Best regards,
Quang

hello Quang_OpenStack,

  1. could you please check if there’s failure message from the kernel side.
$ dmesg > klog.txt
  1. are you able to enable test-pattern generator of your bridge driver to narrow down the issue.
    thanks

Dear JerryChange

  1. could you please check if there’s failure message from the kernel side
    -> yes, we have a lot of error “tegra-vi4 15700000.vi: PXL_SOF syncpt timeout! err = -11”

  2. are you able to enable test-pattern generator of your bridge driver to narrow down the issue.
    -> Sorry, but I do not understand what do you mean? could you explain more detail?

Thank you!!!
Best regards,
Quang

hello Quang_OpenStack,

2) are you able to enable test-pattern generator of your bridge driver to narrow down the issue.
-> Sorry, but I do not understand what do you mean? could you explain more detail?
since you’re develop a FPGA device to convert HDMI signaling and input to CSI port,
normally, there’s build-in chip to generate color bar to identify the FPGA is actually sending signaling.
are you able to enable the test-pattern-generator on that FPGA device?

tegra-vi4 15700000.vi: PXL_SOF syncpt timeout! err = -11
above failure means there’s VI engine waiting timeout, hence you’ll see green screen.
you need to resolve PXL_SOF syncpt timeout first,

  1. may I know which JetPack release you’re working with
  2. could you please enable the VI tracing log from debugfs, thanks
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

Dear JerryChang,
For enabling the test-pattern-generator, we will check and reply later.
Currently, we are working on Jetpack 3.1 release 28.1.

$ head -n 1 /etc/nv_tegra_release
# R28 (release), REVISION: 1.0, GCID: 9379712, BOARD: t186ref, EABI: aarch64, DATE: Thu Jul 20 07:59:31 UTC 2017

I enable the VI tracing log as your suggestion, following is result after I start and stop getting data input

cat /sys/kernel/debug/tracing/trace
# tracer: nop
#
# entries-in-buffer/entries-written: 176/176   #P:6
#
#                              _-----=> irqs-off
#                             / _----=> need-resched
#                            | / _---=> hardirq/softirq
#                            || / _--=> preempt-depth
#                            ||| /     delay
#           TASK-PID   CPU#  ||||    TIMESTAMP  FUNCTION
#              | |       |   ||||       |         |
     kworker/4:1-113   [004] ...1 30248.255157: rtos_queue_peek_from_isr_failed: tstamp:945560939120 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30248.255161: rtcpu_start: tstamp:945560940195
     kworker/4:1-113   [004] ...1 30248.255162: rtcpu_vinotify_handle_msg: tstamp:945561012128 tag:CSIMUX_STREAM channel:0xff frame:0 vi_tstamp:668206578 data:0x00000001
     kworker/4:1-113   [004] ...1 30248.255163: rtcpu_vinotify_handle_msg: tstamp:945561013718 tag:CSIMUX_STREAM channel:0xff frame:0 vi_tstamp:668208171 data:0x00000100
     kworker/4:1-113   [004] ...1 30248.307152: rtcpu_vinotify_handle_msg: tstamp:945562756272 tag:CSIMUX_FRAME channel:0x00 frame:27 vi_tstamp:669950473 data:0x000000a0
     kworker/4:1-113   [004] ...1 30248.307153: rtcpu_vinotify_handle_msg: tstamp:945562756398 tag:CHANSEL_PXL_SOF channel:0x00 frame:28 vi_tstamp:669950490 data:0x00000001
     kworker/4:1-113   [004] ...1 30248.307154: rtcpu_vinotify_handle_msg: tstamp:945562756542 tag:ATOMP_FS channel:0x00 frame:28 vi_tstamp:669950494 data:0x00000000
     kworker/4:1-113   [004] ...1 30248.307154: rtcpu_vinotify_handle_msg: tstamp:945563756778 tag:CHANSEL_PXL_EOF channel:0x00 frame:28 vi_tstamp:670951224 data:0x086f0002
     kworker/4:1-113   [004] ...1 30248.359157: rtcpu_vinotify_handle_msg: tstamp:945563798922 tag:CSIMUX_FRAME channel:0x00 frame:28 vi_tstamp:670993196 data:0x000000a0
     kworker/4:1-113   [004] ...1 30248.359158: rtcpu_vinotify_handle_msg: tstamp:945563799099 tag:ATOMP_FE channel:0x00 frame:28 vi_tstamp:670993199 data:0x00000000
     kworker/4:1-113   [004] ...1 30248.411156: rtos_queue_peek_from_isr_failed: tstamp:945565939980 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30248.567154: rtos_queue_peek_from_isr_failed: tstamp:945570940485 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30248.723154: rtos_queue_peek_from_isr_failed: tstamp:945575940993 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30248.879156: rtos_queue_peek_from_isr_failed: tstamp:945580941492 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30249.035155: rtos_queue_peek_from_isr_failed: tstamp:945585942005 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30249.195162: rtos_queue_peek_from_isr_failed: tstamp:945590942517 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30249.351159: rtos_queue_peek_from_isr_failed: tstamp:945595943018 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30249.507159: rtos_queue_peek_from_isr_failed: tstamp:945600943526 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30249.663159: rtos_queue_peek_from_isr_failed: tstamp:945605944031 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30249.819159: rtos_queue_peek_from_isr_failed: tstamp:945610944544 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30250.027160: rtos_queue_peek_from_isr_failed: tstamp:945615945048 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30250.183166: rtos_queue_peek_from_isr_failed: tstamp:945620945552 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30250.339166: rtos_queue_peek_from_isr_failed: tstamp:945625946063 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30250.495162: rtos_queue_peek_from_isr_failed: tstamp:945630946563 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30250.651161: rtos_queue_peek_from_isr_failed: tstamp:945635947087 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30250.807163: rtos_queue_peek_from_isr_failed: tstamp:945640947582 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30250.963166: rtos_queue_peek_from_isr_failed: tstamp:945645948084 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30251.119164: rtos_queue_peek_from_isr_failed: tstamp:945650948592 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30251.275169: rtos_queue_peek_from_isr_failed: tstamp:945655949100 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30251.431168: rtos_queue_peek_from_isr_failed: tstamp:945660949605 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30251.587167: rtos_queue_peek_from_isr_failed: tstamp:945665950118 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30251.743168: rtos_queue_peek_from_isr_failed: tstamp:945670950630 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30251.899168: rtos_queue_peek_from_isr_failed: tstamp:945675951127 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30252.107170: rtos_queue_peek_from_isr_failed: tstamp:945680951648 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30252.267176: rtos_queue_peek_from_isr_failed: tstamp:945685952144 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30252.423175: rtos_queue_peek_from_isr_failed: tstamp:945690952645 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30252.579172: rtos_queue_peek_from_isr_failed: tstamp:945695953163 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30252.735174: rtos_queue_peek_from_isr_failed: tstamp:945700953666 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30252.891173: rtos_queue_peek_from_isr_failed: tstamp:945705954167 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30253.047174: rtos_queue_peek_from_isr_failed: tstamp:945710954671 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30253.207186: rtos_queue_peek_from_isr_failed: tstamp:945715955182 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30253.363178: rtos_queue_peek_from_isr_failed: tstamp:945720955696 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30253.519178: rtos_queue_peek_from_isr_failed: tstamp:945725956200 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30253.675175: rtos_queue_peek_from_isr_failed: tstamp:945730956719 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30253.831175: rtos_queue_peek_from_isr_failed: tstamp:945735957213 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30253.987176: rtos_queue_peek_from_isr_failed: tstamp:945740957723 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30254.143176: rtos_queue_peek_from_isr_failed: tstamp:945745958231 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30254.299232: rtos_queue_peek_from_isr_failed: tstamp:945750958735 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30254.507179: rtos_queue_peek_from_isr_failed: tstamp:945755959243 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30254.663178: rtos_queue_peek_from_isr_failed: tstamp:945760959746 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30254.819179: rtos_queue_peek_from_isr_failed: tstamp:945765960256 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30254.975182: rtos_queue_peek_from_isr_failed: tstamp:945770960766 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30255.131180: rtos_queue_peek_from_isr_failed: tstamp:945775961270 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30255.287187: rtos_queue_peek_from_isr_failed: tstamp:945780961776 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30255.443187: rtos_queue_peek_from_isr_failed: tstamp:945785962280 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30255.599182: rtos_queue_peek_from_isr_failed: tstamp:945790962792 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30255.755183: rtos_queue_peek_from_isr_failed: tstamp:945795963296 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30255.911184: rtos_queue_peek_from_isr_failed: tstamp:945800963802 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30256.067185: rtos_queue_peek_from_isr_failed: tstamp:945805964309 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30256.223202: rtos_queue_peek_from_isr_failed: tstamp:945810964815 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30256.379190: rtos_queue_peek_from_isr_failed: tstamp:945815965325 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30256.587194: rtos_queue_peek_from_isr_failed: tstamp:945820965830 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30256.743188: rtos_queue_peek_from_isr_failed: tstamp:945825966336 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30256.899188: rtos_queue_peek_from_isr_failed: tstamp:945830966844 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30257.055189: rtos_queue_peek_from_isr_failed: tstamp:945835967352 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30257.211190: rtos_queue_peek_from_isr_failed: tstamp:945840967858 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30257.367214: rtos_queue_peek_from_isr_failed: tstamp:945845968375 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30257.523192: rtos_queue_peek_from_isr_failed: tstamp:945850968869 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30257.679191: rtos_queue_peek_from_isr_failed: tstamp:945855969378 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30257.835192: rtos_queue_peek_from_isr_failed: tstamp:945860969880 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30257.991193: rtos_queue_peek_from_isr_failed: tstamp:945865970386 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30258.147194: rtos_queue_peek_from_isr_failed: tstamp:945870970892 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30258.303200: rtos_queue_peek_from_isr_failed: tstamp:945875971404 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30258.459199: rtos_queue_peek_from_isr_failed: tstamp:945880971904 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30258.667197: rtos_queue_peek_from_isr_failed: tstamp:945885972421 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30258.823198: rtos_queue_peek_from_isr_failed: tstamp:945890972917 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30258.979200: rtos_queue_peek_from_isr_failed: tstamp:945895973427 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30259.135199: rtos_queue_peek_from_isr_failed: tstamp:945900973936 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30259.295204: rtos_queue_peek_from_isr_failed: tstamp:945905974444 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30259.451208: rtos_queue_peek_from_isr_failed: tstamp:945910974954 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30259.607201: rtos_queue_peek_from_isr_failed: tstamp:945915975458 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30259.763202: rtos_queue_peek_from_isr_failed: tstamp:945920975965 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30259.919204: rtos_queue_peek_from_isr_failed: tstamp:945925976470 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30260.075203: rtos_queue_peek_from_isr_failed: tstamp:945930976981 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30260.231202: rtos_queue_peek_from_isr_failed: tstamp:945935977484 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30260.387210: rtos_queue_peek_from_isr_failed: tstamp:945940978004 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30260.543207: rtos_queue_peek_from_isr_failed: tstamp:945945978499 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30260.699206: rtos_queue_peek_from_isr_failed: tstamp:945950979005 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30260.907207: rtos_queue_peek_from_isr_failed: tstamp:945955979513 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30261.063208: rtos_queue_peek_from_isr_failed: tstamp:945960980018 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30261.219208: rtos_queue_peek_from_isr_failed: tstamp:945965980527 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30261.375217: rtos_queue_peek_from_isr_failed: tstamp:945970981035 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30261.531212: rtos_queue_peek_from_isr_failed: tstamp:945975981542 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30261.687210: rtos_queue_peek_from_isr_failed: tstamp:945980982057 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30261.843211: rtos_queue_peek_from_isr_failed: tstamp:945985982555 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30261.999213: rtos_queue_peek_from_isr_failed: tstamp:945990983064 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30262.155213: rtos_queue_peek_from_isr_failed: tstamp:945995983569 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30262.311227: rtos_queue_peek_from_isr_failed: tstamp:946000984078 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30262.467217: rtos_queue_peek_from_isr_failed: tstamp:946005984591 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30262.623215: rtos_queue_peek_from_isr_failed: tstamp:946010985090 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30262.779214: rtos_queue_peek_from_isr_failed: tstamp:946015985595 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30262.987217: rtos_queue_peek_from_isr_failed: tstamp:946020986103 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30263.143215: rtos_queue_peek_from_isr_failed: tstamp:946025986605 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30263.299229: rtos_queue_peek_from_isr_failed: tstamp:946030987114 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30263.455228: rtos_queue_peek_from_isr_failed: tstamp:946035987623 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30263.611219: rtos_queue_peek_from_isr_failed: tstamp:946040988132 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30263.767220: rtos_queue_peek_from_isr_failed: tstamp:946045988638 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30263.923221: rtos_queue_peek_from_isr_failed: tstamp:946050989143 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30264.079221: rtos_queue_peek_from_isr_failed: tstamp:946055989648 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30264.235220: rtos_queue_peek_from_isr_failed: tstamp:946060990178 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30264.391233: rtos_queue_peek_from_isr_failed: tstamp:946065990664 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30264.547225: rtos_queue_peek_from_isr_failed: tstamp:946070991173 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30264.703222: rtos_queue_peek_from_isr_failed: tstamp:946075991677 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30264.859223: rtos_queue_peek_from_isr_failed: tstamp:946080992186 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30265.067225: rtos_queue_peek_from_isr_failed: tstamp:946085992692 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30265.223225: rtos_queue_peek_from_isr_failed: tstamp:946090993199 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30265.379232: rtos_queue_peek_from_isr_failed: tstamp:946095993707 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30265.535229: rtos_queue_peek_from_isr_failed: tstamp:946100994212 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30265.691227: rtos_queue_peek_from_isr_failed: tstamp:946105994729 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30265.847228: rtos_queue_peek_from_isr_failed: tstamp:946110995238 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30266.003225: rtos_queue_peek_from_isr_failed: tstamp:946115995730 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30266.159229: rtos_queue_peek_from_isr_failed: tstamp:946120996233 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30266.315229: rtos_queue_peek_from_isr_failed: tstamp:946125996740 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30266.471234: rtos_queue_peek_from_isr_failed: tstamp:946130997262 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30266.627232: rtos_queue_peek_from_isr_failed: tstamp:946135997760 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30266.783233: rtos_queue_peek_from_isr_failed: tstamp:946140998259 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30266.939276: rtos_queue_peek_from_isr_failed: tstamp:946145998769 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30267.147234: rtos_queue_peek_from_isr_failed: tstamp:946150999279 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30267.303234: rtos_queue_peek_from_isr_failed: tstamp:946155999779 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30267.459240: rtos_queue_peek_from_isr_failed: tstamp:946161000295 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30267.615238: rtos_queue_peek_from_isr_failed: tstamp:946166000801 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30267.771238: rtos_queue_peek_from_isr_failed: tstamp:946171001300 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30267.927237: rtos_queue_peek_from_isr_failed: tstamp:946176001809 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30268.083238: rtos_queue_peek_from_isr_failed: tstamp:946181002317 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30268.239239: rtos_queue_peek_from_isr_failed: tstamp:946186002821 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30268.395249: rtos_queue_peek_from_isr_failed: tstamp:946191003338 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30268.551241: rtos_queue_peek_from_isr_failed: tstamp:946196003869 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30268.707241: rtos_queue_peek_from_isr_failed: tstamp:946201004342 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30268.863241: rtos_queue_peek_from_isr_failed: tstamp:946206004847 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30269.019244: rtos_queue_peek_from_isr_failed: tstamp:946211005366 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30269.227243: rtos_queue_peek_from_isr_failed: tstamp:946216005866 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30269.391252: rtos_queue_peek_from_isr_failed: tstamp:946221006381 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30269.391256: rtos_queue_send_from_isr_failed: tstamp:946221572776 queue:0x0b4a2f38
     kworker/4:1-113   [004] ...1 30269.391257: rtos_queue_peek_from_isr_failed: tstamp:946221574600 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30269.491248: rtos_queue_peek_from_isr_failed: tstamp:946225087825 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30269.491251: rtcpu_start: tstamp:946225088578
     kworker/4:1-113   [004] ...1 30269.491252: rtcpu_vinotify_handle_msg: tstamp:946225158569 tag:CSIMUX_STREAM channel:0xff frame:0 vi_tstamp:1332353019 data:0x00000100
     kworker/4:1-113   [004] ...1 30269.543258: rtcpu_vinotify_handle_msg: tstamp:946225927669 tag:CSIMUX_FRAME channel:0x00 frame:29 vi_tstamp:1333122112 data:0x000000a0
     kworker/4:1-113   [004] ...1 30269.543261: rtcpu_vinotify_handle_msg: tstamp:946226970638 tag:CSIMUX_FRAME channel:0x00 frame:4 vi_tstamp:1334164835 data:0x000000a0
     kworker/4:1-113   [004] ...1 30269.543261: rtcpu_vinotify_handle_msg: tstamp:946226970767 tag:CHANSEL_PXL_SOF channel:0x00 frame:5 vi_tstamp:1334164852 data:0x00000001
     kworker/4:1-113   [004] ...1 30269.543262: rtcpu_vinotify_handle_msg: tstamp:946226970918 tag:ATOMP_FS channel:0x00 frame:5 vi_tstamp:1334164857 data:0x00000000
     kworker/4:1-113   [004] ...1 30269.595254: rtcpu_vinotify_handle_msg: tstamp:946227971136 tag:CHANSEL_PXL_EOF channel:0x00 frame:5 vi_tstamp:1335165587 data:0x086f0002
     kworker/4:1-113   [004] ...1 30269.595256: rtcpu_vinotify_handle_msg: tstamp:946228013269 tag:CSIMUX_FRAME channel:0x00 frame:5 vi_tstamp:1335207558 data:0x000000a0
     kworker/4:1-113   [004] ...1 30269.595257: rtcpu_vinotify_handle_msg: tstamp:946228013449 tag:ATOMP_FE channel:0x00 frame:5 vi_tstamp:1335207562 data:0x00000000
     kworker/4:1-113   [004] ...1 30269.647248: rtos_queue_peek_from_isr_failed: tstamp:946230088696 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30269.803247: rtos_queue_peek_from_isr_failed: tstamp:946235089205 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30269.959246: rtos_queue_peek_from_isr_failed: tstamp:946240089708 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30270.115248: rtos_queue_peek_from_isr_failed: tstamp:946245090217 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30270.271248: rtos_queue_peek_from_isr_failed: tstamp:946250090723 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30270.479252: rtos_queue_peek_from_isr_failed: tstamp:946255091244 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30270.635251: rtos_queue_peek_from_isr_failed: tstamp:946260091747 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30270.791252: rtos_queue_peek_from_isr_failed: tstamp:946265092244 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30270.947255: rtos_queue_peek_from_isr_failed: tstamp:946270092748 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30271.103251: rtos_queue_peek_from_isr_failed: tstamp:946275093264 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30271.259252: rtos_queue_peek_from_isr_failed: tstamp:946280093770 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30271.415265: rtos_queue_peek_from_isr_failed: tstamp:946285094270 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30271.571259: rtos_queue_peek_from_isr_failed: tstamp:946290094779 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30271.727255: rtos_queue_peek_from_isr_failed: tstamp:946295095294 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30271.883255: rtos_queue_peek_from_isr_failed: tstamp:946300095790 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30272.039258: rtos_queue_peek_from_isr_failed: tstamp:946305096296 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30272.195256: rtos_queue_peek_from_isr_failed: tstamp:946310096805 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30272.351258: rtos_queue_peek_from_isr_failed: tstamp:946315097312 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30272.559263: rtos_queue_peek_from_isr_failed: tstamp:946320097835 queue:0x0b4a3c58
     kworker/4:1-113   [004] ...1 30272.559268: rtos_queue_send_from_isr_failed: tstamp:946321074056 queue:0x0b4a2238
     kworker/4:1-113   [004] ...1 30272.559268: rtos_queue_send_from_isr_failed: tstamp:946321074147 queue:0x0b4a2f38
     kworker/4:1-113   [004] ...1 30272.559269: rtos_queue_peek_from_isr_failed: tstamp:946321076155 queue:0x0b4a3c58

Best regards,
Quang

hello Quang_OpenStack,

may I know are you mind to upgrade to latest release.
there are some known issues, please refer to below for the patches.

  1. Topic 1038067: fix FE syncpt wait
  2. Topic 1020202: fix missing timestamp for vi4

Dear JerryChang,
I update SDK to Jetpack 3.3 release 28.2.1 but the same problem happen.

I will check the topics that you recommend. If you have other idea, please help me.

Thank
Best regards,
Quang

Dear JerryChang,
In VI tracing log, could you please tell me more about:
CSIMUX_STREAM channel:0xff and CSIMUX_FRAME channel:0x00

What is the meaning of channel 0xff and channel 0xff?
Currently, we use two MIPI to send data from FPGA to CSI of TX2 and we set both Virtual Channel ID (VCID) of MIPI is 0x00. Is is correct?

Looking for your reply.
P.S. We connect FPGA MIPI0 to CSI_A & CSI_B; MIPI1 to CSI_C & CSI_D
Thank.
Best regards,
Quang

hello Quang_OpenStack,

you don’t need to configure Virtual Channel ID since it’s not design for your use-case.
please refer to TC358840 device tree to have implementation.
you might also check below kernel source, which handle dual csi bricks as an input.
thanks

<i>$TOP/kernel_src/kernel/nvidia/drivers/media/platform/tegra/camera/vi/channel.c</i>

static void update_gang_mode(struct tegra_channel *chan)
{...}

Dear JerryChang,
Is there anyway to check CSI input/output status? Please give me some suggestion!!!

Thank in advance.
Best regards,
Quang

Dear JerryChang,
I put some debug message into update_gang_mode() function.
When I check 2160p@30fps input, it is show

chan->format.width: 3840
chan->format.height: 2160
chan->valid_ports: 2

What is the meaning of “chan->valid_ports” and how can I check information about framerate?

Thank.
Best regards,
Quang

hello Quang_OpenStack,

since you need to combine two csi bricks as an input.
please refer to below kernel driver which will parse the settings from device tree.
thanks

<i>$TOP/kernel_src/kernel/nvidia/drivers/media/platform/tegra/camera/vi/graph.c</i>

int tegra_vi_get_port_info(struct tegra_channel *chan, struct device_node *node, unsigned int index)
{...}

Hi JerryChang,
I added some debug message into tegra_vi_get_port_info() function, I got some information like

csi-port: 0
bus-width: 8

So, I guest CSI port is ready for getting video input.
Do you think that there are something wrong in data structure of video stream that generated from FPGA?
Because when tracing VI, operation sequence seems not correctly, many error come out.

Thank.
Best regards,
Quang

hello Quang_OpenStack,

Because when tracing VI, operation sequence seems not correctly, many error come out.

  1. please review operation sequence.
  2. are you able to enable TPG buffer to narrow down the issue?

Dear JerryChang,

1) please review operation sequence.
Is following sequence is correct?

  1. SOF : Start of Frame
  2. FS : Frame Start
  3. LOAD : Load Frame
  4. EOF : End of Frame
  5. FE

2) are you able to enable TPG buffer to narrow down the issue?
I enable TPG buffer as

sudo insmod /lib/modules/4.4.38-tegra/kernel/drivers/media/platform/tegra/tpg/nvhost-vi-tpg.ko

Then I check /dev/video*

nvidia@tegra-ubuntu:~$ ls /dev/video*
/dev/video0  /dev/video1  /dev/video2  /dev/video3  /dev/video4  /dev/video5  /dev/video6

What should I do next?

Dear JerryChang,

1) please review operation sequence.
Is following sequence is correct?

  1. SOF : Start of Frame
  2. FS : Frame Start
  3. LOAD : Load Frame
  4. EOF : End of Frame
  5. FE

2) are you able to enable TPG buffer to narrow down the issue?
I enable TPG buffer as

sudo insmod /lib/modules/4.4.38-tegra/kernel/drivers/media/platform/tegra/tpg/nvhost-vi-tpg.ko

Then I check /dev/video*

nvidia@tegra-ubuntu:~$ ls /dev/video*
/dev/video0  /dev/video1  /dev/video2  /dev/video3  /dev/video4  /dev/video5  /dev/video6

What should I do next?

hello Quang_OpenStack,

your operation sequence looks correct to me.
however, below command only enable the TPG buffer from tegra side.
$ sudo insmod /lib/modules/4.4.38-tegra/kernel/drivers/media/platform/tegra/tpg/nvhost-vi-tpg.ko

please contact your vendor,
you need to enable test-pattern generator of your bridge driver to narrow down the issue.
thanks

Hi JerryChang,
When I check VI tracing log, it seem that there is no CHANSEL_LOAD_FRAMED. Do you have any suggestion for this error?

kworker/3:1-103   [003] ...1   203.801936: rtcpu_vinotify_handle_msg: tstamp:6672169065 tag:CSIMUX_STREAM channel:0xff frame:0 vi_tstamp:2377201344 data:0x00000001
     kworker/3:1-103   [003] ...1   203.801936: rtcpu_vinotify_handle_msg: tstamp:6672169688 tag:CSIMUX_STREAM channel:0xff frame:0 vi_tstamp:2377202009 data:0x00000100
     kworker/3:1-103   [003] ...1   203.853929: rtcpu_vinotify_handle_msg: tstamp:6673268317 tag:CSIMUX_FRAME channel:0x00 frame:2 vi_tstamp:2378300604 data:0x000000a0
     kworker/3:1-103   [003] ...1   203.909924: rtcpu_vinotify_handle_msg: tstamp:6674311291 tag:CSIMUX_FRAME channel:0x00 frame:3 vi_tstamp:2379343326 data:0x000000a0
     kworker/3:1-103   [003] ...1   203.909925: rtcpu_vinotify_handle_msg: tstamp:6674311423 tag:CHANSEL_PXL_SOF channel:0x00 frame:4 vi_tstamp:2379343343 data:0x00000001
     kworker/3:1-103   [003] ...1   203.909926: rtcpu_vinotify_handle_msg: tstamp:6674311571 tag:ATOMP_FS channel:0x00 frame:4 vi_tstamp:2379343348 data:0x00000000
     kworker/3:1-103   [003] ...1   203.909927: rtcpu_vinotify_handle_msg: tstamp:6675311785 tag:CHANSEL_PXL_EOF channel:0x00 frame:4 vi_tstamp:2380344077 data:0x086f0002
     kworker/3:1-103   [003] ...1   203.909928: rtcpu_vinotify_handle_msg: tstamp:6675353921 tag:CSIMUX_FRAME channel:0x00 frame:4 vi_tstamp:2380386048 data:0x000000a0
     kworker/3:1-103   [003] ...1   203.909928: rtcpu_vinotify_handle_msg: tstamp:6675354102 tag:ATOMP_FE channel:0x00 frame:4 vi_tstamp:2380386052 data:0x00000000
     kworker/3:1-103   [003] ...1   203.961928: rtos_queue_peek_from_isr_failed: tstamp:6677094066 queue:0x0b4a3c58
     kworker/3:1-103   [003] ...1   204.117927: rtos_queue_peek_from_isr_failed: tstamp:6682094562 queue:0x0b4a3c58
     kworker/3:1-103   [003] ...1   204.273929: rtos_queue_peek_from_isr_failed: tstamp:6687095080 queue:0x0b4a3c58
     kworker/3:1-103   [003] ...1   204.429928: rtos_queue_peek_from_isr_failed: tstamp:6692095577 queue:0x0b4a3c58
     kworker/3:1-103   [003] ...1   204.637927: rtos_queue_peek_from_isr_failed: tstamp:6697096087 queue:0x0b4a3c58

Thank,
Best regard.