JP 34.1.1 imx219 Camera issue on Xavier NX Kernel 5.10

I am working on JP 34.1.1 on custom carrier board. I have 3 imx219 camera over a cam_i2c_mux. I am able to get /dev/video0 and the first camera is working without any issues. BUt the other 2 camera’s are not working. I am adding device tree entries only for 3rd CSI camera, and the first 2 camera’s are from nvidia without any changes. One of the camera is working but has issues with the other 2.
Checked this link JP5.0 DP /dev/videoX not showing up - #3 by ShaneCCC but this is already included in 34.1.1. How can I get the other camera’s working?
Attached dmesg errors,
dmesg | grep imx
[ 16.167347] imx219 0-0010: Failed to find matching dt id
[ 16.167578] imx219 0-0010: unable to get platform data
[ 16.167698] imx219 0-0010: tegra camera driver registration failed
[ 16.167949] imx219: probe of 0-0010 failed with error -14
[ 16.169083] imx219 9-0010: tegracam sensor driver:imx219_v2.0.6
[ 16.192848] tegra-camrtc-capture-vi tegra-capture-vi: subdev imx219 9-0010 bound
[ 16.196480] imx219 10-0010: tegracam sensor driver:imx219_v2.0.6
[ 16.208142] imx219 10-0010: imx219_board_setup: error during i2c read probe (-121)
[ 16.213521] imx219 10-0010: board setup failed
[ 16.213760] imx219: probe of 10-0010 failed with error -121

Looks like i2c failed communicate with the sensor.
Did you verify it’s working with JP4.x?

Hi Shane,
All the 3 sensors are working with older releases. I can see /dev/video0, /dev/video1 and /dev/video2 being enumerated with L4T 32.x. With the same setup on L4T 34.1.1, I can see only /dev/video0.

Suppose it could be the device tree cause the problem.
May need to review your device tree.

I have converted the dtb file into dts and attached device tree file. Kindly check if there are any changes to be done.
tegra194-p3668-all.dts (308.4 KB)

It’s looks like have problem for this dts.
There have vi@{} and tegra-capture-vi{} K5.10 should change vi@ to tegra-capture-vi{} and this dts only define two imx219 instead of three.

Yeah I missed out that part, attached updated device tree. Will there be an entry for vi@15c10000 or no?
Updated_CSI.dts (308.3 KB)

I would suggest reference to tegra194-camera-e3326-a00.dtsi to implement your device tree for K5.10

Thanks

I have updated the device tree, replaced host1x { vi@15c10000 with tegra-capture-vi and
host1x { nvcsi@15a00000 with host1x@13e00000 { nvcsi@15a00000. Can you find any mistakes in my device tree?

Edit: my device tree looks similar to tegra194-camera-e3326-a00.dtsi

Hi, I could see that the CAM1 PWDN GPIO - TEGRA194_MAIN_GPIO(P, 5) is not being configured in kernel. CAM0 GPIO is being configured, but not CAM1.
gpio-429 (PP.02 )
gpio-430 (PP.03 )
gpio-431 (PP.04 |cam_reset_gpio ) out lo
gpio-432 (PP.05 )
gpio-433 (PP.06 )
gpio-434 (PP.07 )

Also observed that the same GPIOs are being configured for imx477 camera in ‘common/tegra194-camera-jakku-rbpcv3-imx477.dtsi’.

You need to check those PINs and modify them for your carrier board. If the control PINs incorrect that could have problem to make camera working.

We have the same functionality for the respective GPIOs (CAM0 & CAM1). They are being used for CSI imx219 camera as defined in ‘common/tegra194-camera-jakku-rbpcv2-imx219.dtsi’.
#define CAM0_PWDN TEGRA194_MAIN_GPIO(P, 4)
#define CAM1_PWDN TEGRA194_MAIN_GPIO(P, 5)
#define CAM_I2C_MUX TEGRA194_AON_GPIO(CC, 3)

In the previous releases we had it working. Observed that with the current release support for imx477 is added on the same cam_i2cmux, but I am disabling it as we don’t support it.

Please have scope to make sure those PINs able to control and at right status due to the kernel log tell the i2c failed.

what is the correct value for ‘pix_clk_hz’ for imx219 camera?

Hi @ShaneCCC
I converted nvidia dtb into dts and compared it with my device tree. I could see some differences and tried keeping exaclty same as nvidia’s dts for tegra194.
I can see entries for host1x {
vi@15c10000 {

as well as,
tegra-capture-vi {
compatible = “nvidia,tegra-camrtc-capture-vi”;

As mentioned in this link JP5.0 DP /dev/videoX not showing up - #5 by jdluckyday
host1x { vi@15c10000 is replaced with tegra-capture-vi But why there is still an entry for host1x { vi@15c10000?
Can you please clear this?

nvidia.dts (308.9 KB)

The sensor configuration should move to tegra-capture-vi {} and will check if vi@15c10000 need keep or need to remove next week.

Hi Shane, I went through the pinmux (tegra19x-mb1-pinmux-p3668-a01.cfg) file from the current release and compared it against pinmux file from older release(32.5). I could see many differences, but there is no update regarding Xavier NX pinmux table for the L4T 34.1.1 release.
Attached pinmux configuration file from 32.5 and 34.1 release.
tegra19x-mb1-pinmux-p3668-a01_v1.5.cfg (27.2 KB)
tegra19x-mb1-pinmux-p3668-a01_v1.6.cfg (27.2 KB)
I would like to know if we have to perform any changes related to pinmux?