Issue about NVCSI

Hello, NVIDIA support team,

I encountered a problem while developing the camera driver using version R36.3. Please help me with the following detailed description:

I have four cameras connected to the Orin, named cameraA, cameraB, cameraC, and cameraD. They are connected to NVCSI through NVCSI_PHY0, NVCSI_PHY1, NVCSI_PHY2, and NVCSI_PHY3 respectively, and each cameraX has four VC-channels. When I boot the Orin and sequentially activate cameraA, B, C, and D, they all work normally. However, after I sequentially deactivate all cameras, I can only activate one camera at most. For example, after activating cameraA, cameraB, C, and D will never be able to obtain data from NVCSI’s PP normally. Interestingly, after deactivating cameraA and waiting for about 10 seconds, if I activate cameraB, cameraA, C, and D will no longer work properly.

I dumped some registers such as NVCSI_STREAM_0_PH_WC_0 and NVCSI_STREAM_0_PH_DI_0 and found they were all 0. It appears as if NVCSI is not starting.I am very sure that the MIPI signal sent by the sensor is normal and complete because the first time after a reboot, all cameras can definitely be activated.

there are log files: succeed / failed , Step1: activate cameraB succeed, then down it; Step2: activate cameraA succeed, activate cameraB FAILED;
log0711_stream_well.txt (2.6 MB)
log0711_stream_fail.txt (1.9 MB)

Please provide some debugging suggestions. Thank you.

could you please tell me how to check NVCSI pads power status and clk status? thank you

I would like to check the first two steps according the TRM
1、Enable the NVCSI clock and nvcsi_lpclk. Remove the reset of the NVCSI, but keep the PP and CIL in reset state.
Power up the CSI pad.
2、Power up the CSI pad.
3、…

You can access the NVCSI REG that tell the power and clock was enable.
I suspect the problem could be the ser/deser chip problem.

could you please tell me how to understand this CSI PHY LOG?
kworker/2:0-77604 [002] … 3072.737488: rtcpu_nvcsi_intr: tstamp:96778991084 class:GLOBAL type:PHY_INTR0 phy:1 cil:0 st:0 vc:0 status:0x40000000
kworker/2:0-77604 [002] … 3072.737490: rtcpu_nvcsi_intr: tstamp:96778991652 class:GLOBAL type:PHY_INTR0 phy:1 cil:0 st:0 vc:0 status:0x20000000
kworker/2:0-77604 [002] … 3072.737491: rtcpu_nvcsi_intr: tstamp:96778991652 class:GLOBAL type:PHY_INTR0 phy:1 cil:1 st:0 vc:0 status:0x20000000
kworker/2:0-77604 [002] … 3072.737491: rtcpu_nvcsi_intr: tstamp:96778992692 class:GLOBAL type:PHY_INTR0 phy:1 cil:0 st:0 vc:0 status:0x00000004
kworker/2:0-77604 [002] … 3072.737491: rtcpu_nvcsi_intr: tstamp:96778992692 class:GLOBAL type:PHY_INTR0 phy:1 cil:1 st:0 vc:0 status:0x00000004
kworker/2:0-77604 [002] … 3072.737492: rtcpu_nvcsi_intr: tstamp:96778993219 class:GLOBAL type:PHY_INTR0 phy:1 cil:0 st:0 vc:0 status:0x00000004

is the REG like NVCSI_PHY_0_NVCSI_CIL_PAD_CONFIG_0?

Please check the REG NVCSI_PHY_0_CILA_INTR_0_STATUS_CILA_0 for the error.

kworker/2:0-77604 [002] … 3072.737492: rtcpu_nvcsi_intr: tstamp:96778993219 class:GLOBAL type:PHY_INTR0 phy:1 cil:0 st:0 vc:0 status:0x00000004 

intr_cil_data_lane_sot_mb_err0_a,it means start of transfer multi bits err right? so NVCSI is worked but mipi data err detected?

Yes, it could be the timing cause the SOT error.

Maybe I can try to modify cil_settletime or some reg to try get valid data,is it useful?

If activate/deactivate single camera have the same problem you can try the settle time.

It didn’t work, is there any full reset pragraming sequence for nvcsi block?

what about IDAC CALIB, the result of IDAC CALIB will lead to stream failing? ,It always be 0XFC0 if streaming out failed but It is 0xFFF if it streaming out succeed.

Reboot the system and issue below command before active the camera.

echo on > /sys/devices/platform/*rtcpu/power/control

It’s working properly. Is this a small bug? Could you explain its principle? BTW, where can I set the default value to “on” for reboot, so that I don’t have to set it every time I start up?

This command keep RTCPU suspend to redo the IDAC calibration.
Don’t know why the IDAC calibration timeout in the running time but successful at the system start up.
You can add to some initrc to do it for every system boot up.

Thanks

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