Get sensor embedded data in Xavier

Hi ,
I use Jetson Xavier, JetPack 4.4-R32.4.3.
I want to get sensor embedded data in Xavier. The camera I use has an ISP, outputs YUV, and embeds a row of sensor metadata in Mipi data.

Can i use …/vi5_ fops.c get metadata in mipi?
…/vi5_ fops.c support obtaining sensor embedded data in YUV camera?

I have referred to the link below

Yes, you need to modify the vi5_fops.c to get the data from the embedded data buffer.

Thank you for your reply
So YUV camera can also get metadata in mipi.
Is there a corresponding patch on Xavier for reference?
I added the following code in vi5_capture_dequeue() in vi5_fops.c .

        void* frame_buffer = vb2_plane_vaddr(&(vb->vb2_buf), 0);
        if(frame_buffer != NULL) {
                if(chan->vi->emb_buf_addr != NULL){
                        //emb_buf_size = 4096
                        memcpy(frame_buffer,chan->vi->emb_buf_addr,chan->vi->emb_buf_size);
                }
        }

But failed. Is it OK to add here?

I would suggest just print the buffer in kernel driver to check if able to get validate data first.

Thank you for your reply
The following is the log when I use v4l-ctl to obtain images.
I see “channel_embedded_sof”, but I don’t see channel_ EMBED_ EOF and atomp_ EMB_ DATA_ DONE in log.
What may cause this problem?

   kworker/0:1-11787 [000] ....  5776.059238: rtcpu_vinotify_event: tstamp:180654763395 tag:FE channel:0x00 frame:0 vi_tstamp:180654586019 data:0x00000020
     kworker/0:1-11787 [000] ....  5776.059239: rtcpu_vinotify_event: tstamp:180654763657 tag:RESERVED_18 channel:0x23 frame:0 vi_tstamp:180309413248 data:0x10000000
     kworker/0:1-11787 [000] ....  5776.059269: rtcpu_vinotify_event: tstamp:180654763872 tag:RESERVED_18 channel:0x23 frame:0 vi_tstamp:180309417056 data:0x31000001
     kworker/0:1-11787 [000] ....  5776.059270: rtcpu_vinotify_event: tstamp:180654764126 tag:RESERVED_19 channel:0x23 frame:0 vi_tstamp:180309418080 data:0x07020001
     kworker/0:1-11787 [000] ....  5776.059271: rtcpu_vinotify_event: tstamp:180654764334 tag:RESERVED_18 channel:0x23 frame:0 vi_tstamp:180309469600 data:0x10000000
     kworker/0:1-11787 [000] ....  5776.059272: rtcpu_vinotify_event: tstamp:180654764583 tag:RESERVED_18 channel:0x23 frame:0 vi_tstamp:180309473440 data:0x31000002
     kworker/0:1-11787 [000] ....  5776.059273: rtos_queue_send_from_isr_failed: tstamp:180654870262 queue:0x0bcb41f8
     kworker/0:1-11787 [000] ....  5776.059275: rtos_queue_send_from_isr_failed: tstamp:180654870413 queue:0x0bcb8a60
     kworker/0:1-11787 [000] ....  5776.059276: rtos_queue_send_from_isr_failed: tstamp:180654870568 queue:0x0bcba5e0
     kworker/0:1-11787 [000] ....  5776.059277: rtos_queue_send_from_isr_failed: tstamp:180654870715 queue:0x0bcbb3a0
     kworker/0:1-11787 [000] ....  5776.059278: rtos_queue_send_from_isr_failed: tstamp:180654870862 queue:0x0bcbc160
     kworker/0:1-11787 [000] ....  5776.059280: rtcpu_vinotify_error: tstamp:180654879022 tag:CSIMUX_STREAM channel:0x00 frame:0 vi_tstamp:180654876173 data:0x00000001
 vi-output, imx1-11960 [006] ....  5776.071437: tegra_channel_capture_frame: sof:0.0
 vi-output, imx1-11960 [006] ....  5776.071443: tegra_channel_capture_frame: eof:5780.976012128
 vi-output, imx1-11960 [006] ....  5776.071782: tegra_channel_capture_frame: sof:0.0
 vi-output, imx1-11960 [006] ....  5776.071786: tegra_channel_capture_frame: eof:5780.976468352
     kworker/0:1-11787 [000] ....  5776.115086: rtcpu_vinotify_event: tstamp:180655305380 tag:CSIMUX_STREAM channel:0x00 frame:0 vi_tstamp:180654876173 data:0x00000001
     kworker/0:1-11787 [000] ....  5776.115091: rtcpu_vinotify_error: tstamp:180655506643 tag:CSIMUX_FRAME channel:0x00 frame:0 vi_tstamp:180655500379 data:0x000000a0
     kworker/0:1-11787 [000] ....  5776.115093: rtcpu_vinotify_event: tstamp:180655507084 tag:FS channel:0x00 frame:0 vi_tstamp:180655500357 data:0x00000010
     kworker/0:1-11787 [000] ....  5776.115094: rtcpu_vinotify_event: tstamp:180655507229 tag:ATOMP_FS channel:0x00 frame:0 vi_tstamp:180655500361 data:0x00000000
     kworker/0:1-11787 [000] ....  5776.115095: rtcpu_vinotify_event: tstamp:180655507387 tag:CSIMUX_FRAME channel:0x00 frame:0 vi_tstamp:180655500379 data:0x000000a0
     kworker/0:1-11787 [000] ....  5776.115096: rtcpu_vinotify_event: tstamp:180655507527 tag:CHANSEL_SHORT_FRAME channel:0x01 frame:0 vi_tstamp:180655500379 data:0x01000000
     kworker/0:1-11787 [000] ....  5776.115097: rtcpu_vinotify_event: tstamp:180655507691 tag:RESERVED_19 channel:0x23 frame:0 vi_tstamp:180338693632 data:0x01020001
     kworker/0:1-11787 [000] ....  5776.115098: rtcpu_vinotify_event: tstamp:180655507826 tag:FS channel:0x00 frame:0 vi_tstamp:180655500379 data:0x00000010
     kworker/0:1-11787 [000] ....  5776.115100: rtcpu_vinotify_error: tstamp:180655517600 tag:CSIMUX_STREAM channel:0x00 frame:0 vi_tstamp:180655514636 data:0x00000002
     kworker/0:1-11787 [000] ....  5776.115142: rtos_queue_send_from_isr_failed: tstamp:180655519987 queue:0x0bcb41f8
     kworker/0:1-11787 [000] ....  5776.115144: rtos_queue_send_from_isr_failed: tstamp:180655520144 queue:0x0bcb8a60
     kworker/0:1-11787 [000] ....  5776.115145: rtos_queue_send_from_isr_failed: tstamp:180655520297 queue:0x0bcba5e0
     kworker/0:1-11787 [000] ....  5776.115147: rtos_queue_send_from_isr_failed: tstamp:180655520446 queue:0x0bcbb3a0
     kworker/0:1-11787 [000] ....  5776.115148: rtos_queue_send_from_isr_failed: tstamp:180655520595 queue:0x0bcbc160
     kworker/0:1-11787 [000] ....  5776.115149: rtos_queue_send_from_isr_failed: tstamp:180655529724 queue:0x0bcb41f8
     kworker/0:1-11787 [000] ....  5776.115150: rtos_queue_send_from_isr_failed: tstamp:180655529881 queue:0x0bcb8a60
     kworker/0:1-11787 [000] ....  5776.115151: rtos_queue_send_from_isr_failed: tstamp:180655530031 queue:0x0bcba5e0
     kworker/0:1-11787 [000] ....  5776.115152: rtos_queue_send_from_isr_failed: tstamp:180655530178 queue:0x0bcbb3a0
     kworker/0:1-11787 [000] ....  5776.115153: rtos_queue_send_from_isr_failed: tstamp:180655530323 queue:0x0bcbc160
     kworker/0:1-11787 [000] ....  5776.115154: rtcpu_vinotify_event: tstamp:180656010713 tag:ATOMP_FE channel:0x00 frame:0 vi_tstamp:180655500381 data:0x00000000
     kworker/0:1-11787 [000] ....  5776.115156: rtcpu_vinotify_event: tstamp:180656010860 tag:ATOMP_FS channel:0x00 frame:0 vi_tstamp:180655500382 data:0x00000000
     kworker/0:1-11787 [000] ....  5776.115157: rtcpu_vinotify_event: tstamp:180656011022 tag:CHANSEL_EMBED_SOF channel:0x23 frame:0 vi_tstamp:180655514616 data:0x00000004
     kworker/0:1-11787 [000] ....  5776.115183: rtcpu_vinotify_event: tstamp:180656011167 tag:CSIMUX_STREAM channel:0x00 frame:0 vi_tstamp:180655514636 data:0x00000002
     kworker/0:1-11787 [000] ....  5776.115184: rtcpu_vinotify_event: tstamp:180656011332 tag:CHANSEL_LOAD_FRAMED channel:0x01 frame:0 vi_tstamp:180655518419 data:0x38000252
     kworker/0:1-11787 [000] ....  5776.115185: rtcpu_vinotify_event: tstamp:180656011469 tag:CHANSEL_FAULT_FE channel:0x01 frame:0 vi_tstamp:180655518419 data:0x00000000
     kworker/0:1-11787 [000] ....  5776.115186: rtcpu_vinotify_event: tstamp:180656011626 tag:ATOMP_FE channel:0x00 frame:0 vi_tstamp:180655518421 data:0x00000000
     kworker/0:1-11787 [000] ....  5776.115187: rtcpu_vinotify_error: tstamp:180656545083 tag:CSIMUX_FRAME channel:0x00 frame:0 vi_tstamp:180656541973 data:0x000000a0
     kworker/0:1-11787 [000] ....  5776.115188: rtcpu_vinotify_error: tstamp:180656545748 tag:CSIMUX_FRAME channel:0x00 frame:0 vi_tstamp:180656541993 data:0x000000a0
     kworker/0:1-11787 [000] ....  5776.115189: rtcpu_vinotify_event: tstamp:180656553685 tag:CSIMUX_FRAME channel:0x00 frame:0 vi_tstamp:180656541973 data:0x000000a0
     kworker/0:1-11787 [000] ....  5776.115190: rtcpu_vinotify_event: tstamp:180656553845 tag:FS channel:0x00 frame:0 vi_tstamp:180656541973 data:0x00000010
     kworker/0:1-11787 [000] ....  5776.115191: rtcpu_vinotify_event: tstamp:180656553982 tag:CSIMUX_FRAME channel:0x00 frame:0 vi_tstamp:180656541993 data:0x000000a0
     kworker/0:1-11787 [000] ....  5776.115193: rtcpu_vinotify_event: tstamp:180656554139 tag:FS channel:0x00 frame:0 vi_tstamp:180656541994 data:0x00000010
     kworker/0:1-11787 [000] ....  5776.115194: rtcpu_vinotify_error: tstamp:180656559303 tag:CHANSEL_NOMATCH channel:0x01 frame:0 vi_tstamp:180656556230 data:0x00000249
     kworker/0:1-11787 [000] ....  5776.115195: rtcpu_vinotify_error: tstamp:180656559970 tag:CSIMUX_STREAM channel:0x00 frame:0 vi_tstamp:180656556251 data:0x00000002
     kworker/0:1-11787 [000] ....  5776.115197: rtos_queue_peek_from_isr_failed: tstamp:180656727184 queue:0x0bcbcf78

Maybe the embedded_metadata_height incorrect.
Looks like the sensor output size doesn’t as expect also. tag:CHANSEL_SHORT_FRAME

Thank you for your reply
I can see CHANSEL_EMBED_SOF/CHANSEL_EMBED_EOF/ATOMP_EMB_DATA_DONE in log.
But there are still problems with camera data.
CSIMUX_FRAME = 0x000000a0
CHANSEL_NOMATCH = 0x00000249 (camera data type is not yuyv)
CHANSEL_SHORT_FRAME = 0x01000000
IN my device tree:

                                dynamic_pixel_bit_depth = "16";
                                csi_pixel_bit_depth = "16";
                                mode_type = "yuv";
                                pixel_phase = "yuyv";

                                active_w = "1920";
                                active_h = "1080";
                                .......
                                embedded_metadata_height = "1";
kworker/2:2-10569 [002] ....  3199.460814: rtcpu_string: tstamp:100136754048 id:0x04010000 str:"vi5_hwinit: firmware CL2018101701 protocol versi"
     kworker/2:2-10569 [002] ....  3199.460816: rtcpu_string: tstamp:100136754239 id:0x04010000 str:"on 2.2
"
     kworker/2:2-10569 [002] ....  3199.460823: rtos_queue_send_from_isr_failed: tstamp:100137420940 queue:0x0bcb41f8
     kworker/2:2-10569 [002] ....  3199.460824: rtos_queue_send_from_isr_failed: tstamp:100137421201 queue:0x0bcb8a60
     kworker/2:2-10569 [002] ....  3199.460825: rtos_queue_send_from_isr_failed: tstamp:100137421429 queue:0x0bcba5e0
     kworker/2:2-10569 [002] ....  3199.460826: rtos_queue_send_from_isr_failed: tstamp:100137421648 queue:0x0bcbb3a0
     kworker/2:2-10569 [002] ....  3199.460826: rtos_queue_send_from_isr_failed: tstamp:100137421867 queue:0x0bcbc160
     kworker/2:2-10569 [002] ....  3199.460827: rtcpu_string: tstamp:100137423048 id:0x04010000 str:"VI GOS[#0] set to VM GOS[4] base 0xc2104000
"
     kworker/2:2-10569 [002] ....  3199.460834: rtcpu_vinotify_event: tstamp:100137449029 tag:RESERVED_18 channel:0x23 frame:0 vi_tstamp:99136220640 data:0x10000000
     kworker/2:2-10569 [002] ....  3199.460835: rtcpu_vinotify_event: tstamp:100137449249 tag:RESERVED_18 channel:0x23 frame:0 vi_tstamp:99136224448 data:0x31000001
     kworker/2:2-10569 [002] ....  3199.460836: rtcpu_vinotify_event: tstamp:100137449525 tag:RESERVED_19 channel:0x23 frame:0 vi_tstamp:99136225440 data:0x07020001
     kworker/2:2-10569 [002] ....  3199.460837: rtcpu_vinotify_event: tstamp:100137449731 tag:RESERVED_18 channel:0x23 frame:0 vi_tstamp:99136282912 data:0x10000000
     kworker/2:2-10569 [002] ....  3199.460837: rtcpu_vinotify_event: tstamp:100137449979 tag:RESERVED_18 channel:0x23 frame:0 vi_tstamp:99136286784 data:0x31000002
     kworker/2:2-10569 [002] ....  3199.460838: rtos_queue_send_from_isr_failed: tstamp:100137702155 queue:0x0bcb41f8
     kworker/2:2-10569 [002] ....  3199.460840: rtos_queue_send_from_isr_failed: tstamp:100137702305 queue:0x0bcb8a60
     kworker/2:2-10569 [002] ....  3199.460840: rtos_queue_send_from_isr_failed: tstamp:100137702457 queue:0x0bcba5e0
     kworker/2:2-10569 [002] ....  3199.460841: rtos_queue_send_from_isr_failed: tstamp:100137702602 queue:0x0bcbb3a0
     kworker/2:2-10569 [002] ....  3199.460842: rtos_queue_send_from_isr_failed: tstamp:100137702747 queue:0x0bcbc160
     kworker/2:2-10569 [002] ....  3199.460843: rtcpu_nvcsi_intr: tstamp:100137705324 class:GLOBAL type:PHY_INTR0 phy:0 cil:0 st:0 vc:0 status:0x00000089
     kworker/2:2-10569 [002] ....  3199.460845: rtcpu_nvcsi_intr: tstamp:100137705324 class:GLOBAL type:PHY_INTR0 phy:0 cil:1 st:0 vc:0 status:0x00000088
     kworker/2:2-10569 [002] ....  3199.460847: rtcpu_vinotify_error: tstamp:100137712501 tag:CSIMUX_STREAM channel:0x00 frame:0 vi_tstamp:100137709653 data:0x00000001
 vi-output, imx1-11424 [004] ....  3199.477829: tegra_channel_capture_frame: sof:0.0
 vi-output, imx1-11424 [004] ....  3199.477835: tegra_channel_capture_frame: eof:3204.428787680
 vi-output, imx1-11424 [004] ....  3199.511026: tegra_channel_capture_frame: sof:0.0
 vi-output, imx1-11424 [004] ....  3199.511031: tegra_channel_capture_frame: eof:3204.462119712
     kworker/2:2-10569 [002] ....  3199.516680: rtcpu_vinotify_event: tstamp:100137991829 tag:CSIMUX_STREAM channel:0x00 frame:0 vi_tstamp:100137709653 data:0x00000001
     kworker/2:2-10569 [002] ....  3199.516687: rtcpu_vinotify_error: tstamp:100138405626 tag:CSIMUX_FRAME channel:0x00 frame:0 vi_tstamp:100138399615 data:0x000000a0
     kworker/2:2-10569 [002] ....  3199.516689: rtcpu_vinotify_event: tstamp:100138416951 tag:FS channel:0x00 frame:0 vi_tstamp:100138399568 data:0x00000010
     kworker/2:2-10569 [002] ....  3199.516690: rtcpu_vinotify_event: tstamp:100138417095 tag:ATOMP_FS channel:0x00 frame:0 vi_tstamp:100138399571 data:0x00000000
     kworker/2:2-10569 [002] ....  3199.516690: rtcpu_vinotify_event: tstamp:100138417253 tag:CSIMUX_FRAME channel:0x00 frame:0 vi_tstamp:100138399615 data:0x000000a0
     kworker/2:2-10569 [002] ....  3199.516692: rtcpu_vinotify_event: tstamp:100138417396 tag:CHANSEL_SHORT_FRAME channel:0x01 frame:0 vi_tstamp:100138399615 data:0x01000000
     kworker/2:2-10569 [002] ....  3199.516692: rtcpu_vinotify_event: tstamp:100138417558 tag:RESERVED_19 channel:0x23 frame:0 vi_tstamp:99167467360 data:0x01020001
     kworker/2:2-10569 [002] ....  3199.516693: rtcpu_vinotify_event: tstamp:100138417694 tag:FS channel:0x00 frame:0 vi_tstamp:100138399615 data:0x00000010
     kworker/2:2-10569 [002] ....  3199.516693: rtcpu_vinotify_event: tstamp:100138417855 tag:ATOMP_FE channel:0x00 frame:0 vi_tstamp:100138399617 data:0x00000000
     kworker/2:2-10569 [002] ....  3199.516694: rtcpu_vinotify_event: tstamp:100138417991 tag:ATOMP_FS channel:0x00 frame:0 vi_tstamp:100138399618 data:0x00000000
     kworker/2:2-10569 [002] ....  3199.516694: rtcpu_vinotify_event: tstamp:100138418151 tag:CHANSEL_EMBED_SOF channel:0x23 frame:0 vi_tstamp:100138413834 data:0x00000004
     kworker/2:2-10569 [002] ....  3199.516695: rtcpu_vinotify_event: tstamp:100138418287 tag:CHANSEL_EMBED_EOF channel:0x23 frame:0 vi_tstamp:100138414228 data:0x00000008
     kworker/2:2-10569 [002] ....  3199.516699: rtos_queue_send_from_isr_failed: tstamp:100138419721 queue:0x0bcb41f8
     kworker/2:2-10569 [002] ....  3199.516700: rtos_queue_send_from_isr_failed: tstamp:100138419874 queue:0x0bcb8a60
     kworker/2:2-10569 [002] ....  3199.516701: rtos_queue_send_from_isr_failed: tstamp:100138420027 queue:0x0bcba5e0
     kworker/2:2-10569 [002] ....  3199.516702: rtos_queue_send_from_isr_failed: tstamp:100138420172 queue:0x0bcbb3a0
     kworker/2:2-10569 [002] ....  3199.516702: rtos_queue_send_from_isr_failed: tstamp:100138420317 queue:0x0bcbc160
     kworker/2:2-10569 [002] ....  3199.516703: rtcpu_vinotify_event: tstamp:100138914237 tag:ATOMP_EMB_DATA_DONE channel:0x23 frame:0 vi_tstamp:100138414256 data:0x00000000
     kworker/2:2-10569 [002] ....  3199.516703: rtcpu_vinotify_event: tstamp:100138914379 tag:RESERVED_19 channel:0x23 frame:0 vi_tstamp:99167914048 data:0x03020001
     kworker/2:2-10569 [002] ....  3199.516704: rtcpu_vinotify_event: tstamp:100138914538 tag:CHANSEL_PXL_SOF channel:0x23 frame:0 vi_tstamp:100138415182 data:0x00000001
     kworker/2:2-10569 [002] ....  3199.516704: rtcpu_vinotify_event: tstamp:100138914673 tag:RESERVED_19 channel:0x23 frame:0 vi_tstamp:99167954912 data:0x08020001
     kworker/2:2-10569 [002] ....  3199.516705: rtcpu_vinotify_error: tstamp:100139418671 tag:CSIMUX_STREAM channel:0x00 frame:0 vi_tstamp:100139415091 data:0x00000001
     kworker/2:2-10569 [002] ....  3199.516706: rtcpu_vinotify_error: tstamp:100139444074 tag:CSIMUX_FRAME channel:0x00 frame:0 vi_tstamp:100139441241 data:0x000000a0
     kworker/2:2-10569 [002] ....  3199.516707: rtos_queue_send_from_isr_failed: tstamp:100139456811 queue:0x0bcb41f8
     kworker/2:2-10569 [002] ....  3199.516708: rtos_queue_send_from_isr_failed: tstamp:100139456963 queue:0x0bcb8a60
     kworker/2:2-10569 [002] ....  3199.516708: rtos_queue_send_from_isr_failed: tstamp:100139457116 queue:0x0bcba5e0
     kworker/2:2-10569 [002] ....  3199.516709: rtos_queue_send_from_isr_failed: tstamp:100139457261 queue:0x0bcbb3a0
     kworker/2:2-10569 [002] ....  3199.516710: rtos_queue_send_from_isr_failed: tstamp:100139457406 queue:0x0bcbc160
     kworker/2:2-10569 [002] ....  3199.516710: rtcpu_vinotify_event: tstamp:100139459657 tag:CHANSEL_PXL_EOF channel:0x23 frame:0 vi_tstamp:100139414998 data:0x04370002
     kworker/2:2-10569 [002] ....  3199.516711: rtcpu_vinotify_event: tstamp:100139459800 tag:ATOMP_FRAME_DONE channel:0x23 frame:0 vi_tstamp:100139415026 data:0x00000000
     kworker/2:2-10569 [002] ....  3199.516711: rtcpu_vinotify_event: tstamp:100139459960 tag:RESERVED_19 channel:0x23 frame:0 vi_tstamp:99199933920 data:0x02020001
     kworker/2:2-10569 [002] ....  3199.516712: rtcpu_vinotify_event: tstamp:100139460100 tag:FE channel:0x00 frame:0 vi_tstamp:100139415044 data:0x00000020
     kworker/2:2-10569 [002] ....  3199.516712: rtcpu_vinotify_event: tstamp:100139460264 tag:ATOMP_FE channel:0x00 frame:0 vi_tstamp:100139415047 data:0x00000000
     kworker/2:2-10569 [002] ....  3199.516713: rtcpu_vinotify_event: tstamp:100139460410 tag:CSIMUX_STREAM channel:0x00 frame:0 vi_tstamp:100139415091 data:0x00000001
     kworker/2:2-10569 [002] ....  3199.516713: rtcpu_vinotify_event: tstamp:100139460569 tag:FS channel:0x00 frame:0 vi_tstamp:100139441194 data:0x00000010
     kworker/2:2-10569 [002] ....  3199.516714: rtcpu_vinotify_event: tstamp:100139460704 tag:CSIMUX_FRAME channel:0x00 frame:0 vi_tstamp:100139441241 data:0x000000a0
     kworker/2:2-10569 [002] ....  3199.516718: rtcpu_vinotify_event: tstamp:100139460858 tag:FS channel:0x00 frame:0 vi_tstamp:100139441241 data:0x00000010
     kworker/2:2-10569 [002] ....  3199.516719: rtcpu_vinotify_event: tstamp:100139460994 tag:RESERVED_18 channel:0x23 frame:0 vi_tstamp:99200946080 data:0x10000000
     kworker/2:2-10569 [002] ....  3199.516719: rtcpu_vinotify_event: tstamp:100139461155 tag:RESERVED_18 channel:0x23 frame:0 vi_tstamp:99200975296 data:0x31000004
     kworker/2:2-10569 [002] ....  3199.516720: rtcpu_vinotify_event: tstamp:100139461295 tag:CHANSEL_NOMATCH channel:0x01 frame:0 vi_tstamp:100139455454 data:0x00000249
     kworker/2:2-10569 [002] ....  3199.516720: rtcpu_vinotify_error: tstamp:100139462366 tag:CHANSEL_NOMATCH channel:0x01 frame:0 vi_tstamp:100139455454 data:0x00000249
 vi-output, imx1-11424 [006] ....  3199.544341: tegra_channel_capture_frame: sof:0.0
 vi-output, imx1-11424 [006] ....  3199.544346: tegra_channel_capture_frame: eof:3204.495451200
     kworker/2:2-10569 [002] ....  3199.572649: rtcpu_vinotify_error: tstamp:100140459572 tag:CSIMUX_STREAM channel:0x00 frame:0 vi_tstamp:100140456705 data:0x00000001
     kworker/2:2-10569 [002] ....  3199.572653: rtcpu_vinotify_error: tstamp:100140485681 tag:CSIMUX_FRAME channel:0x00 frame:0 vi_tstamp:100140482850 data:0x000000a0
     kworker/2:2-10569 [002] ....  3199.572655: rtcpu_vinotify_event: tstamp:100140489222 tag:FE channel:0x00 frame:0 vi_tstamp:100140456659 data:0x00000020
     kworker/2:2-10569 [002] ....  3199.572657: rtcpu_vinotify_event: tstamp:100140489367 tag:CSIMUX_STREAM channel:0x00 frame:0 vi_tstamp:100140456705 data:0x00000001
     kworker/2:2-10569 [002] ....  3199.572657: rtcpu_vinotify_event: tstamp:100140489523 tag:FS channel:0x00 frame:0 vi_tstamp:100140482803 data:0x00000010
     kworker/2:2-10569 [002] ....  3199.572658: rtcpu_vinotify_event: tstamp:100140489660 tag:CSIMUX_FRAME channel:0x00 frame:0 vi_tstamp:100140482850 data:0x000000a0
     kworker/2:2-10569 [002] ....  3199.572658: rtcpu_vinotify_event: tstamp:100140489814 tag:FS channel:0x00 frame:0 vi_tstamp:100140482850 data:0x00000010

Embedded data should be normally received by VI, but normal image data cannot be received.
What may be the problem that makes it impossible to receive normal image data?

Try boost the clocks to try if still see the short frame message.
If still short frame then modify the driver to report less lines like 1920x540, 1920x800, … then check the log if any different

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
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

Thanks for your reply

CSIMUX_FRAME = 0x000000a0
CHANSEL_NOMATCH = 0x00000249 (camera data type is not yuv_422_8(0x1e),data type is 0x12, embedded data type)
CHANSEL_SHORT_FRAME = 0x01000000

VI (VC id = 0) receives 0x1E (yuv422_8) and 0x12 (metadata) data types at the same time, and displays CHANSEL_NOMATCH = 0x249 (data type 0x12) in the trace log. What is the problem and why the data type 0x12 is displayed?
Can’t VI receive 0x1E (yuv422_8) and 0x12 (metadata) data types at the same time?

I can’t set 1920x1 resolution, because there is only one row of data of 0x12 data type, so the log always displays SHORT_FRAME

It’s could be the embedded_metadata_height incorrect.
May need confirm the embedded lines from the sensor vendor.

Thank you for your reply
We confirm that the embedded data output by the camera sensor is one line.
Why is CHANSEL_NOMATCH displayed in trace log 0x12 (metadata type)?

The tag:CHANSEL_NOMATCH could be the embedded data send at incorrect time.
Also looks like some frame lose the FE and new FS arrive not sure if short frame relative.
You need to modify the sensor driver to report less lines to check the short frame error. After modify the sensor driver using v4l2-ctl --list-formats-ext to confirm the modification.

Screenshot from 2022-05-05 14-20-04

The camera sensor we use outputs embedded data on the first line of a frame.
Therefore, the first row of data entering the VI is embedded data.
Is this the reason why CHANSEL_NOMATCH is 0x12 ?

Sorry for the late response, have you managed to get issue resolved or still need the support? Thanks

I’m sorry for the untimely response. I have solved the problem myself. There is a problem with the max929x configuration

Glad yo know you resolved the problem, thanks for your sharing.