Need Help to Integrate Lontium lt6911uxe in our Auvideo Based carrier board for TX2NX

Hello,
We have a custom carrier board for TX2NX SoM which is based on Auvidea JN30D platform design. We have placed Lontium LT6911UXE chip for our HDMI2CSI needs. I need your help in integrating lontium device into the device tree so that the lontium driver gets loaded properly, functions properly and gets integrated into the l4t / v4l2 framework seamlessly. I am ataching the existing dtsi into which I would like to add lontium device and the necessary hooks to make the whole video path to work correctly. Also attaching a block diagram showing interface between lontium and tx2nx module in our carrier board.

Lontium has provided some guidance and pointers/references but I could not get the new modified dtsi to compile when I tried to follow their directions.
https://github.com/InES-HPMM/Lontium_lt6911uxc/blob/main/lt6911uxc.txt
kernel_tegra186-p3636-0001-p3509-0000-a01.txt (247.1 KB)

Lontium to TX2NX connections.pdf (57.9 KB)

Any help or directions would be greatly appreciated.

Thanks

hello ajoshi,

there should be video node created (i.e. /dev/video0) once you configure device tree correctly. if yes, please refer to Approaches for Validating and Testing the V4L2 Driver.
you may see-also Debugging Tips section for troubleshooting.

Hi Jerry,
Thanks for responding. I have added entry in dtsi for lontium lt6911uxe chip in couple of files, which I am attaching. They are part of the kernel_src provided by Auvidea and are located at kernel_src/hardware/nvidia/platform/t18x/lanai/kernel-dts/common/

I then recompile the kernel, copy the generated dtb under kernel_output/arch/arm64/boot/dtb/ on the target in /boot/dtb/
I also copy the new Image onto the target in /boot/
Still when I load the driver module it gives out message “lt6911uxe: loading out-of-tree module taints kernel”. I am still struggling to get the driver loaded properly.
The Lontium chip is on i2c bus 1 at address 0x2b as shown from output of i2cdetect
sudo i2cdetect -y -r 1
[sudo] password for rgb:
0 1 2 3 4 5 6 7 8 9 a b c d e f
00: – – – – – – – – – – – – –
10: – – – – – – – – – – – – – – – –
20: – – – – – – – – – – – 2b – – – –
30: – – – – – – – – – – – – – – – –
40: – – – – – – – – – – – – – – – –
50: – – – – – – – – – – – – – – – –
60: – – – – – – – – – – – – – – – –
70: – – – – – – – –

Please note that I haven’t included the driver as part of kernel and loading it as module using the command “sudo insmod lt6911uxe.ko”
Any help will be appreciated. Thanks.

tegra186-camera-lanai-rbpcv2-imx219-auvidea.txt (4.6 KB)
tegra186-camera-rbpcv2-imx219-auvidea.txt (31.7 KB)

hello ajoshi,

may I double check which Jetpack public release version you’re working with,
besides, please setup serial console to gather the complete booting logs for reference.

Hello Jerry,

After some struggling and efforts, I was able to flash my modifided dtsi on to the device and got the Lontinum driver to at least load but is crashing. Sending the logs and the device tree configuration. Kindly take a look and let me know what you think could be the issue. The tegra release version is:
cat /etc/nv_tegra_release

R32 (release), REVISION: 6.1, GCID: 27863751, BOARD: t186ref, EABI: aarch64, DATE: Mon Jul 26 19:36:31 UTC 2021

Jul 21 11:54:01 rgb-desktop kernel: [ 145.864925] lt6911uxe: loading out-of-tree module taints kernel.
Jul 21 11:54:01 rgb-desktop kernel: [ 145.872428] lt6911uxe 0-002b: Failed to get IRQ number
Jul 21 11:54:01 rgb-desktop kernel: [ 145.877694] lt6911uxe: probe of 0-002b failed with error -22
Jul 21 11:54:01 rgb-desktop kernel: [ 145.883524] sysfs: cannot create duplicate filename ‘/class/chip_class’
Jul 21 11:54:01 rgb-desktop kernel: [ 145.890221] ------------[ cut here ]------------
Jul 21 11:54:01 rgb-desktop kernel: [ 145.894845] WARNING: CPU: 3 PID: 9015 at /dvs/git/dirty/git-master_linux/kernel/kernel-4.9/fs/sysfs/dir.c:31 sysfs_warn_dup+0x68/0x88
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906819] Modules linked in: lt6911uxe(O+) bnep fuse xt_conntrack ipt_MASQUERADE nf_nat_masquerade_ipv4 nf_conntrack_netlink nfnetlink xt_addrtype iptable_filter iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 nf_nat nf_conntrack br_netfilter zram userspace_alert overlay nvgpu ip_tables x_tables
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906854]
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906859] CPU: 3 PID: 9015 Comm: insmod Tainted: G O 4.9.253-tegra #1
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906861] Hardware name: lanai-3636 (DT)
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906863] task: ffffffc0b1bf4600 task.stack: ffffffc034eb4000
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906868] PC is at sysfs_warn_dup+0x68/0x88
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906871] LR is at sysfs_warn_dup+0x68/0x88
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906874] pc : [] lr : [] pstate: 40400045
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906875] sp : ffffffc034eb7940
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906877] x29: ffffffc034eb7940 x28: 0000000000000018
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906882] x27: 0000000000000122 x26: 0000000000000030
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906886] x25: 0000000000000000 x24: ffffff8008f8b970
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906891] x23: ffffff800119d4d0 x22: ffffffc0f11def18
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906895] x21: ffffffc0f11dc618 x20: ffffffc07687b140
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906899] x19: ffffffc0e94ef000 x18: 0000000000000010
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906903] x17: 0000000000000000 x16: 0000000000000000
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906907] x15: ffffffffffffffff x14: ffffff808a16e5b7
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906912] x13: ffffff800a16e5c5 x12: 0000000000000000
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906916] x11: 0000000005f5e0ff x10: 0000000000000454
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906920] x9 : 00000000ffffffd0 x8 : ffffff80083d6cf0
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906924] x7 : ffffff8009ed4468 x6 : ffffffc0f66cebf0
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906928] x5 : ffffffc0f66cebf0 x4 : 0000000000000000
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906932] x3 : ffffffc0f66d47f8 x2 : ffffffc0f66cebf0
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906936] x1 : ffffffc0b1bf4600 x0 : 000000000000003b
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906939]
Jul 21 11:54:01 rgb-desktop kernel: [ 145.906941] —[ end trace a5fffbc2b0e1bdca ]—
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911550] Call trace:
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911555] [] sysfs_warn_dup+0x68/0x88
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911558] [] sysfs_create_dir_ns+0x9c/0xb0
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911563] [] kobject_add_internal+0x98/0x348
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911566] [] kset_register+0x54/0x98
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911571] [] __class_register+0xcc/0x220
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911574] [] __class_create+0x60/0x90
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911585] [] chip_probe+0x78/0x3a0 [lt6911uxe]
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911591] [] i2c_device_probe+0x144/0x258
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911594] [] driver_probe_device+0x298/0x448
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911596] [] __driver_attach+0xdc/0x128
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911600] [] bus_for_each_dev+0x5c/0xa8
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911602] [] driver_attach+0x30/0x40
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911605] [] bus_add_driver+0x20c/0x2a8
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911608] [] driver_register+0x6c/0x110
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911611] [] i2c_register_driver+0x4c/0xb0
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911617] [] chip_driver_init+0x18/0x30 [lt6911uxe]
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911622] [] do_one_initcall+0x44/0x130
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911627] [] do_init_module+0x64/0x1b0
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911632] [] load_module+0x10ac/0x12e0
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911635] [] SyS_finit_module+0xd8/0xf0
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911637] [] el0_svc_naked+0x34/0x38
Jul 21 11:54:01 rgb-desktop kernel: [ 145.911772] kobject_add_internal failed for chip_class with -EEXIST, don’t try to register things with the same name in the same directory.
Jul 21 11:54:02 rgb-desktop kernel: [ 145.924654] lt6911uxe 1-002b: Failed to get IRQ number
Jul 21 11:54:02 rgb-desktop kernel: [ 145.929893] lt6911uxe: probe of 1-002b failed with error -22
Jul 21 11:54:02 rgb-desktop kernel: [ 145.935725] sysfs: cannot create duplicate filename ‘/class/chip_class’
Jul 21 11:54:02 rgb-desktop kernel: [ 145.942383] ------------[ cut here ]------------
Jul 21 11:54:02 rgb-desktop PackageKit: search-file transaction /30_ececdcdb from uid 1000 finished with success after 358ms
Jul 21 11:54:02 rgb-desktop PackageKit: search-file transaction /31_ecdaacae from uid 1000 finished with success after 352ms
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945637] LT6911UXE: reset chip
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945638] Unable to handle kernel read from unreadable memory at virtual address 000001dc
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945639] Mem abort info:
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945640] ESR = 0x96000005
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945642] Exception class = DABT (current EL), IL = 32 bits
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945643] SET = 0, FnV = 0
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945644] EA = 0, S1PTW = 0
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945645] Data abort info:
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945646] ISV = 0, ISS = 0x00000005
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945647] CM = 0, WnR = 0
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945650] user pgtable: 4k pages, 39-bit VAs, pgd = ffffffc0e3cc3000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945653] [00000000000001dc] *pgd=0000000000000000, *pud=0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945657] Internal error: Oops: 96000005 [#1] PREEMPT SMP
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945677] Modules linked in: lt6911uxe(O+) bnep fuse xt_conntrack ipt_MASQUERADE nf_nat_masquerade_ipv4 nf_conntrack_netlink nfnetlink xt_addrtype iptable_filter iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 nf_nat nf_conntrack br_netfilter zram userspace_alert overlay nvgpu ip_tables x_tables
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945681] CPU: 5 PID: 9018 Comm: lt6911uxe_kthre Tainted: G W O 4.9.253-tegra #1
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945682] Hardware name: lanai-3636 (DT)
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945684] task: ffffffc0e4bc4600 task.stack: ffffffc034e68000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945691] PC is at regmap_write+0x24/0x78
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945701] LR is at WriteI2C_Byte+0x38/0x88 [lt6911uxe]
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945703] pc : [] lr : [] pstate: 20400045
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945704] sp : ffffffc034e6bd90
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945706] x29: ffffffc034e6bd90 x28: 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945708] x27: 0000000000000000 x26: 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945710] x25: 0000000000000000 x24: 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945712] x23: ffffff800119e358 x22: 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945714] x21: 00000000000000e0 x20: 00000000000000ff
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945716] x19: 0000000000000000 x18: 0000000000000400
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945718] x17: 0000000000000003 x16: 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945720] x15: 000000000000036c x14: 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945722] x13: 0000000000000587 x12: 071c71c71c71c71c
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945724] x11: 000000000000000b x10: 0000000000000a10
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945726] x9 : ffffffc034e6bc60 x8 : 7465736572203a45
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945728] x7 : 585531313936544c x6 : ffffff800a16e0a5
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945730] x5 : 0000000000000000 x4 : 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945732] x3 : ffffffffffffffff x2 : 00000000000000e0
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945734] x1 : 00000000000000ff x0 : ffffff800119e4b0
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945735]
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945736] Process lt6911uxe_kthre (pid: 9018, stack limit = 0xffffffc034e68000)
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945738] Call trace:
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945742] [] regmap_write+0x24/0x78
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945748] [] WriteI2C_Byte+0x38/0x88 [lt6911uxe]
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945754] [] LT6911UXE_Mutex_Lock+0x1c/0x30 [lt6911uxe]
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945759] [] LT6911UXE_Main+0x20/0x120 [lt6911uxe]
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945763] [] kthread+0xec/0xf0
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945766] [] ret_from_fork+0x10/0x30
Jul 21 11:54:02 rgb-desktop kernel: [ 145.945769] —[ end trace a5fffbc2b0e1bdcb ]—
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993636] LT6911UXE: reset chip
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993636] Unable to handle kernel read from unreadable memory at virtual address 000001dc
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993637] Mem abort info:
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993638] ESR = 0x96000005
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993641] Exception class = DABT (current EL), IL = 32 bits
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993642] SET = 0, FnV = 0
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993643] EA = 0, S1PTW = 0
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993644] Data abort info:
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993645] ISV = 0, ISS = 0x00000005
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993646] CM = 0, WnR = 0
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993649] user pgtable: 4k pages, 39-bit VAs, pgd = ffffffc0e5f63000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993652] [00000000000001dc] *pgd=0000000000000000, *pud=0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993656] Internal error: Oops: 96000005 [#2] PREEMPT SMP
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993677] Modules linked in: lt6911uxe(O+) bnep fuse xt_conntrack ipt_MASQUERADE nf_nat_masquerade_ipv4 nf_conntrack_netlink nfnetlink xt_addrtype iptable_filter iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 nf_nat nf_conntrack br_netfilter zram userspace_alert overlay nvgpu ip_tables x_tables
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993681] CPU: 5 PID: 9021 Comm: lt6911uxe_kthre Tainted: G D W O 4.9.253-tegra #1
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993682] Hardware name: lanai-3636 (DT)
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993684] task: ffffffc0e4bc2a00 task.stack: ffffffc034e64000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993691] PC is at regmap_write+0x24/0x78
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993701] LR is at WriteI2C_Byte+0x38/0x88 [lt6911uxe]
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993702] pc : [] lr : [] pstate: 20400045
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993703] sp : ffffffc034e67d90
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993706] x29: ffffffc034e67d90 x28: 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993708] x27: 0000000000000000 x26: 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993710] x25: 0000000000000000 x24: 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993713] x23: ffffff800119e358 x22: 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993715] x21: 00000000000000e0 x20: 00000000000000ff
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993717] x19: 0000000000000000 x18: 0000007f95927a70
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993719] x17: 0000000000000003 x16: 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993721] x15: 00002f5a70000000 x14: 00000000010679dd
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993723] x13: 0000000000000b8f x12: 071c71c71c71c71c
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993725] x11: 000000000000000b x10: 0000000000000a10
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993727] x9 : ffffffc034e67c60 x8 : 7465736572203a45
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993729] x7 : 585531313936544c x6 : ffffff800a16e0a5
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993731] x5 : 0000000000000000 x4 : 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993733] x3 : ffffffffffffffff x2 : 00000000000000e0
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993735] x1 : 00000000000000ff x0 : ffffff800119e4b0
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993736]
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993737] Process lt6911uxe_kthre (pid: 9021, stack limit = 0xffffffc034e64000)
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993738] Call trace:
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993742] [] regmap_write+0x24/0x78
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993749] [] WriteI2C_Byte+0x38/0x88 [lt6911uxe]
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993755] [] LT6911UXE_Mutex_Lock+0x1c/0x30 [lt6911uxe]
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993760] [] LT6911UXE_Main+0x20/0x120 [lt6911uxe]
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993764] [] kthread+0xec/0xf0
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993768] [] ret_from_fork+0x10/0x30
Jul 21 11:54:02 rgb-desktop kernel: [ 145.993770] —[ end trace a5fffbc2b0e1bdcc ]—
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455936] WARNING: CPU: 3 PID: 9015 at /dvs/git/dirty/git-master_linux/kernel/kernel-4.9/fs/sysfs/dir.c:31 sysfs_warn_dup+0x68/0x88
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455957] Modules linked in: lt6911uxe(O+) bnep fuse xt_conntrack ipt_MASQUERADE nf_nat_masquerade_ipv4 nf_conntrack_netlink nfnetlink xt_addrtype iptable_filter iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 nf_nat nf_conntrack br_netfilter zram userspace_alert overlay nvgpu ip_tables x_tables
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455959]
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455962] CPU: 3 PID: 9015 Comm: insmod Tainted: G D W O 4.9.253-tegra #1
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455964] Hardware name: lanai-3636 (DT)
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455965] task: ffffffc0b1bf4600 task.stack: ffffffc034eb4000
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455968] PC is at sysfs_warn_dup+0x68/0x88
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455970] LR is at sysfs_warn_dup+0x68/0x88
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455972] pc : [] lr : [] pstate: 40400045
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455973] sp : ffffffc034eb7940
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455976] x29: ffffffc034eb7940 x28: 0000000000000018
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455979] x27: 0000000000000122 x26: 0000000000000030
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455981] x25: 0000000000000000 x24: ffffff8008f8b970
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455984] x23: ffffff800119d4d0 x22: ffffffc0f11def18
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455986] x21: ffffffc0f11dc618 x20: ffffffc07687b640
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455989] x19: ffffffc0e94ef000 x18: 0000000000000010
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455991] x17: 0000000000000000 x16: 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455993] x15: ffffffffffffffff x14: ffffff808a16e5b7
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455996] x13: ffffff800a16e5c5 x12: 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 146.455998] x11: 0000000005f5e0ff x10: 000000000000048a
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456001] x9 : 00000000ffffffd0 x8 : ffffff80083d6cf0
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456008] x7 : ffffff8009ed4468 x6 : ffffffc0f66cebf0
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456010] x5 : ffffffc0f66cebf0 x4 : 0000000000000000
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456012] x3 : ffffffc0f66d47f8 x2 : ffffffc0f66cebf0
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456015] x1 : ffffffc0b1bf4600 x0 : 000000000000003b
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456016]
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456018] —[ end trace a5fffbc2b0e1bdcd ]—
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456020] Call trace:
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456025] [] sysfs_warn_dup+0x68/0x88
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456028] [] sysfs_create_dir_ns+0x9c/0xb0
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456034] [] kobject_add_internal+0x98/0x348
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456038] [] kset_register+0x54/0x98
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456046] [] __class_register+0xcc/0x220
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456048] [] __class_create+0x60/0x90
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456060] [] chip_probe+0x78/0x3a0 [lt6911uxe]
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456066] [] i2c_device_probe+0x144/0x258
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456070] [] driver_probe_device+0x298/0x448
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456072] [] __driver_attach+0xdc/0x128
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456075] [] bus_for_each_dev+0x5c/0xa8
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456077] [] driver_attach+0x30/0x40
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456079] [] bus_add_driver+0x20c/0x2a8
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456082] [] driver_register+0x6c/0x110
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456084] [] i2c_register_driver+0x4c/0xb0
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456090] [] chip_driver_init+0x18/0x30 [lt6911uxe]
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456093] [] do_one_initcall+0x44/0x130
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456098] [] do_init_module+0x64/0x1b0
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456101] [] load_module+0x10ac/0x12e0
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456104] [] SyS_finit_module+0xd8/0xf0
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456106] [] el0_svc_naked+0x34/0x38
Jul 21 11:54:02 rgb-desktop kernel: [ 146.456279] kobject_add_internal failed for chip_class with -EEXIST, don’t try to register things with the same name in the same directory.
Jul 21 11:54:02 rgb-desktop PackageKit: search-file transaction /32_ebbaecdd from uid 1000 finished with success after 363ms
Jul 21 11:54:03 rgb-desktop kernel: [ 146.467009] lt6911uxe 2-002b: Failed to get IRQ number
Jul 21 11:54:03 rgb-desktop kernel: [ 146.467061] lt6911uxe: probe of 2-002b failed with error -22
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533633] LT6911UXE: reset chip
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533633] Unable to handle kernel read from unreadable memory at virtual address 000001dc
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533634] Mem abort info:
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533636] ESR = 0x96000005
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533638] Exception class = DABT (current EL), IL = 32 bits
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533640] SET = 0, FnV = 0
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533641] EA = 0, S1PTW = 0
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533642] Data abort info:
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533643] ISV = 0, ISS = 0x00000005
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533644] CM = 0, WnR = 0
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533647] user pgtable: 4k pages, 39-bit VAs, pgd = ffffffc0e7bc5000
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533650] [00000000000001dc] *pgd=0000000000000000, *pud=0000000000000000
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533653] Internal error: Oops: 96000005 [#3] PREEMPT SMP
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533674] Modules linked in: lt6911uxe(O) bnep fuse xt_conntrack ipt_MASQUERADE nf_nat_masquerade_ipv4 nf_conntrack_netlink nfnetlink xt_addrtype iptable_filter iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 nf_nat nf_conntrack br_netfilter zram userspace_alert overlay nvgpu ip_tables x_tables
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533678] CPU: 4 PID: 9029 Comm: lt6911uxe_kthre Tainted: G D W O 4.9.253-tegra #1
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533680] Hardware name: lanai-3636 (DT)
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533681] task: ffffffc0ee2f2a00 task.stack: ffffffc032028000
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533688] PC is at regmap_write+0x24/0x78
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533697] LR is at WriteI2C_Byte+0x38/0x88 [lt6911uxe]
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533699] pc : [] lr : [] pstate: 20400045
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533700] sp : ffffffc03202bd90
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533703] x29: ffffffc03202bd90 x28: 0000000000000000
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533705] x27: 0000000000000000 x26: 0000000000000000
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533707] x25: 0000000000000000 x24: 0000000000000000
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533709] x23: ffffff800119e358 x22: 0000000000000000
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533711] x21: 00000000000000e0 x20: 00000000000000ff
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533713] x19: 0000000000000000 x18: 0000000000000400
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533715] x17: 0000000000000003 x16: 0000000000000000
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533717] x15: 0000000000000298 x14: 0000000000000000
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533719] x13: 0000000000000b13 x12: 071c71c71c71c71c
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533721] x11: 000000000000000b x10: 0000000000000a10
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533723] x9 : ffffffc03202bc60 x8 : 7465736572203a45
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533725] x7 : 585531313936544c x6 : ffffff800a16e0a5
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533727] x5 : 0000000000000000 x4 : 0000000000000000
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533729] x3 : ffffffffffffffff x2 : 00000000000000e0
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533730] x1 : 00000000000000ff x0 : ffffff800119e4b0
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533731]
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533733] Process lt6911uxe_kthre (pid: 9029, stack limit = 0xffffffc032028000)
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533735] Call trace:
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533738] [] regmap_write+0x24/0x78
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533744] [] WriteI2C_Byte+0x38/0x88 [lt6911uxe]
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533748] [] LT6911UXE_Mutex_Lock+0x1c/0x30 [lt6911uxe]
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533753] [] LT6911UXE_Main+0x20/0x120 [lt6911uxe]
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533757] [] kthread+0xec/0xf0
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533760] [] ret_from_fork+0x10/0x30
Jul 21 11:54:03 rgb-desktop kernel: [ 146.533763] —[ end trace a5fffbc2b0e1bdce ]—
tegra186-camera-lanai-rbpcv2-imx219-auvidea.txt (4.0 KB)
tegra186-camera-rbpcv2-imx219-auvidea.txt (31.0 KB)

hello ajoshi,

there’re probing failure has reported..

since it’s failure due to device registration.
please also check you’re using GPIO correctly regrading to this error, Failed to get IRQ number
for instance, please check you’re using free GPIOs for camera controls.

Attaching the serial spew during boot.
When i load the driver module, there is no serial output

welcome to lk
adc initialized
chip_revision initialized
speedo initialized
dt initialized
clk_init_mrq: mrq handler registered
383 clocks registered
clock initialized
reset initialized
i2c5 controller initialized
i2c10 controller initialized
initialized i2c mrq handling
i2c initialized
thermal initialized
fuse initialized
soctherm initialized
aotag initialized
cvc initialized
regulator initialized
dvs initialized
t186_dvs initialized
pm initialized
tegra186_reset initialized
uart initialized
sku_init: not sku 00
sku initialized
modules initialized
tag initialized
avfs_clk_platform initialized
parse_possible_parent_table: pllp_bb not in allowed parent table for axi_cbb
clock_dt initialized
powergate initialized
avfs_gpu initialized
clock_gpu initialized
debugfs_mrq initialized
emc initialized
gpmu2bpmp initialized
mc_init_mrq: mrq handler registered
mc initialized
pg_mrq initialized
pg_legacy_mrq initialized
pm_post initialized
ppm initialized
uphy_dt initialized
uphy initialized
mrq initialized
tag is 91572a54614f84d0fd0c270beec2c56f
tag_lateinit initialized
clock_debugfs initialized
thermal_test initialized
avfs_clk_platform_post initialized
avfs_debugfs initialized
clock_pto initialized
cvc_dt initialized
debugfs_cons_init initialized
dvs_debugfs initialized
rm initialized
edp initialized
gboost initialized
powergate_debug initialized
regulator_post initialized
sku_debugfs initialized
speedo_debugfs initialized
soctherm_debug initialized
aotag_hsm initialized
sc7_diag initialized
starting app shell
entering main console loop
] WARNING: at platform/drivers/clk/clk-mrq.c:290

hello ajoshi,

please also check with the vendor since you’re developing with auvideo-based-carrier-board, for instance, please check the schematic, device tree settings..etc.
BTW, you may collect all the logs as single text file, and attach it here for reference.

Hello Jerry,
I got past all the errors after I fixed device tree issues, but now I need clarification on how to proceed regarding video capture on CSI lanes. I am posting my most current device tree implementation, after which it creates /dev/media0 and 3 video devices 0,1 & 2. I haven’t even loaded the driver. Also there is no support for v4l2 in the driver, wherein the vendor (Lontium) has provided bare minimum functionalities (mainly support for hotplug detection, reset and interrupts, and i2c comm), Do I need to follow the sensor driver development guide to get a fully functional capture device and add this to the driver?

/ {
host1x {
/delete-node/ vi;
vi@15700000 {
num-channels = <4>;
status=“okay”;
ports {
status=“okay”;
#address-cells = <1>;
#size-cells = <0>;
vi_port0: port@0 {
status=“okay”;
reg = <0>;
hdmi2csi_vi_in0: endpoint {
status=“okay”;
//vc-id=<0>;
port-index = <0>;
bus-width = <2>;
remote-endpoint = <&hdmi2csi_csi_out0>;
};
};
vi_port1: port@1 {
status=“okay”;
reg = <1>;
hdmi2csi_vi_in1: endpoint {
status=“okay”;
//vc-id=<1>;
port-index = <2>;
bus-width = <2>;
remote-endpoint = <&hdmi2csi_csi_out1>;
};
};
vi_port2: port@2 {
status=“okay”;
reg = <2>;
hdmi2csi_vi_in2: endpoint {
status=“okay”;
//vc-id=<2>;
port-index = <4>;
bus-width = <1>;
remote-endpoint = <&hdmi2csi_csi_out2>;
};
};
vi_port3: port@3 {
status=“okay”;
reg = <3>;
hdmi2csi_vi_in3: endpoint {
status=“okay”;
//vc-id=<3>;
port-index = <5>;
bus-width = <1>;
remote-endpoint = <&hdmi2csi_csi_out3>;
};
};
};
};

	nvcsi@150c0000 {
		status="okay";
		num-channels = <4>;
		#address-cells = <1>;
		#size-cells = <0>;
		csi_chan0: channel@0 {
			status="okay";
			#address-cells = <1>;
			#size-cells = <0>;
			reg = <0>;
			ports {
				#address-cells = <1>;
				#size-cells = <0>;
				csi_chan0_port0: port@0 {
					status="okay";
					reg = <0>;
					hdmi2csi_csi_in0: endpoint@0 {
						port-index = <0>;
						bus-width = <2>;
						remote-endpoint = <&hdmi2csi_lt6911_out0>;
					};
				};
				csi_chan0_port1: port@1 {
					status="okay";
					reg = <1>;
					hdmi2csi_csi_out0: endpoint@1 {
					    status = "ok";
					    remote-endpoint = <&hdmi2csi_vi_in0>;
					};
				};
			};
		};
		csi_chan1: channel@1 {
			status="okay";
			#address-cells = <1>;
			#size-cells = <0>;
			reg = <1>;
			ports {
				#address-cells = <1>;
				#size-cells = <0>;
				csi_chan1_port0: port@2 {
					status="okay";
					reg = <0>;
					hdmi2csi_csi_in1: endpoint@2 {
						port-index = <2>;
						bus-width = <2>;
						remote-endpoint = <&hdmi2csi_csi_out1>;
					};
				};
				csi_chan1_port1: port@3 {
					status="okay";
					reg = <1>;						
					hdmi2csi_csi_out1: endpoint@3 {
						remote-endpoint = <&hdmi2csi_vi_in1>;
					};
				};
			};
		};
		csi_chan2: channel@2 {
			#address-cells = <1>;
			#size-cells = <0>;
			reg = <2>;
			status="okay";
			ports {
				#address-cells = <1>;
				#size-cells = <0>;
				csi_chan2_port0: port@4 {
					status="okay";
					reg = <0>;
					hdmi2csi_csi_in2: endpoint@4 {
						status="okay";
						port-index = <4>;
						bus-width = <1>;
						remote-endpoint = <&hdmi2csi_csi_out2>;
					};
				};
				csi_chan2_port1: port@5 {
					status="okay";
					reg = <1>;
					hdmi2csi_csi_out2: endpoint@5 {
						status="okay";
						remote-endpoint = <&hdmi2csi_vi_in2>;
					};
				};
			};
		};
		csi_chan3: channel@3 {
			status="okay";
			#address-cells = <1>;
			#size-cells = <0>;
			reg = <3>;
			ports {
				#address-cells = <1>;
				#size-cells = <0>;
				csi_chan3_port0: port@6 {
					status="okay";
					reg = <0>;
					hdmi2csi_csi_in3: endpoint@6 {
						status="okay";
						port-index = <5>;
						bus-width = <1>;
						remote-endpoint = <&hdmi2csi_csi_out3>;
					};
				};
				csi_chan3_port1: port@7 {
					status="okay";
					reg = <1>;
					hdmi2csi_csi_out3: endpoint@7 {
						status="okay";
						remote-endpoint = <&hdmi2csi_vi_in3>;
					};
				};
			};
		};
	};
};

i2c@3180000 {
	status = "disabled";
};

i2c@3160000{
	status = "okay";
};

i2c@c240000{
	status = "okay";
	//clock-frequency = <100000>;
	lt6911uxe@2b {
                #address-cells = <0x1>;
                #size-cells = <0x4>;
                compatible = "nvidia,lt6911uxe";
                reg = <0x2b>;
                status = "okay";
                devnode = "video0";
	    power-gpios = <&tegra_main_gpio TEGRA_MAIN_GPIO(C, 2) GPIO_ACTIVE_HIGH>;
                reset-gpios = <&tegra_main_gpio TEGRA_MAIN_GPIO(C, 4) GPIO_ACTIVE_HIGH>;
   		    interrupt-gpios = <&tegra_main_gpio TEGRA_MAIN_GPIO(C, 1) GPIO_ACTIVE_LOW>;
	    set_mode_delay_ms = "5000";
		mode0 { // IMX219_MODE_3264x2464_21FPS //
			mclk_khz = "24000";
			num_lanes = "2";
			tegra_sinterface = "serial_c";
			phy_mode = "DPHY";
			discontinuous_clk = "yes";
			dpcm_enable = "false";
			cil_settletime = "0";

			active_w = "3264";
			active_h = "2464";
			pixel_t = "bayer_rggb";
			readout_orientation = "90";
			line_length = "3448";
			inherent_gain = "1";
			mclk_multiplier = "9.33";
			pix_clk_hz = "182400000";

			gain_factor = "16";
			framerate_factor = "1000000";
			exposure_factor = "1000000";
			min_gain_val = "16"; // 1.00x //
			max_gain_val = "170"; // 10.66x //
			step_gain_val = "1";
			default_gain = "16"; // 1.00x //
			min_hdr_ratio = "1";
			max_hdr_ratio = "1";
			min_framerate = "2000000"; // 2.0 fps //
			max_framerate = "21000000"; // 21.0 fps //
			step_framerate = "1";
			default_framerate = "21000000"; // 21.0 fps //
			min_exp_time = "13"; // us //
			max_exp_time = "683709"; // us //
			step_exp_time = "1";
			default_exp_time = "2495"; // us //

			embedded_metadata_height = "2";
		};
		mode1 { // MODE_3264x1848_28FPS //
			mclk_khz = "24000";
			num_lanes = "2";
			tegra_sinterface = "serial_c";
			phy_mode = "DPHY";
			discontinuous_clk = "yes";
			dpcm_enable = "false";
			cil_settletime = "0";

			active_w = "3264";
			active_h = "1848";
			pixel_t = "bayer_rggb";
			readout_orientation = "90";
			line_length = "3448";
			inherent_gain = "1";
			mclk_multiplier = "9.33";
			pix_clk_hz = "182400000";

			gain_factor = "16";
			framerate_factor = "1000000";
			exposure_factor = "1000000";
			min_gain_val = "16"; // 1.00x //
			max_gain_val = "170"; // 10.66x //
			step_gain_val = "1";
			default_gain = "16"; // 1.00x //
			min_hdr_ratio = "1";
			max_hdr_ratio = "1";
			min_framerate = "2000000"; // 2.0 fps //
			max_framerate = "28000000"; // 28.0 fps //
			step_framerate = "1";
			default_framerate = "28000000"; // 28.0 fps //
			min_exp_time = "13"; // us //
			max_exp_time = "683709"; // us //
			step_exp_time = "1";
			default_exp_time = "2495"; // us //

			embedded_metadata_height = "2";
		};
		mode2 { // MODE_1920x1080_30FPS //
			mclk_khz = "24000";
			num_lanes = "2";
			tegra_sinterface = "serial_c";
			phy_mode = "DPHY";
			discontinuous_clk = "yes";
			dpcm_enable = "false";
			cil_settletime = "0";

			active_w = "1920";
			active_h = "1080";
			pixel_t = "bayer_rggb";
			readout_orientation = "90";
			line_length = "3448";
			inherent_gain = "1";
			mclk_multiplier = "9.33";
			pix_clk_hz = "182400000";

			gain_factor = "16";
			framerate_factor = "1000000";
			exposure_factor = "1000000";
			min_gain_val = "16"; // 1.00x //
			max_gain_val = "170"; // 10.66x //
			step_gain_val = "1";
			default_gain = "16"; // 1.00x //
			min_hdr_ratio = "1";
			max_hdr_ratio = "1";
			min_framerate = "2000000"; // 2.0 fps //
			max_framerate = "30000000"; // 30.0 fps //
			step_framerate = "1";
			default_framerate = "30000000"; // 30.0 fps //
			min_exp_time = "13"; // us //
			max_exp_time = "683709"; // us //
			step_exp_time = "1";
			default_exp_time = "2495"; // us //

			embedded_metadata_height = "2";
		};
		mode3 {MODE_1640x1232_30FPS //
			mclk_khz = "24000";
			num_lanes = "2";
			tegra_sinterface = "serial_c";
			phy_mode = "DPHY";
			discontinuous_clk = "yes";
			dpcm_enable = "false";
			cil_settletime = "0";

			active_w = "1640";
			active_h = "1232";
			pixel_t = "bayer_rggb";
			readout_orientation = "90";
			line_length = "3448";
			inherent_gain = "1";
			mclk_multiplier = "9.33";
			pix_clk_hz = "182400000";

			gain_factor = "16";
			framerate_factor = "1000000";
			exposure_factor = "1000000";
			min_gain_val = "16"; // 1.00x //
			max_gain_val = "170"; // 10.66x //
			step_gain_val = "1";
			default_gain = "16"; // 1.00x //
			min_hdr_ratio = "1";
			max_hdr_ratio = "1";
			min_framerate = "2000000"; // 2.0 fps //
			max_framerate = "30000000"; // 60.0 fps //
			step_framerate = "1";
			default_framerate = "30000000"; // 60.0 fps //
			min_exp_time = "13"; // us //
			max_exp_time = "683709"; // us //
			step_exp_time = "1";
			default_exp_time = "2495"; // us //

			embedded_metadata_height = "2";
		};
		mode4 { //MODE_1280x720_60FPS //
			mclk_khz = "24000";
			num_lanes = "2";
			tegra_sinterface = "serial_c";
			phy_mode = "DPHY";
			discontinuous_clk = "yes";
			dpcm_enable = "false";
			cil_settletime = "0";

			active_w = "1280";
			active_h = "720";
			pixel_t = "bayer_rggb";
			readout_orientation = "90";
			line_length = "3448";
			inherent_gain = "1";
			mclk_multiplier = "9.33";
			pix_clk_hz = "182400000";

			gain_factor = "16";
			framerate_factor = "1000000";
			exposure_factor = "1000000";
			min_gain_val = "16"; // 1.00x //
			max_gain_val = "170"; // 10.66x //
			step_gain_val = "1";
			default_gain = "16"; // 1.00x //
			min_hdr_ratio = "1";
			max_hdr_ratio = "1";
			min_framerate = "2000000"; // 2.0 fps //
			max_framerate = "60000000"; // 60.0 fps //
			step_framerate = "1";
			default_framerate = "60000000"; // 60.0 fps //
			min_exp_time = "13"; // us //
			max_exp_time = "683709"; // us //
			step_exp_time = "1";
			default_exp_time = "2495"; // us //

			embedded_metadata_height = "2";
		};
		
		ports {
			#address-cells = <1>;
			#size-cells = <0>;
			port@0 {
				reg = <0>;
				hdmi2csi_lt6911_out0: endpoint {
					status = "okay";
					port-index = <0>;
					bus-width = <4>;
					remote-endpoint = <&hdmi2csi_csi_in0>;
				};
			};
		};
	};
};

i2c@c250000{
        status = "okay";
};

};

/ {
tcp: tegra-camera-platform {
compatible = “nvidia, tegra-camera-platform”;

	num_csi_lanes = <8>;
	max_lane_speed = <2500000>;
	min_bits_per_pixel = <16>;
	vi_peak_byte_per_pixel = <3>;
	vi_bw_margin_pct = <25>;
	max_pixel_rate = <240000>;
	isp_peak_byte_per_pixel = <5>;
	isp_bw_margin_pct = <25>;
            status = "okay";
            modules {
                module0 {
                        status = "okay";
                        badge = "hdmi2csi_left_6911";
                        position = "left";
                        orientation = "1";
                        drivernode0 {
                                /* Declare PCL support driver (classically known as guid)  */
                                pcl_id = "v4l2_sensor";
                                /* Driver v4l2 device name */
                                devname = "lt6911uxe 1-002b";
                                /* Declare the device-tree hierarchy to driver instance */
                                proc-device-tree = "/proc/device-tree/i2c@c240000/lt6911uxe@2b";
                        };
                };
            };
};

};

Output of media-ctl and v4l2-ctl
sudo media-ctl -p -d /dev/media0
Media controller API version 0.1.0

Media device information

driver tegra-vi4
model NVIDIA Tegra Video Input Device
serial
bus info
hw revision 0x3
driver version 0.0.0

Device topology

  • entity 1: 150c0000.nvcsi–4 (2 pads, 0 link)
    type V4L2 subdev subtype Unknown flags 0
    device node name /dev/v4l-subdev0
    pad0: Sink
    pad1: Source

  • entity 4: 150c0000.nvcsi–3 (2 pads, 1 link)
    type V4L2 subdev subtype Unknown flags 0
    device node name /dev/v4l-subdev1
    pad0: Sink
    pad1: Source
    → “vi-output, 150c0000.nvcsi–3”:0 [ENABLED]

  • entity 7: vi-output, 150c0000.nvcsi–3 (1 pad, 1 link)
    type Node subtype V4L flags 0
    device node name /dev/video0
    pad0: Sink
    ← “150c0000.nvcsi–3”:1 [ENABLED]

  • entity 17: 150c0000.nvcsi–2 (2 pads, 1 link)
    type V4L2 subdev subtype Unknown flags 0
    device node name /dev/v4l-subdev2
    pad0: Sink
    pad1: Source
    → “vi-output, 150c0000.nvcsi–2”:0 [ENABLED]

  • entity 20: vi-output, 150c0000.nvcsi–2 (1 pad, 1 link)
    type Node subtype V4L flags 0
    device node name /dev/video1
    pad0: Sink
    ← “150c0000.nvcsi–2”:1 [ENABLED]

  • entity 28: 150c0000.nvcsi–1 (2 pads, 1 link)
    type V4L2 subdev subtype Unknown flags 0
    device node name /dev/v4l-subdev3
    pad0: Sink
    pad1: Source
    → “vi-output, 150c0000.nvcsi–1”:0 [ENABLED]

  • entity 31: vi-output, 150c0000.nvcsi–1 (1 pad, 1 link)
    type Node subtype V4L flags 0
    device node name /dev/video2
    pad0: Sink
    ← “150c0000.nvcsi–1”:1 [ENABLED]

v4l2-ctl --all
Driver Info (not using libv4l2):
Driver name : tegra-video
Card type : vi-output, 150c0000.nvcsi–3
Bus info : platform:15700000.vi:2
Driver version: 4.9.253
Capabilities : 0x84200001
Video Capture
Streaming
Extended Pix Format
Device Capabilities
Device Caps : 0x04200001
Video Capture
Streaming
Extended Pix Format
Priority: 2
Video input : 0 (Camera 2: ok)
Format Video Capture:
Width/Height : 1920/1080
Pixel Format : ‘RG10’
Field : Any
Bytes per Line : 3840
Size Image : 4147200
Colorspace : Default
Transfer Function : Default (maps to Rec. 709)
YCbCr/HSV Encoding: Default (maps to ITU-R 601)
Quantization : Default (maps to Full Range)
Flags :

Camera Controls

                bypass_mode 0x009a2064 (intmenu): min=0 max=1 default=0 value=0
            override_enable 0x009a2065 (intmenu): min=0 max=1 default=0 value=0
               height_align 0x009a2066 (int)    : min=1 max=16 step=1 default=1 value=1
                 size_align 0x009a2067 (intmenu): min=0 max=2 default=0 value=0
           write_isp_format 0x009a2068 (int)    : min=1 max=1 step=1 default=1 value=1
   sensor_signal_properties 0x009a2069 (u32)    : min=0 max=0 step=0 default=0 flags=read-only, has-payload
    sensor_image_properties 0x009a206a (u32)    : min=0 max=0 step=0 default=0 flags=read-only, has-payload
  sensor_control_properties 0x009a206b (u32)    : min=0 max=0 step=0 default=0 flags=read-only, has-payload
          sensor_dv_timings 0x009a206c (u32)    : min=0 max=0 step=0 default=0 flags=read-only, has-payload
           low_latency_mode 0x009a206d (bool)   : default=0 value=0
           preferred_stride 0x009a206e (int)    : min=0 max=65535 step=1 default=0 value=0
               sensor_modes 0x009a2082 (int)    : min=0 max=30 step=1 default=30 value=30 flags=read-only

v4l2-compliance
v4l2-compliance SHA : not available

Driver Info:
Driver name : tegra-video
Card type : vi-output, 150c0000.nvcsi–3
Bus info : platform:15700000.vi:2
Driver version: 4.9.253
Capabilities : 0x84200001
Video Capture
Streaming
Extended Pix Format
Device Capabilities
Device Caps : 0x04200001
Video Capture
Streaming
Extended Pix Format

Compliance test for device /dev/video0 (not using libv4l2):

Required ioctls:
test VIDIOC_QUERYCAP: OK

Allow for multiple opens:
test second video open: OK
test VIDIOC_QUERYCAP: OK
test VIDIOC_G/S_PRIORITY: OK
test for unlimited opens: OK

Debug ioctls:
test VIDIOC_DBG_G/S_REGISTER: OK (Not Supported)
test VIDIOC_LOG_STATUS: OK

Input ioctls:
test VIDIOC_G/S_TUNER/ENUM_FREQ_BANDS: OK (Not Supported)
test VIDIOC_G/S_FREQUENCY: OK (Not Supported)
test VIDIOC_S_HW_FREQ_SEEK: OK (Not Supported)
test VIDIOC_ENUMAUDIO: OK (Not Supported)
test VIDIOC_G/S/ENUMINPUT: OK
test VIDIOC_G/S_AUDIO: OK (Not Supported)
Inputs: 1 Audio Inputs: 0 Tuners: 0

Output ioctls:
test VIDIOC_G/S_MODULATOR: OK (Not Supported)
test VIDIOC_G/S_FREQUENCY: OK (Not Supported)
test VIDIOC_ENUMAUDOUT: OK (Not Supported)
test VIDIOC_G/S/ENUMOUTPUT: OK (Not Supported)
test VIDIOC_G/S_AUDOUT: OK (Not Supported)
Outputs: 0 Audio Outputs: 0 Modulators: 0

Input/Output configuration ioctls:
test VIDIOC_ENUM/G/S/QUERY_STD: OK (Not Supported)
test VIDIOC_ENUM/G/S/QUERY_DV_TIMINGS: OK (Not Supported)
test VIDIOC_DV_TIMINGS_CAP: OK (Not Supported)
test VIDIOC_G/S_EDID: OK (Not Supported)

Test input 0:

Control ioctls:
	test VIDIOC_QUERY_EXT_CTRL/QUERYMENU: OK
	test VIDIOC_QUERYCTRL: OK
	test VIDIOC_G/S_CTRL: OK
	fail: v4l2-test-controls.cpp(633): did not check against size
	test VIDIOC_G/S/TRY_EXT_CTRLS: FAIL
	test VIDIOC_(UN)SUBSCRIBE_EVENT/DQEVENT: OK
	test VIDIOC_G/S_JPEGCOMP: OK (Not Supported)
	Standard Controls: 1 Private Controls: 12

Format ioctls:
	test VIDIOC_ENUM_FMT/FRAMESIZES/FRAMEINTERVALS: OK
	test VIDIOC_G/S_PARM: OK (Not Supported)
	test VIDIOC_G_FBUF: OK (Not Supported)
	fail: v4l2-test-formats.cpp(330): !colorspace
	fail: v4l2-test-formats.cpp(439): testColorspace(pix.pixelformat, pix.colorspace, pix.ycbcr_enc, pix.quantization)
	test VIDIOC_G_FMT: FAIL
	test VIDIOC_TRY_FMT: OK (Not Supported)
	test VIDIOC_S_FMT: OK (Not Supported)
	test VIDIOC_G_SLICED_VBI_CAP: OK (Not Supported)
	test Cropping: OK (Not Supported)
	test Composing: OK (Not Supported)
	fail: v4l2-test-formats.cpp(1550): doioctl(node, VIDIOC_S_FMT, &fmt)
	fail: v4l2-test-formats.cpp(1647): doioctl(node, VIDIOC_S_FMT, &fmt)
	test Scaling: FAIL

Codec ioctls:
	test VIDIOC_(TRY_)ENCODER_CMD: OK (Not Supported)
	test VIDIOC_G_ENC_INDEX: OK (Not Supported)
	test VIDIOC_(TRY_)DECODER_CMD: OK (Not Supported)

Buffer ioctls:
	test VIDIOC_REQBUFS/CREATE_BUFS/QUERYBUF: OK
	fail: v4l2-test-buffers.cpp(574): VIDIOC_EXPBUF is supported, but the V4L2_MEMORY_MMAP support is missing, probably due to earlier failing format tests.
	test VIDIOC_EXPBUF: OK (Not Supported)

Test input 0:

Total: 43, Succeeded: 40, Failed: 3, Warnings: 0

v4l2-ctl --list-devices
vi-output, 150c0000.nvcsi–3 (platform:15700000.vi:2):
/dev/video0

vi-output, 150c0000.nvcsi–2 (platform:15700000.vi:4):
/dev/video1

vi-output, 150c0000.nvcsi–1 (platform:15700000.vi:5):
/dev/video2

Without the driver being loaded, the devices are already created, who creates them? Isn’t the driver supposed to create the video device.

Also if I just keep channel = 1 and bus-width = 4, and modify the dtsi with just one port mapping, it doesn’t create video device at all.

Based on connection diagram i posted earlier, we have connected total 8 CSI lanes in two 4 lane camera configuration to the Lontium chip. Out of which I am using the first 4 lanes only currently, and Lontium claims we can achieve 4kp60 in YUV422 format using 4 lanes. For RGB888 we will need to use all 8 lanes, but that’s for future.

Camera 0/1
(4-Lane)
Only CSI 0
Clock Used

Camera 2/3
(4-Lane)
Only CSI 2
Clock Used

Please any help or useful guidance will be greatly appreciated.
Thanks

I am also sharing output of nvcapture and nvargus commands

nvgstcapture-1.0 --cap-dev-node=0 --color-format=1
Encoder null, cannot set bitrate!
Encoder Profile = High
Supported resolutions in case of ARGUS Camera
(2) : 640x480
(3) : 1280x720
(4) : 1920x1080
(5) : 2104x1560
(6) : 2592x1944
(7) : 2616x1472
(8) : 3840x2160
(9) : 3896x2192
(10): 4208x3120
(11): 5632x3168
(12): 5632x4224

Runtime ARGUS Camera Commands:

Help : ‘h’
Quit : ‘q’
Set Capture Mode:
mo:
(1): image
(2): video
Get Capture Mode:
gmo
Set sensor orientation:
so:
(0): none
(1): Rotate counter-clockwise 90 degrees
(2): Rotate 180 degrees
(3): Rotate clockwise 90 degrees
Get sensor orientation:
gso
Set sensor mode:
smo: e.g., smo:1
Get sensor mode:
gsmo
Set Whitebalance Mode:
wb:
(0): off
(1): auto
(2): incandescent
(3): fluorescent
(4): warm-fluorescent
(5): daylight
(6): cloudy-daylight
(7): twilight
(8): shade
(9): manual
Get Whitebalance Mode:
gwb
Set Saturation (0 to 2):
st: e.g., st:1.25
Get Saturation:
gst
Set Exposure Compensation (-2 to 2):
ec: e.g., ec:-2
Get Exposure Compensation:
gec
Set Auto Whitebalance Lock:
awbl: e.g., awbl:0
Get Auto Whitebalance Lock:
awbl
Set Auto Exposure Lock:
ael: e.g., ael:0
Get Auto Exposure Lock:
gael
Set TNR Mode:
tnrm: e.g., tnrm:1
(0): OFF
(1): FAST
(2): HIGH QUALITY
Get TNR Mode:
gtnrm
Set TNR Strength (-1 to 1):
tnrs: e.g., tnrs:0.5
Get TNR Strength:
gtnrs
Set EE Mode:
eem: e.g., eem:1
(0): OFF
(1): FAST
(2): HIGH QUALITY
Get EE Mode:
geem
Set EE Strength (-1 to 1):
ees: e.g., ees:0.5
Get EE Strength:
gees
Set Auto Exposure Anti-Banding (0 to 3):
aeab: e.g., aeab:2
(0): OFF
(1): MODE AUTO
(2): MODE 50HZ
(3): MODE 60HZ
Get Auto Exposure Anti-Banding:
gaeab
Set Gain Range:
gr: e.g., gr:1 16
Get Gain Range:
ggr
Set Exposure Time Range:
etr: e.g., etr:34000 35000
Get Exposure Time Range:
getr
Set ISP Digital Gain Range:
dgr: e.g., dgr:2 152
Get ISP Digital Gain Range:
gdgr
Capture: enter ‘j’ OR
followed by a timer (e.g., jx5000, capture after 5 seconds) OR
followed by multishot count (e.g., j:6, capture 6 images)
timer/multihot values are optional, capture defaults to single shot with timer=0s
Start Recording : enter ‘1’
Stop Recording : enter ‘0’
Video snapshot : enter ‘2’ (While recording video)
Get Preview Resolution:
gpcr
Get Image Capture Resolution:
gicr
Get Video Capture Resolution:
gvcr

Runtime encoder configuration options:

Set Encoding Bit-rate(in bytes):
br: e.g., br:4000000
Get Encoding Bit-rate(in bytes):
gbr
Set Encoding Profile(only for H.264):
ep: e.g., ep:1
(0): Baseline
(1): Main
(2): High
Get Encoding Profile(only for H.264):
gep
Force IDR Frame on video Encoder(only for H.264):
Enter ‘f’

bitrate = 4000000
Encoder Profile = High
Encoder control-rate = 1
Encoder EnableTwopassCBR = 0
Opening in BLOCKING MODE
** Message: 21:15:42.912: main:4670 iterating capture loop …
Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, execute:725 No cameras available
NvMMLiteOpen : Block : BlockType = 4
===== NVMEDIA: NVENC =====
NvMMLiteBlockCreate : Block : BlockType = 4

v4l2-ctl --set-fmt-video=width=1920,height=1080,pixelformat=NV12 --stream-mmap --stream-count=100 -d /dev/video0
VIDIOC_S_FMT: failed: Inappropriate ioctl for device

gst-launch-1.0 nvarguscamerasrc ! “video/x-raw(memory:NVMM), width=(int)1920, height=(int)1080, framerate=(fraction)60/1” ! nvvidconv ! fakesink sync=0 -vvv
Setting pipeline to PAUSED …
Pipeline is live and does not need PREROLL …
Setting pipeline to PLAYING …
Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, execute:725 No cameras available
/GstPipeline:pipeline0/GstNvArgusCameraSrc:nvarguscamerasrc0.GstPad:src: caps = video/x-raw(memory:NVMM), width=(int)1920, height=(int)1080, format=(string)NV12, framerate=(fraction)60/1
/GstPipeline:pipeline0/GstCapsFilter:capsfilter0.GstPad:src: caps = video/x-raw(memory:NVMM), width=(int)1920, height=(int)1080, format=(string)NV12, framerate=(fraction)60/1
New clock: GstSystemClock
/GstPipeline:pipeline0/Gstnvvconv:nvvconv0.GstPad:src: caps = video/x-raw(memory:NVMM), width=(int)1920, height=(int)1080, format=(string)NV12, framerate=(fraction)60/1
/GstPipeline:pipeline0/GstFakeSink:fakesink0.GstPad:sink: caps = video/x-raw(memory:NVMM), width=(int)1920, height=(int)1080, format=(string)NV12, framerate=(fraction)60/1
/GstPipeline:pipeline0/Gstnvvconv:nvvconv0.GstPad:sink: caps = video/x-raw(memory:NVMM), width=(int)1920, height=(int)1080, format=(string)NV12, framerate=(fraction)60/1
/GstPipeline:pipeline0/GstCapsFilter:capsfilter0.GstPad:sink: caps = video/x-raw(memory:NVMM), width=(int)1920, height=(int)1080, format=(string)NV12, framerate=(fraction)60/1
Got EOS from element “pipeline0”.
Execution ended after 0:00:00.001321157
Setting pipeline to PAUSED …
Setting pipeline to READY …
Setting pipeline to NULL …
Freeing pipeline …

hello ajoshi,

it’ll register video nodes (i.e. /dev/video0) once you’ve correct device tree port bindings.
please also check the Lontium output formats, is it sending bayer raw, RG10?
you may see-also Applications Using V4L2 IOCTL Directly to use V4L2 IOCTL to verify basic camera functionality.

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