intel / ipu6-drivers

152 stars 49 forks source link

Error when loading intel-ipu6 module #48

Open randomehro opened 1 year ago

randomehro commented 1 year ago

I am running 5.19.12-1-default on OpenSUSE Tumbleweed. My hardware is LENOVO 21CBCTO1WW/21CBCTO1WW, BIOS N3AET65W (1.30). I got an error when loading intel-ipu6 module (commit from 20220926) during boot:

Edit: Still the same problem with kernel 6.0.0 and the commit from 20221009

[    6.746457] intel-ipu6 intel-ipu: enabling device (0000 -> 0002)
[    6.748265] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x4)
[    6.748301] intel-ipu6 intel-ipu: physical base address 0x603c000000
[    6.748305] intel-ipu6 intel-ipu: mapped as: 0x00000000496d1881
[    6.748422] intel-ipu6 intel-ipu: IPU in secure mode
[    6.748426] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[    6.748428] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[    6.754013] proc_thermal_pci 0000:00:04.0: enabling device (0000 -> 0002)
[    6.759019] intel_rapl_common: Found RAPL domain package
[    6.762885] intel-ipu6 intel-ipu: IPC reset done
[    6.762891] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[    6.763627] intel-ipu6 intel-ipu: FW version: 20220510
[    6.763955] BUG: kernel NULL pointer dereference, address: 0000000000000304
[    6.763962] #PF: supervisor read access in kernel mode
[    6.763966] #PF: error_code(0x0000) - not-present page
[    6.763969] PGD 0 P4D 0 
[    6.763975] Oops: 0000 [#1] PREEMPT SMP NOPTI
[    6.763981] CPU: 5 PID: 665 Comm: systemd-udevd Tainted: G     U  W  OE     5.19.12-1-default #1 openSUSE Tumbleweed 665b142383228b747d71fcd0f7280693267f8cd7
[    6.763988] Hardware name: LENOVO 21CBCTO1WW/21CBCTO1WW, BIOS N3AET65W (1.30 ) 08/02/2022
[    6.763991] RIP: 0010:ipu_pci_probe.cold+0x3f0/0x90e [intel_ipu6]
[    6.764023] Code: 48 89 fa 48 85 ff 0f 84 b8 00 00 00 48 8b bf 10 03 00 00 48 85 ff 0f 84 ba 00 00 00 e8 56 b6 ff ff 48 8b 43 18 48 85 c0 74 11 <48> 8b b8 10 03 00 00 48 85 ff 74 05 e8 3c b6 ff ff 48 8b 53 20 48
[    6.764028] RSP: 0018:ffffb71440747b58 EFLAGS: 00010282
[    6.764033] RAX: fffffffffffffff4 RBX: ffff88b6c6789828 RCX: 0000000000000000
[    6.764036] RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
[    6.764039] RBP: ffff88b9e81bb000 R08: ffffb71440747af0 R09: ffff88b6c3f425a0
[    6.764043] R10: 0000000000000001 R11: 0000000000000001 R12: ffff88b9e81bb0d0
[    6.764046] R13: ffffb71445000000 R14: 00000000fffffff4 R15: ffffb71445000000
[    6.764049] FS:  00007f2330946b00(0000) GS:ffff88ba0f540000(0000) knlGS:0000000000000000
[    6.764054] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[    6.764057] CR2: 0000000000000304 CR3: 000000010b3e4002 CR4: 0000000000770ee0
[    6.764062] PKRU: 55555554
[    6.764064] Call Trace:
[    6.764069]  <TASK>
[    6.764076]  local_pci_probe+0x3e/0x80
[    6.764087]  pci_device_probe+0xc3/0x230
[    6.764094]  really_probe+0x1bf/0x390
[    6.764101]  __driver_probe_device+0xff/0x170
[    6.764106]  driver_probe_device+0x1f/0x90
[    6.764111]  __driver_attach+0xcf/0x1d0
[    6.764116]  ? __device_attach_driver+0x110/0x110
[    6.764121]  bus_for_each_dev+0x73/0xc0
[    6.764126]  bus_add_driver+0x160/0x210
[    6.764131]  driver_register+0x89/0xe0
[    6.764136]  ? 0xffffffffc0f83000
[    6.764140]  ipu_init+0x3b/0x1000 [intel_ipu6 47b5614a0b9b9e937a29eb4630298c70c28ff96d]
[    6.764161]  do_one_initcall+0x41/0x200
[    6.764169]  ? kmem_cache_alloc_trace+0x177/0x360
[    6.764177]  do_init_module+0x4a/0x1f0
[    6.764185]  __do_sys_finit_module+0xac/0x120
[    6.764192]  do_syscall_64+0x58/0x80
[    6.764200]  ? do_syscall_64+0x67/0x80
[    6.764206]  ? exit_to_user_mode_prepare+0x190/0x1f0
[    6.764211]  ? syscall_exit_to_user_mode+0x17/0x40
[    6.764216]  ? do_syscall_64+0x67/0x80
[    6.764221]  ? syscall_exit_to_user_mode+0x17/0x40
[    6.764225]  ? do_syscall_64+0x67/0x80
[    6.764230]  entry_SYSCALL_64_after_hwframe+0x63/0xcd
[    6.764237] RIP: 0033:0x7f23313128fd
[    6.764241] Code: 5d c3 66 2e 0f 1f 84 00 00 00 00 00 90 f3 0f 1e fa 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 8b 0d e3 74 0d 00 f7 d8 64 89 01 48
[    6.764245] RSP: 002b:00007fff1e93fa38 EFLAGS: 00000246 ORIG_RAX: 0000000000000139
[    6.764250] RAX: ffffffffffffffda RBX: 0000557837186240 RCX: 00007f23313128fd
[    6.764253] RDX: 0000000000000000 RSI: 00007f233187e05d RDI: 0000000000000006
[    6.764256] RBP: 00007f233187e05d R08: 0000000000000000 R09: 0000557836fb3cd0
[    6.764259] R10: 0000000000000006 R11: 0000000000000246 R12: 0000000000020000
[    6.764262] R13: 0000000000000000 R14: 000055783718af30 R15: 0000000000000000
[    6.764266]  </TASK>
[    6.764268] Modules linked in: processor_thermal_device_pci(+) processor_thermal_device processor_thermal_rfim processor_thermal_mbox processor_thermal_rapl fjes(-) acpi_cpufreq(-) intel_vsec pcc_cpufreq(-) intel_rapl_common intel_ipu6(OE+) i2c_dev igen6_edac thermal tiny_power_button button fan thinkpad_acpi ledtrig_audio platform_profile snd mei_vsc(OE) mei soundcore int3403_thermal int340x_thermal_zone soc_button_array ac ov2740(OE) v4l2_fwnode v4l2_async videodev mc intel_skl_int3472_tps68470 tps68470_regulator intel_skl_int3472_discrete intel_hid sparse_keymap int3400_thermal acpi_thermal_rel intel_pmc_core acpi_tad acpi_pad nft_fib_inet nft_fib_ipv4 nft_fib_ipv6 nft_fib nft_reject_inet nf_reject_ipv4 nf_reject_ipv6 nft_reject nft_ct nft_chain_nat nf_tables ip6table_nat ip6table_mangle ip6table_raw ip6table_security iptable_nat nf_nat nf_conntrack nf_defrag_ipv6 nf_defrag_ipv4 libcrc32c iptable_mangle iptable_raw vboxnetadp(O) iptable_security vboxnetflt(O)
[    6.764334]  nfnetlink rfkill ip6table_filter ip6_tables iptable_filter bpfilter vboxdrv(O) qrtr dmi_sysfs nls_iso8859_1 nls_cp437 vfat fat fuse configfs ip_tables x_tables ext4 mbcache jbd2 hid_sensor_custom hid_sensor_hub hid_generic intel_ishtp_hid i915 drm_buddy drm_display_helper crct10dif_pclmul xhci_pci crc32_pclmul xhci_pci_renesas crc32c_intel xhci_hcd cec ucsi_acpi nvme rc_core typec_ucsi intel_ish_ipc i2c_hid_acpi ghash_clmulni_intel aesni_intel crypto_simd cryptd serio_raw roles usbcore intel_ishtp nvme_core typec ttm wmi i2c_hid battery video pinctrl_tigerlake coretemp sg dm_multipath dm_mod scsi_dh_rdac scsi_dh_emc scsi_dh_alua msr efivarfs
[    6.764392] Unloaded tainted modules: acpi_cpufreq():1 fjes():1 pcc_cpufreq():1 acpi_cpufreq():1 fjes():1 pcc_cpufreq():1 acpi_cpufreq():1 fjes():1 pcc_cpufreq():1 acpi_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 fjes():1 acpi_cpufreq():1 pcc_cpufreq():1 fjes():1 pcc_cpufreq():1 acpi_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1
[    6.764460]  pcc_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 pcc_cpufreq():1 acpi_cpufreq():1 acpi_cpufreq():1
[    6.764479] CR2: 0000000000000304
[    6.764483] ---[ end trace 0000000000000000 ]---
[    6.764486] RIP: 0010:ipu_pci_probe.cold+0x3f0/0x90e [intel_ipu6]
[    6.764509] Code: 48 89 fa 48 85 ff 0f 84 b8 00 00 00 48 8b bf 10 03 00 00 48 85 ff 0f 84 ba 00 00 00 e8 56 b6 ff ff 48 8b 43 18 48 85 c0 74 11 <48> 8b b8 10 03 00 00 48 85 ff 74 05 e8 3c b6 ff ff 48 8b 53 20 48
[    6.764513] RSP: 0018:ffffb71440747b58 EFLAGS: 00010282
[    6.764516] RAX: fffffffffffffff4 RBX: ffff88b6c6789828 RCX: 0000000000000000
[    6.764519] RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
[    6.764522] RBP: ffff88b9e81bb000 R08: ffffb71440747af0 R09: ffff88b6c3f425a0
[    6.764525] R10: 0000000000000001 R11: 0000000000000001 R12: ffff88b9e81bb0d0
[    6.764527] R13: ffffb71445000000 R14: 00000000fffffff4 R15: ffffb71445000000
[    6.764531] FS:  00007f2330946b00(0000) GS:ffff88ba0f540000(0000) knlGS:0000000000000000
[    6.764535] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[    6.764538] CR2: 0000000000000304 CR3: 000000010b3e4002 CR4: 0000000000770ee0
[    6.764541] PKRU: 55555554
drogenlied commented 1 year ago
Hardware name: LENOVO 21CDCTO1WW/21CDCTO1WW, BIOS N3AET65W (1.30 ) 08/02/2022

I can confirm the null pointer dereference in ipu_pci_probe as well, same BIOS, slightly different laptop configuration, on Debian Bookworm/Sid, happens on kernels 5.18, 5.19 and custom compiled 6.0-rc.

For me, it has the nasty side effect that shutdown and suspend are broken afterwards.

norbusan commented 1 year ago

My wild guess is that it has to do with the patch int3472-support-independent-clock-and-LED-gpios-5.17+ included in this repo is not applied with dkms builds, and furthermore, it does not contain entries for the X1 Carbon:

--- a/drivers/platform/x86/intel/int3472/discrete.c
+++ b/drivers/platform/x86/intel/int3472/discrete.c
@@ -57,11 +57,17 @@ static const struct int3472_gpio_function_remap ov2680_gpio_function_remaps[] =

 static const struct int3472_sensor_config int3472_sensor_configs[] = {
        /* Lenovo Miix 510-12ISK - OV2680, Front */
-       { "GNDF140809R", { 0 }, ov2680_gpio_function_remaps },
+       { "GNDF140809R", { 0 }, ov2680_gpio_function_remaps, false },
        /* Lenovo Miix 510-12ISK - OV5648, Rear */
-       { "GEFF150023R", REGULATOR_SUPPLY("avdd", NULL), NULL },
+       { "GEFF150023R", REGULATOR_SUPPLY("avdd", NULL), NULL, false },
        /* Surface Go 1&2 - OV5693, Front */
-       { "YHCU", REGULATOR_SUPPLY("avdd", NULL), NULL },
+       { "YHCU", REGULATOR_SUPPLY("avdd", NULL), NULL, false },
+       /* Dell Latitude 9420 - OV01A1S, Front */
+       { "0BF111N3", { 0 }, NULL, true },
+       /* Dell Latitude 9420 - HM11B1, Front */
+       { "9BF123N3", { 0 }, NULL, true },
+       /* Lenovo X1 Yoga - OV2740, Front */
+       { "CJFLE23", { 0 }, NULL, true },
 };

I guess there some entry for the X1 Carbon (which I also have) is necessary!?

fhloston commented 1 year ago

Seing this null pointer dereference with the patch int3472-support-independent-clock-and-LED-gpios-5.17+ included.

norbusan commented 1 year ago

@fhloston On which hardware?

fhloston commented 1 year ago

@norbusan LENOVO 21CDS04A00/21CDS04A00, BIOS N3AET66W (1.31 ) 09/09/2022 X1 Yoga Gen7

fhloston commented 1 year ago
[   29.499244] platform INT3472:05: deferred probe pending
[  485.120306] intel-ipu6 intel-ipu: enabling device (0000 -> 0002)
[  485.120500] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[  485.120528] intel-ipu6 intel-ipu: physical base address 0x603c000000
[  485.120529] intel-ipu6 intel-ipu: mapped as: 0x000000004348259f
[  485.120532] intel-ipu6 intel-ipu: isys_base: 0xffffb82d49000000
[  485.120533] intel-ipu6 intel-ipu: psys_base: 0xffffb82d49000000
[  485.120654] intel-ipu6 intel-ipu: IPU in secure mode
[  485.120655] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[  485.120656] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[  485.121165] intel-ipu6 intel-ipu: ipu_buttress_ipc_reset: unexpected CSR 0x0
[  485.121669] intel-ipu6 intel-ipu: ipu_buttress_ipc_reset: unexpected CSR 0x0
[  485.122184] intel-ipu6 intel-ipu: ipu_buttress_ipc_reset: unexpected CSR 0x0
[  485.122700] intel-ipu6 intel-ipu: ipu_buttress_ipc_reset: unexpected CSR 0x0
[  485.123216] intel-ipu6 intel-ipu: ipu_buttress_ipc_reset: unexpected CSR 0x0
[  485.123732] intel-ipu6 intel-ipu: ipu_buttress_ipc_reset: unexpected CSR 0x0
[  485.124248] intel-ipu6 intel-ipu: ipu_buttress_ipc_reset: unexpected CSR 0x0
[  485.124764] intel-ipu6 intel-ipu: ipu_buttress_ipc_reset: unexpected CSR 0x0
[  485.125272] intel-ipu6 intel-ipu: ipu_buttress_ipc_reset: unexpected CSR 0x0
[  485.125785] intel-ipu6 intel-ipu: ipu_buttress_ipc_reset: unexpected CSR 0x0
[  485.134480] intel-ipu6 intel-ipu: ipu_buttress_ipc_reset:IPC_PEER_COMP_ACTIONS_RST_PHASE1 & IPC_PEER_COMP_ACTIONS_RST_PHASE2
[  485.136022] intel-ipu6 intel-ipu: ipu_buttress_ipc_reset: IPC_PEER_COMP_ACTIONS_RST_PHASE2
[  485.136340] intel-ipu6 intel-ipu: IPC reset done
[  485.136355] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[  485.147637] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[  485.147663] intel-ipu6 intel-ipu: FW version: 20220510
[  485.148154] BUG: kernel NULL pointer dereference, address: 00000000000002fc
[  485.148159] #PF: supervisor read access in kernel mode
[  485.148162] #PF: error_code(0x0000) - not-present page
[  485.148166] PGD 0 P4D 0 
[  485.148173] Oops: 0000 [#1] PREEMPT SMP NOPTI
[  485.148179] CPU: 0 PID: 3779 Comm: modprobe Tainted: P     U  W  OE      6.0.0 #1 
[  485.148186] Hardware name: LENOVO 21CDS04A00/21CDS04A00, BIOS N3AET66W (1.31 ) 09/09/2022
[  485.148189] RIP: 0010:ipu_pci_probe.cold+0x3fe/0x91c [intel_ipu6]
[  485.148230] Code: 48 89 fa 48 85 ff 0f 84 b8 00 00 00 48 8b bf 08 03 00 00 48 85 ff 0f 84 ba 00 00 00 e8 c6 b5 ff ff 48 8b 43 18 48 85 c0 74 11 <48> 8b b8 08 03 00 00 48 85 ff 74 05 e8 ac b5 ff ff 48 8b 53 20 48
[  485.148235] RSP: 0018:ffffb82d481bbbf0 EFLAGS: 00010282
[  485.148240] RAX: fffffffffffffff4 RBX: ffff95d50832f428 RCX: 0000000000000000
[  485.148244] RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
[  485.148246] RBP: ffff95d501700000 R08: ffff95d501700370 R09: 0000000000000024
[  485.148249] R10: 0000000000000001 R11: 0000000000000000 R12: ffff95d5017000d0
[  485.148252] R13: ffffb82d49000000 R14: 00000000fffffff4 R15: ffffb82d49000000
[  485.148256] FS:  00007f080dc00480(0000) GS:ffff95dc3f400000(0000) knlGS:0000000000000000
[  485.148260] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[  485.148264] CR2: 00000000000002fc CR3: 000000014f318003 CR4: 0000000000770ef0
[  485.148268] PKRU: 55555554
[  485.148271] Call Trace:
[  485.148276]  <TASK>
[  485.148285]  local_pci_probe+0x3e/0x80
[  485.148300]  pci_device_probe+0xc3/0x230
[  485.148309]  really_probe+0xdb/0x380
[  485.148316]  ? pm_runtime_barrier+0x50/0x90
[  485.148322]  __driver_probe_device+0x78/0x170
[  485.148327]  driver_probe_device+0x1f/0x90
[  485.148332]  __driver_attach+0xd1/0x1d0
[  485.148337]  ? __device_attach_driver+0x110/0x110
[  485.148341]  bus_for_each_dev+0x84/0xd0
[  485.148351]  bus_add_driver+0x1ae/0x200
[  485.148356]  driver_register+0x89/0xe0
[  485.148361]  ? 0xffffffffc09a4000
[  485.148365]  ipu_init+0x3b/0x1000 [intel_ipu6]
[  485.148387]  ? 0xffffffffc09a4000
[  485.148389]  do_one_initcall+0x56/0x220
[  485.148400]  do_init_module+0x4a/0x200
[  485.148408]  __do_sys_finit_module+0xac/0x120
[  485.148417]  do_syscall_64+0x37/0xc0
[  485.148427]  entry_SYSCALL_64_after_hwframe+0x63/0xcd
[  485.148435] RIP: 0033:0x7f080d303859
[  485.148440] Code: 08 44 89 e0 5b 41 5c c3 66 0f 1f 84 00 00 00 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 8b 0d 87 05 0f 00 f7 d8 64 89 01 48
[  485.148444] RSP: 002b:00007ffda1018d08 EFLAGS: 00000246 ORIG_RAX: 0000000000000139
[  485.148449] RAX: ffffffffffffffda RBX: 0000562ec4d89ff0 RCX: 00007f080d303859
[  485.148452] RDX: 0000000000000000 RSI: 0000562ec4d8a3c0 RDI: 0000000000000003
[  485.148455] RBP: 0000562ec4d8a3c0 R08: 0000000000000000 R09: 0000000000000014
[  485.148457] R10: 0000000000000003 R11: 0000000000000246 R12: 0000000000040000
[  485.148460] R13: 0000000000000000 R14: 0000562ec4d89f80 R15: 0000000000000015
[  485.148465]  </TASK>
[  485.148467] Modules linked in: intel_ipu6(OE+) nvme_fabrics ctr ccm rfcomm snd_seq_dummy snd_hrtimer snd_seq snd_seq_device qrtr cmac algif_hash algif_skcipher af_alg bnep snd_ctl_led snd_soc_skl_hda_dsp snd_soc_intel_hda_dsp_common snd_sof_probes snd_soc_hdac_hdmi snd_soc_dmic mei_hdcp intel_rapl_msr x86_pkg_temp_thermal intel_powerclamp coretemp kvm_intel kvm irqbypass rapl intel_cstate intel_uncore pcspkr serio_raw efi_pstore wmi_bmof snd_hda_codec_hdmi snd_hda_codec_realtek snd_hda_codec_generic snd_sof_pci_intel_tgl snd_sof_intel_hda_common soundwire_intel soundwire_generic_allocation soundwire_cadence snd_sof_intel_hda snd_sof_pci snd_sof_xtensa_dsp snd_sof snd_sof_utils snd_soc_hdac_hda snd_hda_ext_core snd_soc_acpi_intel_match snd_soc_acpi snd_soc_core snd_compress soundwire_bus iwlmvm snd_hda_intel snd_intel_dspcfg snd_intel_sdw_acpi mac80211 snd_hda_codec btusb libarc4 snd_hda_core btrtl snd_hwdep mei_me btbcm snd_pcm btintel btmtk snd_timer mei iwlwifi bluetooth joydev
[  485.148567]  cfg80211 jitterentropy_rng hid_multitouch sha512_ssse3 sha512_generic drbg hid_sensor_gyro_3d hid_sensor_accel_3d hid_sensor_trigger ansi_cprng hid_sensor_iio_common industrialio_triggered_buffer kfifo_buf ecdh_generic ecc industrialio processor_thermal_device_pci processor_thermal_device processor_thermal_rfim ucsi_acpi processor_thermal_mbox typec_ucsi processor_thermal_rapl intel_rapl_common nxp_nci_i2c roles nxp_nci typec nci thinkpad_acpi nfc nvram platform_profile ledtrig_audio snd soundcore rfkill int3403_thermal int340x_thermal_zone soc_button_array ac evdev intel_skl_int3472_tps68470 intel_skl_int3472_discrete intel_hid sparse_keymap int3400_thermal acpi_thermal_rel intel_pmc_core acpi_tad acpi_pad zfs(POE) zunicode(POE) zzstd(OE) zlua(OE) zavl(POE) icp(POE) nls_ascii nls_cp437 vfat fat zcommon(POE) znvpair(POE) spl(OE) v4l2loopback(OE) videodev mc msr parport_pc ppdev lp parport fuse configfs efivarfs ip_tables x_tables autofs4 ext4 crc16 mbcache jbd2
[  485.148671]  crc32c_generic dm_crypt dm_mod hid_sensor_custom hid_sensor_hub intel_ishtp_hid wacom crc32_pclmul crc32c_intel usbhid hid_generic ghash_clmulni_intel i915 xhci_pci drm_buddy nvme i2c_algo_bit xhci_hcd nvme_core drm_display_helper t10_pi cec rc_core crc64_rocksoft_generic crc64_rocksoft ttm crc_t10dif usbcore crct10dif_generic aesni_intel drm_kms_helper intel_lpss_pci i2c_hid_acpi crct10dif_pclmul i2c_i801 i2c_hid intel_ish_ipc intel_lpss crc64 crypto_simd psmouse cryptd thunderbolt drm i2c_smbus idma64 intel_ishtp usb_common crct10dif_common hid wmi button fan video battery
[  485.148741] CR2: 00000000000002fc
[  485.148745] ---[ end trace 0000000000000000 ]---
[  485.888630] RIP: 0010:ipu_pci_probe.cold+0x3fe/0x91c [intel_ipu6]
[  485.888654] Code: 48 89 fa 48 85 ff 0f 84 b8 00 00 00 48 8b bf 08 03 00 00 48 85 ff 0f 84 ba 00 00 00 e8 c6 b5 ff ff 48 8b 43 18 48 85 c0 74 11 <48> 8b b8 08 03 00 00 48 85 ff 74 05 e8 ac b5 ff ff 48 8b 53 20 48
[  485.888656] RSP: 0018:ffffb82d481bbbf0 EFLAGS: 00010282
[  485.888658] RAX: fffffffffffffff4 RBX: ffff95d50832f428 RCX: 0000000000000000
[  485.888659] RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
[  485.888660] RBP: ffff95d501700000 R08: ffff95d501700370 R09: 0000000000000024
[  485.888674] R10: 0000000000000001 R11: 0000000000000000 R12: ffff95d5017000d0
[  485.888674] R13: ffffb82d49000000 R14: 00000000fffffff4 R15: ffffb82d49000000
[  485.888675] FS:  00007f080dc00480(0000) GS:ffff95dc3f400000(0000) knlGS:0000000000000000
[  485.888677] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[  485.888694] CR2: 00000000000002fc CR3: 000000014f318003 CR4: 0000000000770ef0
[  485.888695] PKRU: 55555554
jeffreyfq commented 1 year ago

Similar on HP Spectre x360 16-f1010TX (i7-1260P) @ 5.19.0-15-generic and (K)Ubuntu 20.10:

[ 3594.980687] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2) [ 3594.980793] intel-ipu6 intel-ipu: physical base address 0x612c000000 [ 3594.980796] intel-ipu6 intel-ipu: mapped as: 0x000000001aa49395 [ 3594.980957] intel-ipu6 intel-ipu: IPU in secure mode [ 3594.980962] intel-ipu6 intel-ipu: IPU secure touch = 0x80000000 [ 3594.980965] intel-ipu6 intel-ipu: IPU camera mask = 0x0 [ 3594.998356] intel-ipu6 intel-ipu: IPC reset done [ 3594.998369] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin [ 3595.030262] intel-ipu6 intel-ipu: FW version: 20211011 [ 3595.030954] BUG: kernel NULL pointer dereference, address: 00000000000002fc [ 3595.030967] #PF: supervisor read access in kernel mode [ 3595.030973] #PF: error_code(0x0000) - not-present page [ 3595.030980] PGD 0 P4D 0 [ 3595.030991] Oops: 0000 [#1] PREEMPT SMP NOPTI [ 3595.031003] CPU: 8 PID: 52603 Comm: modprobe Tainted: G U W OE 5.19.0-15-generic #15-Ubuntu [ 3595.031016] Hardware name: HP HP Spectre x360 2-in-1 Laptop 16-f1xxx/891D, BIOS F.05 03/23/2022 [ 3595.031022] RIP: 0010:ipu_pci_probe.cold+0x3fd/0x8e7 [intel_ipu6] [ 3595.031083] Code: 48 89 fa 48 85 ff 0f 84 b8 00 00 00 48 8b bf 08 03 00 00 48 85 ff 0f 84 ba 00 00 00 e8 b7 ac ff ff 49 8b 46 18 48 85 c0 74 11 <48> 8b b8 08 03 00 00 48 85 ff 74 05 e8 9d ac ff ff 49 8b 56 20 48 [ 3595.031092] RSP: 0018:ffffbc9e09cdb9b8 EFLAGS: 00010282 [ 3595.031102] RAX: fffffffffffffff4 RBX: ffff9e01c2d47000 RCX: 0000000000000000 [ 3595.031109] RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000 [ 3595.031115] RBP: ffffbc9e09cdba00 R08: ffffbc9e09cdb950 R09: ffff9e01d2e4ea80 [ 3595.031121] R10: 0000000000000001 R11: 0000000000000000 R12: ffff9e01c2d470d0 [ 3595.031127] R13: ffff9e01d2e4eaa8 R14: ffff9e076ac35428 R15: 00000000fffffff4 [ 3595.031134] FS: 00007f0b64866040(0000) GS:ffff9e094fa00000(0000) knlGS:0000000000000000 [ 3595.031142] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 3595.031148] CR2: 00000000000002fc CR3: 0000000204c34003 CR4: 0000000000770ee0 [ 3595.031156] PKRU: 55555554 [ 3595.031161] Call Trace: [ 3595.031167] [ 3595.031182] local_pci_probe+0x44/0x80 [ 3595.031200] pci_call_probe+0x55/0x180 [ 3595.031213] pci_device_probe+0x84/0x110 [ 3595.031223] really_probe+0x1ce/0x3a0 [ 3595.031238] driver_probe_device+0x11b/0x190 [ 3595.031250] driver_probe_device+0x24/0xd0 [ 3595.031262] driver_attach+0xd8/0x200 [ 3595.031274] ? __device_attach_driver+0x120/0x120 [ 3595.031286] bus_for_each_dev+0x79/0xc0 [ 3595.031298] driver_attach+0x1e/0x30 [ 3595.031309] bus_add_driver+0x178/0x220 [ 3595.031320] driver_register+0x8f/0xf0 [ 3595.031333] ? 0xffffffffc0a8f000 [ 3595.031340] __pci_register_driver+0x62/0x70 [ 3595.031348] ipu_init+0x3f/0x1000 [intel_ipu6] [ 3595.031382] ? 0xffffffffc0a8f000 [ 3595.031386] do_one_initcall+0x47/0x210 [ 3595.031398] ? kmem_cache_alloc_trace+0x181/0x300 [ 3595.031408] ? do_init_module+0x27/0x200 [ 3595.031418] do_init_module+0x50/0x200 ....


Btw, I tried with the new kernel: ~~Error seems to be gone after power off/on of the system and after installing 6.0.0-060000-generic. There is this, not sure what it means, or if it is important: RIP: 0010:ipu_pci_probe.cold+0x404/0x904 [intel_ipu6]~~

Same error for kernel 6.0 and 6.1rc1 (dmesg_ipu6.txt)

Camera/shutdown/standby not working, but maybe related to other issues with the a370m Intel driver, as the whole dmesg output looks like a Christmas tree

vicamo commented 1 year ago

Similar on HP Spectre x360 16-f1010TX (i7-1260P) @ 5.19.0-15-generic and (K)Ubuntu 20.10:

Hi, wondering if https://launchpad.net/~canonical-hwe-team/+archive/ubuntu/intermediate-kernel works for you:

$ sudo add-apt-repository ppa:canonical-hwe-team/intermediate-kernel
$ sudo apt install linux-image-generic linux-modules-ipu6-generic linux-modules-ivsc-generic
jeffreyfq commented 1 year ago

Similar on HP Spectre x360 16-f1010TX (i7-1260P) @ 5.19.0-15-generic and (K)Ubuntu 20.10:

Hi, wondering if https://launchpad.net/~canonical-hwe-team/+archive/ubuntu/intermediate-kernel works for you:

$ sudo add-apt-repository ppa:canonical-hwe-team/intermediate-kernel
$ sudo apt install linux-image-generic linux-modules-ipu6-generic linux-modules-ivsc-generic

Thanks for your suggestion. I tried it out, but seems to generate the same error. This is the dmesg output, in case it can be useful: 5.19.0-9021-generic_dmesg.txt


The point is, I tried something crazy, I merged the driver with the current next branch (development branch). It was a little bit tricky, as the interface changed even more (it seems media entities had previously only one pipeline. But in the new kernel they have multiple pods that can have a pipeline each. A compatibility function exists that goes through all pods and returns the first pipeline that it can find. As it is assumes that usually there is only one pipeline involved. I changed the code to call this utility function. Also I looped through the pods to find the pipeline during closing/deinitalization. But I only close only the first as in the utility function. As I assume that the camera driver only uses one pipeline, I have no idea if this is ok?) This is the full diff between kernel branch next-20221019 and the integrated/modified driver in my local branch: gitdiff-kernel.txt Kernel compiles but still has the same error! To regenerate the next-kernel something like this should work:

git clone https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git  
cd linux  
git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
git fetch linux-next
git fetch --tags linux-next
git checkout master
git remote update
git checkout -b hp_spectre_i7-1260p next-20221019
git apply <insert ~/Download/ or where the file is>gitdiff-kernel.txt

Then you have to add the .config file, mine was this: config.txt Then, to build the kernel:

make -j 12
make deb-pkg LOCALVERSION=-ipu6mod -j 12

After this you can install the kernel:

cd ..
sudo dpkg -i linux-libc-dev_6.1.0-rc1-next-20221019-ipu6mod-1_amd64.deb
sudo dpkg -i linux-image-6.1.0-rc1-next-20221019-ipu6mod_6.1.0-rc1-next-20221019-ipu6mod-1_amd64.deb 

But I was looking through the diffs and saw that the camera driver files are most probably not in the latest version of the ipu6 repository, i will try to change this and see what happens. (not sure if the ipu driver was already loading the camera driver while it got stuck with the error, or if it was still in an earlier state).

In case I find something out I will post it. Actually, I am not familiar with kernel development and the media subsystem in particular, I actually not even have a clue what the pipeline (image stream from senor to memory, I assume) & pods are, so I am not certain if my modifications for the next-20221019 are ok, but maybe it can be useful for someone.

jwrdegoede commented 1 year ago

The specific crash mentioned here is fixed by: https://github.com/intel/ipu6-drivers/pull/58/commits/5a36712499e83cdf1ec6b89e13df573e09ebe565

But fixing it just results in somewhat related crashes further down the road, note I have fixes for those too, see #58 in general. But you also need some other changes to get things to actually work on Alderlake Lenovo Thinkpads let me copy and paste my comment from #55 about this:

I have been working on making the ipu6-driver stack work on a Lenovo Thinkpad X1 Yoga gen 7 (alderlake) with a 6.0 kernel and using the INT3472 mainline kernel driver for power-control.

I have submitted the following fixes for this, I believe these should also fix things not working on the X1 Nano Gen2:

https://github.com/intel/ipu6-drivers/pull/58 https://github.com/intel/ivsc-driver/pull/24 https://lore.kernel.org/linux-acpi/20221022150722.31787-1-hdegoede@redhat.com/

Note this relies on the mainline kernel itself also being build with the 2 patches from ipu6-drivers/patch. And if you look at the int3472-support-independent-clock-and-LED-gpios-5.17+.patch you will see it adds an entry for the Yoga Gen 7 to the int3472_sensor_configs[] table. You may need to add a copy of that entry with the sensor-module-name used for the main camera on your model. Note the IR camera is not supported yet.

fhloston commented 1 year ago

I can confirm that applying the before mentioned fixes i can see video from the webcam for the first time!

Thank you, great job @jwrdegoede

sudo -E gst-launch-1.0 icamerasrc buffer-count=7 ! video/x-raw,format=NV12,width=1280,height=720 ! videoconvert ! ximagesink

Sadly v4l2-relayd does not work for me yet.

@jwrdegoede how do you then use the camera?

jwrdegoede commented 1 year ago

@jwrdegoede how do you then use the camera?

I have not gotten around to trying v4l2-relayd yet. I was happy to have gst-launch work after a marathon coding session involving all the kernel fixes and then called it a day :) I might give v4l2-relayd a shot coming Tuesday.

jwrdegoede commented 1 year ago

BTW did you have to add an entry to the int3472_sensor_configs[] table ?

jeffreyfq commented 1 year ago

BTW did you have to add an entry to the int3472_sensor_configs[] table ?

I looks like that I do not need to add an entry to int3472_sensor_configs[] for the HP Spectre x360 16-f1010TX (i7-1260P)

I compiled the kernel now with all patches applied, seems that I am almost there :)

This looks to me as if there are some HAL-driver related files missing, but it seems that the device is available.

sudo -E gst-launch-1.0 icamerasrc device-name=ov13b10-wf af-mode=2 ! video/x-raw,format=NV12,width=1280,height=720 ! videoconvert ! ximagesink
Setting pipeline to PAUSED ...
[10-24 14:42:37.962] CamHAL[INF] aiqb file name ov13b10.aiqb
[10-24 14:42:37.962] CamHAL[ERR] there is no aiqb file:ov13b10
[10-24 14:42:37.962] CamHAL[INF] aiqb file name ov13b10.aiqb
[10-24 14:42:37.962] CamHAL[ERR] there is no aiqb file:ov13b10
[10-24 14:42:37.962] CamHAL[INF] aiqb file name ov8856.aiqb
[10-24 14:42:37.962] CamHAL[ERR] there is no aiqb file:ov8856
[10-24 14:42:37.962] CamHAL[INF] aiqb file name ov8856.aiqb
[10-24 14:42:37.962] CamHAL[ERR] there is no aiqb file:ov8856
[10-24 14:42:37.962] CamHAL[INF] aiqb file name ov01a10.aiqb
[10-24 14:42:37.962] CamHAL[INF] aiqb file name ov01a10.aiqb
[10-24 14:42:37.962] CamHAL[INF] aiqb file name ov01a10.aiqb
[10-24 14:42:37.962] CamHAL[INF] aiqb file name ov01a10.aiqb
[10-24 14:42:37.962] CamHAL[INF] aiqb file name OV02C10_1BG203N3_ADL.aiqb
[10-24 14:42:37.963] CamHAL[INF] aiqb file name OV02C10_1BG203N3_ADL.aiqb
[10-24 14:42:37.963] CamHAL[INF] aiqb file name OV2740_CJFLE23_ADL.aiqb
[10-24 14:42:37.963] CamHAL[INF] aiqb file name OV2740_CJFLE23_ADL.aiqb
[10-24 14:42:37.963] CamHAL[INF] aiqb file name HM2170_1SG205N3_ADL.aiqb
[10-24 14:42:37.963] CamHAL[INF] aiqb file name HM2170_1SG205N3_ADL.aiqb
[10-24 14:42:37.963] CamHAL[INF] aiqb file name hi556.aiqb
[10-24 14:42:37.963] CamHAL[INF] aiqb file name hi556.aiqb
[10-24 14:42:37.963] CamHAL[INF] aiqb file name ov01a1s.aiqb
[10-24 14:42:37.963] CamHAL[INF] aiqb file name ov01a1s.aiqb
[10-24 14:42:37.963] CamHAL[ERR] Failed to find DevName for cameraId: 0, get video node: ov13b10 , devname: /dev/v4l-subdev1
[10-24 14:42:37.965] CamHAL[ERR] MediaControl init failed
Failed to set pipeline to PAUSED.
Setting pipeline to NULL ...
Freeing pipeline ...

same for the other command: sudo -E gst-launch-1.0 icamerasrc buffer-count=7 ! video/x-raw,format=NV12,width=1280,height=720 ! videoconvert ! ximagesin

Btw, is there any easy way to list the acpi ensor-module-names in the console?

fhloston commented 1 year ago

BTW did you have to add an entry to the int3472_sensor_configs[] table ?

No, I just applied your mentioned patches plus an unrelated i915 patch. Also X1 Yoga gen7 here.

drogenlied commented 1 year ago

@fhloston was that i915 patch useful?

@jeffreyfq There are multiple names that are necessary for sensor setup.

The _HID and _DDN from ACPI can be obtained easily and are used in the camera sensor driver. On my X1 Yoga Gen 7, the cameras have HIDs like INT3474 and that name can be found in drivers/media/i2c/ov2740.c. Script to find these (needs acpica-tools for iasl):

cat /sys/firmware/acpi/tables/DSDT > dsdt.dat
iasl -tc dsdt.dsl
grep -A9 "Device (CAM" dsdt.dsl

Then there is a model string from ACPI _DSM() of some device that is used by int3472 and compared to the list in int3472_sensor_configs[].

Maybe it is contained in the DSDT, but not verbatim, so I just added dev_info(int3472->dev, "Sensor _DSM: %s\n", obj->string.pointer); to skl_int3472_get_sensor_module_config(...) and saved the work of figuring out where that string ultimately comes from.

As a sort of long shot I added this to int3472_sensor_configs[]

    /* Lenovo ThinkPad X1 Yoga Gen7 - OV9234 monochromatic sensor? */
    { "6BF115T2", { 0 }, NULL, true },

and changed ov9734_acpi_ids[] in drivers/media/i2c/ov9734.c to

    { "OVTI9234", },
    { "OVTI9734", },
    { "INT3471", },

but the ov9734 sensor driver does not like its monochrome sibling variant and fails with -EINVAL during probing. No crash though.

jeffreyfq commented 1 year ago

@jeffreyfq There are multiple names that are necessary for sensor setup.

Thank you for your help and the detailed instructions, I was able to read out the ACPI data:

        Device (CAM0)
        {
            Name (_HID, "INT3471")  // _HID: Hardware ID
            Name (_DDN, "IMX135-CRDG2")  // _DDN: DOS Device Name
            Name (_UID, "0")  // _UID: Unique ID
            Name (_DEP, Package (0x01)  // _DEP: Dependencies
            {
                PMIC
            })
            Name (_PLD, Package (0x01)  // _PLD: Physical Location of Device
--
        Device (CAM1)
        {
            Name (_HID, "INT3474")  // _HID: Hardware ID
            Name (_DDN, "OV2740-CRDG2")  // _DDN: DOS Device Name
            Name (_UID, "0")  // _UID: Unique ID
            Name (_DEP, Package (0x01)  // _DEP: Dependencies
            {
                ^^I2C2.PMIC
            })
            Name (_PLD, Package (0x01)  // _PLD: Physical Location of Device

So I have the device INT3474 with OV2740-CRDG2 and a device INT3471 with sensor IMX135-CRDG2.

It seems that OV2740 and IMX135 (for imx135 there is seemingly no driver available in drivers/media/i2c/), both are RGB sensors, kind of strange, I thought the IR sensor would be grayscale.

Then I checked, the driver should be fine, there is my _HID name INT3474 in the driver structure ov2740_acpi_ids already.

So next I will compile the kernel module with some print statements to get the _DSM name to add it to the int3472_sensor_configs[]

I still have the _DDN name, do I have to add this name also somewhere? Or is it just relevant to figure out which driver/sensor type it is (e.g. in my case OV2740)?

I did it: Mine is

[    5.480086] int3472-discrete INT3472:01: Sensor _DSM: CJFKE26
[    5.486444] int3472-discrete INT3472:02: Sensor _DSM: CJFKE26

for HP Spectre x360 16-f1xxx (i7-1260P, igpu+ dgpu a370m)


Update: I booted now with the modified kernel modules. Dmesg tells me this now:

[    5.181779] systemd-journald[492]: Received client request to flush runtime journal.
[    5.254716] intel_skl_int3472_discrete: loading out-of-tree module taints kernel.
[    5.257730] int3472-discrete INT3472:01: Sensor _DSM: CJFKE26
[    5.258480] int3472-discrete INT3472:01: No supply name defined
[    5.258501] int3472-discrete INT3472:01: error -ENODEV: Failed to map regulator to sensor
[    5.264201] Consider using thermal netlink events interface
[    5.264263] int3472-discrete INT3472:02: Sensor _DSM: CJFKE26
[    5.264452] input: Intel HID events as /devices/platform/INTC1070:00/input/input20
[    5.264873] int3472-discrete INT3472:02: No supply name defined
[    5.264893] int3472-discrete INT3472:02: error -ENODEV: Failed to map regulator to sensor

Update2: I figured out that the error No supply name defined is caused because the entry in int3472_sensor_configs has to include some definition like e.g. REGULATOR_SUPPLY("avdd", NULL), like this:

...
/* HP Spectre x360 16-f1xxx */
{ "CJFKE26", REGULATOR_SUPPLY("avdd", NULL), NULL, true },
...

Actually I dont know what the fourth argument -true- means, did not try with false yet.

Now something happens, but also new errors appear and also the dmeg is messy (includes intel vsc not ready):

jfq@jeffreyhp:~$ sudo -E gst-launch-1.0 icamerasrc buffer-count=7 ! video/x-raw,format=NV12,width=1280,height=720 ! videoconvert ! ximagesink
[sudo] password for jfq: 
Setting pipeline to PAUSED ...
[10-25 21:30:31.255] CamHAL[INF] aiqb file name ov13b10.aiqb
[10-25 21:30:31.255] CamHAL[ERR] there is no aiqb file:ov13b10
[10-25 21:30:31.255] CamHAL[INF] aiqb file name ov13b10.aiqb
[10-25 21:30:31.255] CamHAL[ERR] there is no aiqb file:ov13b10
[10-25 21:30:31.255] CamHAL[INF] aiqb file name ov8856.aiqb
[10-25 21:30:31.255] CamHAL[ERR] there is no aiqb file:ov8856
[10-25 21:30:31.255] CamHAL[INF] aiqb file name ov8856.aiqb
[10-25 21:30:31.255] CamHAL[ERR] there is no aiqb file:ov8856
[10-25 21:30:31.255] CamHAL[INF] aiqb file name ov01a10.aiqb
[10-25 21:30:31.256] CamHAL[INF] aiqb file name ov01a10.aiqb
[10-25 21:30:31.256] CamHAL[INF] aiqb file name ov01a10.aiqb
[10-25 21:30:31.256] CamHAL[INF] aiqb file name ov01a10.aiqb
[10-25 21:30:31.256] CamHAL[INF] aiqb file name OV02C10_1BG203N3_ADL.aiqb
[10-25 21:30:31.257] CamHAL[INF] aiqb file name OV02C10_1BG203N3_ADL.aiqb
[10-25 21:30:31.257] CamHAL[INF] aiqb file name OV2740_CJFLE23_ADL.aiqb
[10-25 21:30:31.258] CamHAL[INF] aiqb file name OV2740_CJFLE23_ADL.aiqb
[10-25 21:30:31.258] CamHAL[INF] aiqb file name HM2170_1SG205N3_ADL.aiqb
[10-25 21:30:31.259] CamHAL[INF] aiqb file name HM2170_1SG205N3_ADL.aiqb
[10-25 21:30:31.259] CamHAL[INF] aiqb file name hi556.aiqb
[10-25 21:30:31.260] CamHAL[INF] aiqb file name hi556.aiqb
[10-25 21:30:31.260] CamHAL[INF] aiqb file name ov01a1s.aiqb
[10-25 21:30:31.261] CamHAL[INF] aiqb file name ov01a1s.aiqb
[10-25 21:30:31.261] CamHAL[ERR] Failed to find DevName for cameraId: 0, get video node: ov13b10 , devname: /dev/v4l-subdev1
Pipeline is live and does not need PREROLL ...
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
[10-25 21:30:31.266] CamHAL[ERR] Get entity fail for calling getEntityById
[10-25 21:30:31.266] CamHAL[ERR] Get entity fail for calling getEntityById
[10-25 21:30:31.266] CamHAL[ERR] setup Link ov13b10  [-1:0] ==> Intel IPU6 CSI-2  [-1x0] enable 1 failed.
[10-25 21:30:31.266] CamHAL[ERR] set MediaCtlConf McLink failed: ret = -1
[10-25 21:30:31.266] CamHAL[ERR] set up mediaCtl failed
[10-25 21:30:31.266] CamHAL[ERR] @configure Device Configure failed
[10-25 21:30:31.266] CamHAL[ERR] failed to config streams.
ERROR: from element /GstPipeline:pipeline0/Gstcamerasrc:camerasrc0: src pad: Internal data flow error.
Additional debug info:
gstcambasesrc.cpp(3143): gst_cam_base_src_loop (): /GstPipeline:pipeline0/Gstcamerasrc:camerasrc0:
streaming task paused, reason not-negotiated (-4)
Execution ended after 0:00:00.003470888
Setting pipeline to NULL ...
Freeing pipeline ...

I loaded the v4l2 loopback kernel module as well. There are even video devices /dev/videoX, but they dont work as well. So it looks like almost, I guess I may have to recompile everything from scratch, to make sure I did not mess anything up with all the modifications and the kernel version. But for now I may give up :D

btw: this is the output of v4l2-ctl --all

Driver Info:
        Driver name      : intel-ipu6-isys
        Card type        : ipu6
        Bus info         : PCI:pci:pci0000:00
        Driver version   : 6.1.0
        Capabilities     : 0x84201000
                Video Capture Multiplanar
                Streaming
                Extended Pix Format
                Device Capabilities
        Device Caps      : 0x04201000
                Video Capture Multiplanar
                Streaming
                Extended Pix Format
Media Driver Info:
        Driver name      : intel-ipu6-isys
        Model            : ipu6
        Serial           : 
        Bus info         : pci:pci0000:00
        Media version    : 6.1.0
        Hardware revision: 0x00000000 (0)
        Driver version   : 6.1.0
Interface Info:
        ID               : 0x0300001e
        Type             : V4L Video
Entity Info:
        ID               : 0x0000001c (28)
        Name             : Intel IPU6 BE SOC capture 0
        Function         : V4L2 I/O
        Pad 0x0100001d   : 0: Sink, Must Connect
          Link 0x02000020: from remote pad 0x100001b of entity 'Intel IPU6 CSI2 BE SOC 0' (Video Interface Bridge): Data, Dynamic
Priority: 2
Video input : 0 (camera: ok)
Format Video Capture Multiplanar:
        Width/Height      : 5120/3840
        Pixel Format      : 'YUYV' (YUYV 4:2:2)
        Field             : None
        Number of planes  : 1
        Flags             : 
        Colorspace        : Raw
        Transfer Function : Default
        YCbCr/HSV Encoding: Default
        Quantization      : Default
        Plane 0           :
           Bytes per Line : 10240
           Size Image     : 39331840

User Controls

        isys_be_soc_compression 0x00981983 (bool)   : default=0 value=0
fhloston commented 1 year ago

@fhloston was that i915 patch useful? @drogenlied yes, trace is gone after applying it (https://gitlab.freedesktop.org/drm/intel/-/issues/6592)

You seem to have another secondary sensor in your X1 Yoga Gen7 than me:

` Device (CAM0) { Name (_HID, "INT3471") // _HID: Hardware ID Name (_DDN, "IMX135-CRDG2") // _DDN: DOS Device Name Name (_UID, "0") // _UID: Unique ID Name (_DEP, Package (0x01) // _DEP: Dependencies { PMIC }) Name (_PLD, Package (0x01) // _PLD: Physical Location of Device

    Device (CAM1)
    {
        Name (_HID, "INT3474")  // _HID: Hardware ID
        Name (_DDN, "OV2740-CRDG2")  // _DDN: DOS Device Name
        Name (_UID, "0")  // _UID: Unique ID
        Name (_DEP, Package (0x01)  // _DEP: Dependencies
        {
            ^^I2C2.PMIC
        })
        Name (_PLD, Package (0x01)  // _PLD: Physical Location of Device`

Sorry for weird formatting :/

Seems my X1 Yoga Gen7 has the same camera setup like @jeffreyfq 's HP Spectre x360.

@jeffreyfq have you tried setting the device name explicitly with: sudo -E gst-launch-1.0 icamerasrc device-name=ov2740-uf buffer-count=7 ! video/x-raw,format=NV12,width=1280,height=720 ! videoconvert ! ximagesink

jeffreyfq commented 1 year ago

@fhloston I just tried now, but results in the same error. But considering that my hardware is so similar to the X1 Yoga Gen7, like in your case, I guess it has to work for me too. I guess to be on the safe side, I have to start over and patch the kernel/modules from a fresh checkout, could be possible that I messed up something.

this is the output (does not cause new dmesg errors):

Setting pipeline to PAUSED ...
[10-26 23:22:03.361] CamHAL[INF] aiqb file name ov13b10.aiqb
[10-26 23:22:03.361] CamHAL[ERR] there is no aiqb file:ov13b10
[10-26 23:22:03.361] CamHAL[INF] aiqb file name ov13b10.aiqb
[10-26 23:22:03.361] CamHAL[ERR] there is no aiqb file:ov13b10
[10-26 23:22:03.361] CamHAL[INF] aiqb file name ov8856.aiqb
[10-26 23:22:03.361] CamHAL[ERR] there is no aiqb file:ov8856
[10-26 23:22:03.361] CamHAL[INF] aiqb file name ov8856.aiqb
[10-26 23:22:03.361] CamHAL[ERR] there is no aiqb file:ov8856
[10-26 23:22:03.361] CamHAL[INF] aiqb file name ov01a10.aiqb
[10-26 23:22:03.362] CamHAL[INF] aiqb file name ov01a10.aiqb
[10-26 23:22:03.362] CamHAL[INF] aiqb file name ov01a10.aiqb
[10-26 23:22:03.362] CamHAL[INF] aiqb file name ov01a10.aiqb
[10-26 23:22:03.362] CamHAL[INF] aiqb file name OV02C10_1BG203N3_ADL.aiqb
[10-26 23:22:03.362] CamHAL[INF] aiqb file name OV02C10_1BG203N3_ADL.aiqb
[10-26 23:22:03.362] CamHAL[INF] aiqb file name OV2740_CJFLE23_ADL.aiqb
[10-26 23:22:03.362] CamHAL[INF] aiqb file name OV2740_CJFLE23_ADL.aiqb
[10-26 23:22:03.362] CamHAL[INF] aiqb file name HM2170_1SG205N3_ADL.aiqb
[10-26 23:22:03.363] CamHAL[INF] aiqb file name HM2170_1SG205N3_ADL.aiqb
[10-26 23:22:03.363] CamHAL[INF] aiqb file name hi556.aiqb
[10-26 23:22:03.363] CamHAL[INF] aiqb file name hi556.aiqb
[10-26 23:22:03.363] CamHAL[INF] aiqb file name ov01a1s.aiqb
[10-26 23:22:03.363] CamHAL[INF] aiqb file name ov01a1s.aiqb
[10-26 23:22:03.363] CamHAL[ERR] Failed to find DevName for cameraId: 7, get video node: ov2740 , devname: /dev/v4l-subdev1
Pipeline is live and does not need PREROLL ...
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
[10-26 23:22:03.370] CamHAL[ERR] Get entity fail for calling getEntityById
[10-26 23:22:03.370] CamHAL[ERR] Get entity fail for calling getEntityById
[10-26 23:22:03.370] CamHAL[ERR] setup Link ov2740  [-1:0] ==> Intel IPU6 CSI-2  [-1x0] enable 1 failed.
[10-26 23:22:03.370] CamHAL[ERR] set MediaCtlConf McLink failed: ret = -1
[10-26 23:22:03.370] CamHAL[ERR] set up mediaCtl failed
[10-26 23:22:03.370] CamHAL[ERR] @configure Device Configure failed
[10-26 23:22:03.370] CamHAL[ERR] failed to config streams.
ERROR: from element /GstPipeline:pipeline0/Gstcamerasrc:camerasrc0: src pad: Internal data flow error.
Additional debug info:
gstcambasesrc.cpp(3143): gst_cam_base_src_loop (): /GstPipeline:pipeline0/Gstcamerasrc:camerasrc0:
streaming task paused, reason not-negotiated (-4)
Execution ended after 0:00:00.004552897
Setting pipeline to NULL ...
Freeing pipeline ...
polair commented 1 year ago

@jeffreyfq This is the same error I have with the OV2740 in the Nano X1 Gen2 that I've filed a bug report on ( #55 )

I haven't been able to get further than you and like you I'm a little fatigued by it. I do have one tidbit of info though. Launching your gstreamer command with GST_DEBUG env var set can get you a lot more information. Something like:

GST_DEBUG=4 sudo -E gst-launch-1.0 icamerasrc buffer-count=7 device-name=ov2740-uf ! video/x-raw,format=YUY2,width=1280,height=720 ! v4l2sink device=/dev/video1

I was tracking this down to missing modules or a conflict with the ivsc-driver package. dmesg | grep vsc doesn't produce any output for me however.

@fhloston What does dmesg | grep vsc say for you when it's working? Can you give a set of outputs, the v4l2 camera information and dmesg | grep ipu and lsmod | grep 'ipu|mei|vsc'. Would be very helpful <3

jwrdegoede commented 1 year ago

You seem to have another secondary sensor in your X1 Yoga Gen7 than me

Note that the presence of the sensor in the DSDT does not say everything, there are multiple sensor entries and only some actually are "active", this is governed by the _STA method of the ACPI device returning 0xf (present) or 0 (not present).

To really see which sensors you have, first build the main kernel with the int3472-gpio + https://lore.kernel.org/linux-acpi/20221022150722.31787-1-hdegoede@redhat.com/ patches. After this the sensors should show up under in ls /sys/bus/i2c/devices for me the 2 sensors are i2c-INT3474:01 which is the ov2740 normal sensor and i2c-OVTI9234:00 which is an ov9234 monochrome sensor which is used as ir-sensor here.

fhloston commented 1 year ago

@fhloston What does dmesg | grep vsc say for you when it's working? Can you give a set of outputs, the v4l2 camera information and dmesg | grep ipu and lsmod | grep 'ipu|mei|vsc'. Would be very helpful <3

# dmesg | grep vsc
# dmesg | grep ipu
[   28.450481] intel-ipu6 intel-ipu: enabling device (0000 -> 0002)
[   28.453087] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   28.454991] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   28.454993] intel-ipu6 intel-ipu: mapped as: 0x0000000061c5c228
[   28.460159] intel-ipu6 intel-ipu: IPU in secure mode
[   28.463390] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   28.466871] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   28.500533] intel-ipu6 intel-ipu: IPC reset done
[   28.504951] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   28.508879] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   28.513018] intel-ipu6 intel-ipu: FW version: 20220510
[   28.517294] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   28.519859] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   28.523983] intel-ipu6 intel-ipu: mapped as: 0x00000000c4fc3a40
[   28.527636] intel-ipu6 intel-ipu: IPU in secure mode
[   28.529708] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   28.533369] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   28.538099] intel-ipu6 intel-ipu: IPC reset done
[   28.541327] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   28.543325] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   28.545132] intel-ipu6 intel-ipu: FW version: 20220510
[   28.547798] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   28.549641] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   28.551409] intel-ipu6 intel-ipu: mapped as: 0x0000000061c5c228
[   28.553672] intel-ipu6 intel-ipu: IPU in secure mode
[   28.555461] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   28.557230] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   28.560820] intel-ipu6 intel-ipu: IPC reset done
[   28.562526] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   28.564282] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   28.566386] intel-ipu6 intel-ipu: FW version: 20220510
[   28.595815] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   28.599498] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   28.603484] intel-ipu6 intel-ipu: mapped as: 0x0000000061c5c228
[   28.606541] intel-ipu6 intel-ipu: IPU in secure mode
[   28.608326] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   28.610013] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   28.613515] intel-ipu6 intel-ipu: IPC reset done
[   28.615179] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   28.616958] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   28.618649] intel-ipu6 intel-ipu: FW version: 20220510
[   28.661257] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   28.664261] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   28.669602] intel-ipu6 intel-ipu: mapped as: 0x0000000061c5c228
[   28.673366] intel-ipu6 intel-ipu: IPU in secure mode
[   28.676600] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   28.680153] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   28.700766] intel-ipu6 intel-ipu: IPC reset done
[   28.702947] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   28.704808] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   28.707069] intel-ipu6 intel-ipu: FW version: 20220510
[   28.742875] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   28.746019] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   28.747950] intel-ipu6 intel-ipu: mapped as: 0x0000000057b928b5
[   28.749869] intel-ipu6 intel-ipu: IPU in secure mode
[   28.751633] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   28.753385] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   28.757028] intel-ipu6 intel-ipu: IPC reset done
[   28.758741] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   28.760510] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   28.762220] intel-ipu6 intel-ipu: FW version: 20220510
[   28.843266] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   28.847175] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   28.855199] intel-ipu6 intel-ipu: mapped as: 0x0000000057b928b5
[   28.863577] intel-ipu6 intel-ipu: IPU in secure mode
[   28.867050] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   28.872494] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   28.876153] intel-ipu6 intel-ipu: IPC reset done
[   28.878669] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   28.882658] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   28.886882] intel-ipu6 intel-ipu: FW version: 20220510
[   28.988870] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   28.993120] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   28.996710] intel-ipu6 intel-ipu: mapped as: 0x0000000061c5c228
[   29.000704] intel-ipu6 intel-ipu: IPU in secure mode
[   29.002652] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   29.006413] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   29.012218] intel-ipu6 intel-ipu: IPC reset done
[   29.016321] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   29.019610] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   29.021823] intel-ipu6 intel-ipu: FW version: 20220510
[   29.104047] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   29.106223] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   29.107977] intel-ipu6 intel-ipu: mapped as: 0x0000000061c5c228
[   29.109863] intel-ipu6 intel-ipu: IPU in secure mode
[   29.111588] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   29.113322] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   29.116851] intel-ipu6 intel-ipu: IPC reset done
[   29.120184] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   29.123170] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   29.126305] intel-ipu6 intel-ipu: FW version: 20220510
[   29.199636] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   29.211679] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   29.214935] intel-ipu6 intel-ipu: mapped as: 0x0000000061c5c228
[   29.216893] intel-ipu6 intel-ipu: IPU in secure mode
[   29.218622] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   29.222141] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   29.225947] intel-ipu6 intel-ipu: IPC reset done
[   29.228930] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   29.231855] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   29.233720] intel-ipu6 intel-ipu: FW version: 20220510
[   29.253728] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   29.255483] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   29.257192] intel-ipu6 intel-ipu: mapped as: 0x0000000061c5c228
[   29.258912] intel-ipu6 intel-ipu: IPU in secure mode
[   29.260575] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   29.262238] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   29.265718] intel-ipu6 intel-ipu: IPC reset done
[   29.267357] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   29.270787] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   29.274103] intel-ipu6 intel-ipu: FW version: 20220510
[   29.284772] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   29.286726] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   29.288438] intel-ipu6 intel-ipu: mapped as: 0x00000000c4fc3a40
[   29.290360] intel-ipu6 intel-ipu: IPU in secure mode
[   29.292072] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   29.294144] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   29.299490] intel-ipu6 intel-ipu: IPC reset done
[   29.301239] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   29.303010] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   29.304746] intel-ipu6 intel-ipu: FW version: 20220510
[   32.094111] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   32.096882] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   32.098841] intel-ipu6 intel-ipu: mapped as: 0x00000000c4fc3a40
[   32.100831] intel-ipu6 intel-ipu: IPU in secure mode
[   32.102551] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   32.104242] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   32.122569] intel-ipu6 intel-ipu: IPC reset done
[   32.129979] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   32.136858] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   32.143682] intel-ipu6 intel-ipu: FW version: 20220510
[   32.187123] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   32.189669] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   32.191515] intel-ipu6 intel-ipu: mapped as: 0x00000000c4fc3a40
[   32.193265] intel-ipu6 intel-ipu: IPU in secure mode
[   32.194979] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   32.196662] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   32.215418] intel-ipu6 intel-ipu: IPC reset done
[   32.217192] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   32.219068] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   32.220867] intel-ipu6 intel-ipu: FW version: 20220510
[   32.331261] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   32.333227] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   32.334865] intel-ipu6 intel-ipu: mapped as: 0x00000000c4fc3a40
[   32.336440] intel-ipu6 intel-ipu: IPU in secure mode
[   32.337940] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   32.339419] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   32.357931] intel-ipu6 intel-ipu: IPC reset done
[   32.359864] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   32.361556] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   32.363150] intel-ipu6 intel-ipu: FW version: 20220510
[   33.455515] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   33.455547] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   33.455557] intel-ipu6 intel-ipu: mapped as: 0x00000000c4fc3a40
[   33.455613] intel-ipu6 intel-ipu: IPU in secure mode
[   33.455631] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   33.455646] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   33.472899] intel-ipu6 intel-ipu: IPC reset done
[   33.472918] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   33.473079] intel-ipu6 intel-ipu: firmware: direct-loading firmware intel/ipu6ep_fw.bin
[   33.473095] intel-ipu6 intel-ipu: FW version: 20220510
[   33.473607] intel-ipu6 intel-ipu: Found supported sensor INT3474:01
[   33.473672] intel-ipu6 intel-ipu: Connected 1 cameras
[   33.477846] intel-ipu6 intel-ipu: Sending BOOT_LOAD to CSE
[   33.487781] intel-ipu6 intel-ipu: Sending AUTHENTICATE_RUN to CSE
[   33.493891] intel-ipu6-isys intel-ipu6-isys0: bind ov2740 19-0036 nlanes is 2 port is 1
[   33.493976] intel-ipu6-isys intel-ipu6-isys0: All sensor registration completed.
[   33.518402] intel-ipu6-psys intel-ipu6-psys0: pkg_dir entry count:8
[   33.518607] intel-ipu6-psys intel-ipu6-psys0: psys probe minor: 0
[   33.556897] intel-ipu6 intel-ipu: CSE authenticate_run done
[   33.556947] intel-ipu6 intel-ipu: IPU6-v3 driver version 1.0
[   34.642920] intel-ipu6-isys intel-ipu6-isys0: isys port open ready failed -16
[   34.642998] intel-ipu6-isys intel-ipu6-isys0: Device close failure: -16
[  197.576916] intel-ipu6-isys intel-ipu6-isys0: stream on ov2740 19-0036
[  197.612650] intel-ipu6-isys intel-ipu6-isys0: csi2-1 error: Payload checksum (CRC) error
[  197.862167] intel-ipu6-isys intel-ipu6-isys0: csi2-1 error: Single packet header error corrected
[  197.862199] intel-ipu6-isys intel-ipu6-isys0: csi2-1 error: Multiple packet header errors detected
[  197.862208] intel-ipu6-isys intel-ipu6-isys0: csi2-1 error: Payload checksum (CRC) error
[  197.862215] intel-ipu6-isys intel-ipu6-isys0: csi2-1 error: Incomplete long packet detected
[  197.862221] intel-ipu6-isys intel-ipu6-isys0: csi2-1 error: Line sync error
[  197.862227] intel-ipu6-isys intel-ipu6-isys0: csi2-1 error: Inter-frame short packet discarded
[  197.862234] intel-ipu6-isys intel-ipu6-isys0: csi2-1 error: Inter-frame long packet discarded
[  538.518245] intel-ipu6-isys intel-ipu6-isys0: stream off ov2740 19-0036
[  830.215654] intel-ipu6-isys intel-ipu6-isys0: stream on ov2740 19-0036
[  881.638036] intel-ipu6-isys intel-ipu6-isys0: stream off ov2740 19-0036
# lsmod | grep 'ipu\|mei\|vsc'
mei_hdcp               24576  0
mei_me                 45056  1
intel_ipu6_isys       135168  0
videobuf2_dma_contig    24576  1 intel_ipu6_isys
videobuf2_v4l2         36864  1 intel_ipu6_isys
videobuf2_common       73728  4 videobuf2_dma_contig,videobuf2_v4l2,intel_ipu6_isys,videobuf2_memops
intel_ipu6_psys        98304  0
intel_ipu6            106496  2 intel_ipu6_isys,intel_ipu6_psys
mei_vsc                40960  0
mei                   159744  4 mei_hdcp,mei_vsc,mei_me
v4l2_fwnode            32768  2 intel_ipu6_isys,ov2740
v4l2_async             32768  3 v4l2_fwnode,intel_ipu6_isys,ov2740
videodev              286720  6 v4l2_async,videobuf2_v4l2,v4l2loopback,intel_ipu6_isys,videobuf2_common,ov2740
mc                     69632  6 v4l2_async,videodev,videobuf2_v4l2,intel_ipu6_isys,videobuf2_common,ov2740

I did however blacklist intel-ipu6 in /etc/modprobe.d/ipu6.conf because in the boots after installation the system would crash. To my astonishment it then works even though blacklisted. So I assume there still is an issue with module loading order.

fhloston commented 1 year ago

To really see which sensors you have, first build the main kernel with the int3472-gpio + https://lore.kernel.org/linux-acpi/20221022150722.31787-1-hdegoede@redhat.com/ patches. After this the sensors should show up under in ls /sys/bus/i2c/devices for me the 2 sensors are i2c-INT3474:01 which is the ov2740 normal sensor and i2c-OVTI9234:00 which is an ov9234 monochrome sensor which is used as ir-sensor here.

yes, indeed! thanks!


lrwxrwxrwx 1 root root 0 Oct 23 16:44 i2c-ELAN067C:00 -> ../../../devices/pci0000:00/0000:00:15.0/i2c_designware.0/i2c-1/i2c-ELAN067C:00
lrwxrwxrwx 1 root root 0 Oct 23 18:06 i2c-INT3474:01 -> ../../../devices/pci0000:00/0000:00:14.0/usb1/1-8/1-8:1.0/ljca-i2c.31.auto/i2c-19/i2c-INT3474:01
lrwxrwxrwx 1 root root 0 Oct 23 18:06 i2c-INT347D:00 -> ../../../devices/pci0000:00/0000:00:14.0/usb1/1-8/1-8:1.0/ljca-i2c.30.auto/i2c-18/i2c-INT347D:00
lrwxrwxrwx 1 root root 0 Oct 23 18:06 i2c-LATT2021:00 -> ../../../devices/pci0000:00/0000:00:14.0/usb1/1-8/1-8:1.0/ljca-i2c.30.auto/i2c-18/i2c-LATT2021:00
lrwxrwxrwx 1 root root 0 Oct 23 16:44 i2c-NXP1001:00 -> ../../../devices/pci0000:00/0000:00:19.0/i2c_designware.2/i2c-3/i2c-NXP1001:00
lrwxrwxrwx 1 root root 0 Oct 23 18:06 i2c-OVTI9234:00 -> ../../../devices/pci0000:00/0000:00:14.0/usb1/1-8/1-8:1.0/ljca-i2c.30.auto/i2c-18/i2c-OVTI9234:00
lrwxrwxrwx 1 root root 0 Oct 23 16:44 i2c-WACF2200:00 -> ../../../devices/pci0000:00/0000:00:15.1/i2c_designware.1/i2c-2/i2c-WACF2200:00```
fhloston commented 1 year ago

How I installed kernel and drivers:

cd /usr/src/
apt source linux-image-6.0.0-2-amd64-unsigned
cd linux-6.0.3 
cp /boot/config-6.0.0-2-amd64 .config
make oldconfig
# make menuconfig and enable CONFIG_INTEL_SKL_INT3472=m
patch -p1 <../ipu6-drivers-0.0.0/patch/int3472-support-independent-clock-and-LED-gpios-5.17+.patch 
patch -p1 <../latt2021.diff 
nice make -j`nproc` bindeb-pkg
cd /usr/src/
git clone https://github.com/intel/ipu6-drivers.git ipu6-drivers-0.0.0 
cd ipu6-drivers-0.0.0/
git pull origin pull/58/head
git clone https://github.com/intel/ivsc-driver.git
cd ivsc-driver/
git pull origin pull/24/head
cd ..
cp -r ivsc-driver/backport-include ivsc-driver/drivers ivsc-driver/include .
rm -rf ivsc-driver
dkms add ipu6-drivers/0.0.0
dkms install ipu6-drivers/0.0.0
cd /usr/src/
git clone https://github.com/intel/ivsc-driver.git ivsc-driver-1.0.0
cd ivsc-driver-1.0.0/
git pull origin pull/24/head
dkms add ivsc-driver/1.0.0
dkms install ivsc-driver/1.0.0
polair commented 1 year ago

@fhloston thank you for taking the time to write these out, very helpful. I'll get to this sometime today.

jeffreyfq commented 1 year ago

Just something I noted while applying the kernel patch of @jwrdegoede , in drivers/acpi/scan.c, there is an ignore and honor list:

/* List of HIDs for which we honor deps of matching ACPI devs, when checking _DEP lists. */
static const char * const acpi_honor_dep_ids[] = {
    "INT3472", /* Camera sensor PMIC / clk and regulator info */
    NULL
};

My devices are named INT3471 and INT3474, so I am currently compiling the kernel with those two device names added to the list. Not sure if this is necessary, but later in the code:

bool acpi_dev_ready_for_enumeration(const struct acpi_device *device)
{
    if (device->flags.honor_deps && device->dep_unmet)
        return false;

    return acpi_device_is_present(device);
}

maybe the driver is never loaded if the device name is not in this honor list....

@fhloston : did you forget the IOMMU-passthrough-for-intel-ipu.diff patch in you previous post/while patching the kernel?

jeffreyfq commented 1 year ago

As I obviously developed an obsession of compiling my kernel, I tried another round.

This time, I used kernel 6.0.5, downloaded from kernel.org. I applied all the patches in the order @fhloston mentioned in the previous post.... ..except... :) I applied additionally IOMMU-passthrough-for-intel-ipu.diff I added my ids to the int3472_sensor_configs, like so:

/* HP Spectre x360 16-f1xxx */
{ "CJFKE26", REGULATOR_SUPPLY("avdd", NULL), NULL, false },

Actually I tried true and false as the last parameter, and false seems to work better somehow^^ I also added my _HID IDs to the struct acpi_honor_dep_ids.

Then it seems to be crucial to install the v4l2loopback kernel module.

Somewhere in the internet, someone mentioned v4l2-relayd, so I installed it... just in case it does something useful.


As it turns out, I am getting same error messages as before on my self-modified 6.2-rc2/next kernel.

The only related dmesg errors show this:

1.388599] intel vsc not ready
[   16.714727] hp_wmi: Unknown event_id - 131073 - 0x0 <-- this is just the keyboard
[   18.036145] intel vsc not ready
[   18.037633] i2c i2c-INT3537:00: deferred probe pending

I am not sure, but I had a look into the source, the intel vsc not ready orignates in ipu6-drivers-0.0.0/drivers/misc/ivsc/intel_vsc.c and the related source is:

    ret = check_component_ready();
    if (ret < 0) {
        pr_info("intel vsc not ready\n");
        return -EAGAIN;
    }

and the check_component_ready function is doing something like this:

...
if (vsc.ace_registerred && vsc.csi_registerred)
        ret = 0;
...

so it will not be ready until mei_csi.c and mei_ace.c call their respective functions vsc_register_csi(csi, &csi_ops); and vsc_register_ace(ace, &ace_ops); that are located in the module probe functions.

I even put some additional print-outs there, and it turns out those modules are listed in lsmod, but their probe function is never called!! Not sure how this is possible, I thought when I modprobe the module the probe function is called... but my guess is that there is some fancy function in the kernel which relates to the i2c i2c-INT3537:00: deferred probe pending message in the dmesg (not sure).`, maybe some module probe is pending?

One thing that seems strange to me is that there is a hi556 kernel module loaded, even though I dont have this sensor in my device (according to this acpi information)! This could be related to why it is not working. There is no OV2740 module.

lsmod | grep intel
snd_soc_intel_hda_dsp_common    20480  1 snd_soc_skl_hda_dsp
snd_sof_pci_intel_tgl    16384  0
snd_sof_intel_hda_common   143360  1 snd_sof_pci_intel_tgl
soundwire_intel        40960  1 snd_sof_intel_hda_common
soundwire_generic_allocation    16384  1 soundwire_intel
soundwire_cadence      40960  1 soundwire_intel
snd_sof_intel_hda      20480  1 snd_sof_intel_hda_common
snd_sof_pci            24576  2 snd_sof_intel_hda_common,snd_sof_pci_intel_tgl
snd_sof_xtensa_dsp     16384  1 snd_sof_intel_hda_common
snd_sof               233472  3 snd_sof_pci,snd_sof_intel_hda_common,snd_sof_probes
snd_soc_hdac_hda       24576  1 snd_sof_intel_hda_common
snd_hda_ext_core       36864  4 snd_sof_intel_hda_common,snd_soc_hdac_hdmi,snd_soc_hdac_hda,snd_sof_intel_hda
snd_soc_acpi_intel_match    69632  2 snd_sof_intel_hda_common,snd_sof_pci_intel_tgl
snd_soc_acpi           16384  2 snd_soc_acpi_intel_match,snd_sof_intel_hda_common
soundwire_bus          98304  3 soundwire_intel,soundwire_generic_allocation,soundwire_cadence
snd_soc_core          364544  8 soundwire_intel,snd_sof,snd_sof_intel_hda_common,snd_soc_hdac_hdmi,snd_soc_hdac_hda,snd_sof_probes,snd_soc_dmic,snd_soc_skl_hda_dsp
snd_hda_intel          53248  0
snd_intel_dspcfg       36864  3 snd_hda_intel,snd_sof,snd_sof_intel_hda_common
snd_intel_sdw_acpi     20480  2 snd_sof_intel_hda_common,snd_intel_dspcfg
intel_tcc_cooling      16384  0
snd_hda_codec         172032  7 snd_hda_codec_generic,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec_realtek,snd_soc_intel_hda_dsp_common,snd_soc_hdac_hda,snd_soc_skl_hda_dsp
snd_hda_core          118784  11 snd_hda_codec_generic,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_ext_core,snd_hda_codec,snd_hda_codec_realtek,snd_soc_intel_hda_dsp_common,snd_sof_intel_hda_common,snd_soc_hdac_hdmi,snd_soc_hdac_hda,snd_sof_intel_hda
intel_powerclamp       24576  0
snd_pcm               155648  12 snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec,soundwire_intel,snd_sof,snd_sof_intel_hda_common,snd_soc_hdac_hdmi,snd_compress,snd_soc_core,snd_sof_utils,snd_hda_core,snd_pcm_dmaengine
intel_ipu6_isys       143360  0
videobuf2_dma_contig    24576  1 intel_ipu6_isys
videobuf2_v4l2         32768  1 intel_ipu6_isys
videobuf2_common       81920  4 videobuf2_dma_contig,videobuf2_v4l2,intel_ipu6_isys,videobuf2_memops
intel_ipu6_psys        98304  0
btintel                40960  1 btusb
intel_rapl_msr         20480  0
kvm_intel             421888  0
kvm                  1130496  1 kvm_intel
bluetooth             864256  48 btrtl,btmtk,btintel,btbcm,bnep,btusb,rfcomm
hid_sensor_custom_intel_hinge    16384  0
hid_sensor_trigger     20480  15 hid_sensor_gyro_3d,hid_sensor_custom_intel_hinge,hid_sensor_incl_3d,hid_sensor_als,hid_sensor_accel_3d,hid_sensor_rotation
hid_sensor_iio_common    28672  7 hid_sensor_gyro_3d,hid_sensor_trigger,hid_sensor_custom_intel_hinge,hid_sensor_incl_3d,hid_sensor_als,hid_sensor_accel_3d,hid_sensor_rotation
snd                   118784  26 snd_ctl_led,snd_hda_codec_generic,snd_seq,snd_seq_device,snd_hda_codec_hdmi,snd_hwdep,snd_hda_intel,snd_hda_codec,snd_hda_codec_realtek,snd_sof,snd_timer,snd_soc_hdac_hdmi,snd_compress,snd_soc_core,snd_pcm,snd_rawmidi
intel_cstate           20480  0
industrialio          106496  11 industrialio_triggered_buffer,hid_sensor_gyro_3d,hid_sensor_trigger,hid_sensor_custom_intel_hinge,hid_sensor_incl_3d,kfifo_buf,hid_sensor_als,hid_sensor_accel_3d,hid_sensor_rotation
intel_vsec             20480  0
intel_rapl_common      40960  2 intel_rapl_msr,processor_thermal_rapl
intel_ipu6            106496  2 intel_ipu6_isys,intel_ipu6_psys
intel_skl_int3472_tps68470    20480  0
intel_vsc              16384  3 mei_ace,mei_csi,hi556
v4l2_fwnode            32768  2 hi556,intel_ipu6_isys
v4l2_async             28672  3 v4l2_fwnode,hi556,intel_ipu6_isys
intel_skl_int3472_discrete    16384  0
intel_hid              24576  0
sparse_keymap          16384  2 hp_wmi,intel_hid
videodev              274432  7 v4l2_async,hi556,videobuf2_v4l2,v4l2loopback,intel_ipu6_isys,videobuf2_common
mc                     65536  6 v4l2_async,videodev,hi556,videobuf2_v4l2,intel_ipu6_isys,videobuf2_common
hid_sensor_hub         28672  9 hid_sensor_gyro_3d,hid_sensor_trigger,hid_sensor_iio_common,hid_sensor_custom_intel_hinge,hid_sensor_incl_3d,hid_sensor_als,hid_sensor_accel_3d,hid_sensor_rotation,hid_sensor_custom
intel_ishtp_hid        28672  0
ghash_clmulni_intel    16384  0
spi_intel_pci          16384  0
aesni_intel           393216  8
crypto_simd            16384  1 aesni_intel
cryptd                 24576  3 crypto_simd,ghash_clmulni_intel
spi_intel              28672  1 spi_intel_pci
intel_ish_ipc          28672  0
intel_lpss_pci         28672  0
intel_lpss             16384  1 intel_lpss_pci
intel_ishtp            57344  2 intel_ishtp_hid,intel_ish_ipc
hid                   163840  6 i2c_hid,hid_multitouch,hid_sensor_hub,intel_ishtp_hid,hid_generic,uhid
polair commented 1 year ago

@jeffreyfq checkout #55 and read a bit. There's some helpful things in there, does /dev/ipu* exist?

What is in /sys/bus/i2c/devices/??

Did you actually apply the "LATT2021" patch from the kernel mailing list? Copied manually?

What happens when you modprobe ov2740?

Here is what a working GPIO/i2c dev tree looks like for the ov2740 sensor on a nano gen2:

» ll /sys/bus/i2c/devices                                                                           Fri 28 Oct 2022 09:36:46 AM MDT
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-3 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-3
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-10 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-1/i2c-10
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-1 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-1
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-8 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-8
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-6 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-6
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-13 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-4/i2c-13
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-4 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-4
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-11 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-2/i2c-11
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-2 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-2
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-0 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-0
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-9 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-eDP-1/i2c-9
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-7 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-7
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-5 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-5
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-12 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-3/i2c-12
lrwxrwxrwx 0 root 28 Oct 09:20 i2c-15 -> ../../../devices/pci0000:00/0000:00:1f.4/i2c-15
lrwxrwxrwx 0 root 28 Oct 09:36 i2c-OVTI9234:00 -> ../../../devices/pci0000:00/0000:00:14.0/usb3/3-8/3-8:1.0/ljca-i2c.2.auto/i2c-16/i2c-OVTI9234:00
lrwxrwxrwx 0 root 28 Oct 09:36 i2c-17 -> ../../../devices/pci0000:00/0000:00:14.0/usb3/3-8/3-8:1.0/ljca-i2c.3.auto/i2c-17
lrwxrwxrwx 0 root 28 Oct 09:36 i2c-ELAN0670:00 -> ../../../devices/pci0000:00/0000:00:15.0/i2c_designware.0/i2c-14/i2c-ELAN0670:00
lrwxrwxrwx 0 root 28 Oct 09:36 i2c-INT347D:00 -> ../../../devices/pci0000:00/0000:00:14.0/usb3/3-8/3-8:1.0/ljca-i2c.2.auto/i2c-16/i2c-INT347D:00
lrwxrwxrwx 0 root 28 Oct 09:36 i2c-INT3474:01 -> ../../../devices/pci0000:00/0000:00:14.0/usb3/3-8/3-8:1.0/ljca-i2c.3.auto/i2c-17/i2c-INT3474:01
lrwxrwxrwx 0 root 28 Oct 09:36 i2c-LATT2021:00 -> ../../../devices/pci0000:00/0000:00:14.0/usb3/3-8/3-8:1.0/ljca-i2c.2.auto/i2c-16/i2c-LATT2021:00
lrwxrwxrwx 0 root 28 Oct 09:36 i2c-16 -> ../../../devices/pci0000:00/0000:00:14.0/usb3/3-8/3-8:1.0/ljca-i2c.2.auto/i2c-16
lrwxrwxrwx 0 root 28 Oct 09:36 i2c-14 -> ../../../devices/pci0000:00/0000:00:15.0/i2c_designware.0/i2c-14
jwrdegoede commented 1 year ago

@jeffreyfq you should not edit/change acpi_honor_dep_ids. To make the i2c devices for the sensors show up under /sys/bus/i2c/devices you need 2 changes:

  1. My patch which adds "LATT2021" to acpi_ignore_dep_ids[]
  2. https://github.com/intel/ivsc-driver/pull/24/commits/c5aa0b65a6fb3cca7ee3b6fae093cfadfdd3a5cf

For details for how this all actually works (it has to do with ensuring that things are probed in a certain order) see: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=9d9bcae47fd5a

polair commented 1 year ago

@jwrdegoede That's exactly the details I wanted. Very great reading/learning material. Thanks.

drogenlied commented 1 year ago

@fhloston @jwrdegoede If you have trouble with v4l-relayd not working, try using v4l2loopback from Ubuntu (https://git.launchpad.net/ubuntu/+source/v4l2loopback), it contains patches (in folder debian/patches) that are crucial to make v4l-relayd work, mostly relating to V4L2_EVENT_PRI_CLIENT_USAGE, aka v4l2 events needed to start the stream when a client opens the loopback device.

I just got that to sort of work today with chromium and gstreamer video source, everything else has some problems with the loopback device and sometimes v4l2-relayd just crashes.

jwrdegoede commented 1 year ago

@drogenlied a thanks, that probably explains why it is not working for me.

drogenlied commented 1 year ago

Another tip: applying https://github.com/umlaeute/v4l2loopback/pull/435 to v4l2loopback will allow some ffmpeg based applications to use the device, otherwise they complain about buffer sizes. Maybe this just fixes symptoms and the root cause is somewhere in gstreamer, it helps nonetheless.

One more thing:

I added an output video format to the v4l2-relayd .service file and the config file, as shown below, now I have successfully tested Chromium, OBS, Firefox, mpv and VLC.

Especially VLC and Firefox really do not like the NV12 video format and work fine with YUY2.

[Unit]
Description=v4l2-relay daemon service
After=modprobe@v4l2loopback.service systemd-logind.service

[Service]
Type=simple
EnvironmentFile=/etc/default/v4l2-relayd
EnvironmentFile=-/etc/v4l2-relayd
ExecCondition=/usr/bin/test -n "${VIDEOSRC}"
ExecCondition=/usr/bin/test -n "$FORMAT"
ExecCondition=/usr/bin/test -n "$FORMAT_OUT"
ExecCondition=/usr/bin/test -n "$WIDTH"
ExecCondition=/usr/bin/test -n "$HEIGHT"
ExecCondition=/usr/bin/test -n "$FRAMERATE"
ExecCondition=/usr/bin/test -n "${CARD_LABEL}"
ExecStart=/bin/sh -c 'DEVICE=$(grep -l -m1 -E "^${CARD_LABEL}$" /sys/devices/virtual/video4linux/*/name | cut -d/ -f6); exec /usr/bin/v4l2-relayd -i "${VIDEOSRC}" $${SPLASHSRC:+-s "${SPLASHSRC}"} -o "appsrc name=appsrc caps=video/x-raw,format=${FORMAT},width=${WIDTH},height=${HEIGHT},framerate=${FRAMERATE} ! videoconvert ! video/x-raw,format=${FORMAT_OUT} ! v4l2sink name=v4l2sink device=/dev/$${DEVICE}"'
ExecStopPost=/bin/sh -c 'modprobe -r v4l2loopback; modprobe v4l2loopback'
Restart=always

[Install]
WantedBy=multi-user.target
# GStreamer source element name:
VIDEOSRC="icamerasrc"
#SPLASHSRC="filesrc location=/.../splash.png ! pngdec ! imagefreeze num-buffers=4 ! videoscale ! videoconvert"

# Output format, width, height, and frame rate:
FORMAT=NV12
FORMAT_OUT=YUY2
WIDTH=1280
HEIGHT=720
FRAMERATE=30/1

# Virtual video device name:
CARD_LABEL="Intel MIPI Camera"

# Extra options to pass to v4l2-relayd:
#EXTRA_OPTS=-d
jeffreyfq commented 1 year ago

Thanks @jwrdegoede and @polair for following up on this,

@jwrdegoede, I can confirm,

@polair:

does /dev/ipu* exist?

Yes

Did you actually apply the "LATT2021" patch from the kernel mailing list? Copied manually?

Yes, I patched this, the one-liner, but I dont have that device in my system. I also applied the IOMMU, gpio, #58 and the 24 pull request (https://github.com/intel/ivsc-driver/pull/24)

What is in /sys/bus/i2c/devices/??

jfq@jeffreyhp:~/src/kernel/ipu6-drivers-0.0.0$ ll /sys/bus/i2c/devices
total 0
drwxr-xr-x 2 root root 0 Oct 31 15:46 ./
drwxr-xr-x 4 root root 0 Oct 31 15:46 ../
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-0 -> ../../../devices/pci0000:00/0000:00:1f.4/i2c-0/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-1 -> ../../../devices/pci0000:00/0000:00:10.0/i2c_designware.0/i2c-1/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-10 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-10/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-11 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-11/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-12 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-12/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-13 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-13/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-14 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-14/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-15 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-eDP-1/i2c-15/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-16 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-1/i2c-16/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-17 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-2/i2c-17/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-18 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-3/i2c-18/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-19 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-4/i2c-19/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-2 -> ../../../devices/pci0000:00/0000:00:10.1/i2c_designware.1/i2c-2/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-20 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-5/i2c-20/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-3 -> ../../../devices/pci0000:00/0000:00:15.0/i2c_designware.2/i2c-3/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-4 -> ../../../devices/pci0000:00/0000:00:15.1/i2c_designware.3/i2c-4/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-5 -> ../../../devices/pci0000:00/0000:00:19.0/i2c_designware.4/i2c-5/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-6 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-6/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-7 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-7/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-8 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-8/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-9 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-9/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-ELAN2513:00 -> ../../../devices/pci0000:00/0000:00:15.1/i2c_designware.3/i2c-4/i2c-ELAN2513:00/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-INT3537:00 -> ../../../devices/pci0000:00/0000:00:19.0/i2c_designware.4/i2c-5/i2c-INT3537:00/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-OVTI00AB:00 -> ../../../devices/pci0000:00/0000:00:10.1/i2c_designware.1/i2c-2/i2c-OVTI00AB:00/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-SYNA32C0:00 -> ../../../devices/pci0000:00/0000:00:15.0/i2c_designware.2/i2c-3/i2c-SYNA32C0:00/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-TXNW3643:01 -> ../../../devices/pci0000:00/0000:00:10.1/i2c_designware.1/i2c-2/i2c-TXNW3643:01/

What happens when you modprobe ov2740?

Nothing, no dmesg entry, no error, I can not notice any difference after loading the module by hand.

jfq@jeffreyhp:~$ modinfo ov2740 
filename:       /lib/modules/6.0.5/updates/dkms/ov2740.ko
license:        GPL v2
description:    OmniVision OV2740 sensor driver
author:         Bingbu Cao <bingbu.cao@intel.com>
author:         Shawn Tu <shawnx.tu@intel.com>
author:         Qiu, Tianshu <tian.shu.qiu@intel.com>
srcversion:     A93395D93ACFD7D88D82462
alias:          acpi*:INT3474:*
depends:        videodev,v4l2-async,v4l2-fwnode,mc
retpoline:      Y
name:           ov2740
vermagic:       6.0.5 SMP preempt mod_unload modversions 


I guess there are some differences to the HP spectre notebook, compared to the lenovo one. When I boot, the hi556 module is loaded and the ov2740 is not loaded. also the mei_vsc module is not loaded. There other modules are loaded.

But there is no hi556 device, also the device name in hi556.c:

static const struct acpi_device_id hi556_acpi_ids[] = {
    {"INT3537"},
    {}
};

Does not exist in the ACPI data (e.g. grep -A9 "INT3537" dsdt.dsl or grep -A9 "556" dsdt.dsl)

grep -A9 "(CAM" dsdt.dsl 
        Device (CAM0)
        {
            Name (_HID, "INT3471")  // _HID: Hardware ID
            Name (_DDN, "IMX135-CRDG2")  // _DDN: DOS Device Name
            Name (_UID, "0")  // _UID: Unique ID
            Name (_DEP, Package (0x01)  // _DEP: Dependencies
            {
                PMIC
            })
            Name (_PLD, Package (0x01)  // _PLD: Physical Location of Device
--
        Device (CAM1)
        {
            Name (_HID, "INT3474")  // _HID: Hardware ID
            Name (_DDN, "OV2740-CRDG2")  // _DDN: DOS Device Name
            Name (_UID, "0")  // _UID: Unique ID
            Name (_DEP, Package (0x01)  // _DEP: Dependencies
            {
                ^^I2C2.PMIC
            })
            Name (_PLD, Package (0x01)  // _PLD: Physical Location of Device

Also there is no LATT2021 device, checked grep -A9 "LATT2021" dsdt.dsl, can it be that the device has another name in my system, is there a way to figure this out? I guess the suspicious devices are:

lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-ELAN2513:00 -> ../../../devices/pci0000:00/0000:00:15.1/i2c_designware.3/i2c-4/i2c-ELAN2513:00/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-INT3537:00 -> ../../../devices/pci0000:00/0000:00:19.0/i2c_designware.4/i2c-5/i2c-INT3537:00/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-OVTI00AB:00 -> ../../../devices/pci0000:00/0000:00:10.1/i2c_designware.1/i2c-2/i2c-OVTI00AB:00/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-SYNA32C0:00 -> ../../../devices/pci0000:00/0000:00:15.0/i2c_designware.2/i2c-3/i2c-SYNA32C0:00/
lrwxrwxrwx 1 root root 0 Oct 31 15:46 i2c-TXNW3643:01 -> ../../../devices/pci0000:00/0000:00:10.1/i2c_designware.1/i2c-2/i2c-TXNW3643:01/

But even then, I seems strange to me that the hi556 module loads without a device present in my system.

Right after boot, I can see many messages intel vsc not ready and one message i2c i2c-INT3537:00: deferred probe pending in the dmesg output.

jwrdegoede commented 1 year ago

@jeffreyfq the ACPI tables unfortunately are not always written in such a way that they are easily readable. E.g. the ACPI hw-id (HID/CID) may come out of a variable set by the BIOS.

E.g. you say there is no INT3537 in your DSDT (did you also check the SSDTs?) but since you do have a i2c-INT3537:00 device you clearly have an ACPI device in your tables with a INT3537 HID and this is also why the hi556 module is loading.

It is also interesting to see if the driver is actually binding to the device. Can you do:

ls -l /sys/bus/i2c/devices/INT3537:00/

And see if there is a driver symlink in there ? And the same for the other i2c-devices.

Note that it might be tricky to get things to work on laptop models which do not have an officially supported Linux OS option (typically an Ubuntu OEM install) . On these laptop models some extra work / fixes may be necessary and it may be quite tricky to figure out what changes are necessary.

Can you attach a full dmesg output from after your latest attempt here? And also please run sudo acpidump -o acpidump.txt and attach the acpidump.txt file here. Or send them both to me directly at hdegoede@redhat.com. Note I'm not making any promises here, but I can at least take a quick look. Also I'm quite busy this week so it may be a while before I get back to you.

jwrdegoede commented 1 year ago

@jeffreyfq Also please run: cat /sys/bus/i2c/devices/INT3537:00/firmware_node/path and let us know what the output is? This will tell us which "Device (NAME0000) {}" in the ACPI tables corresponds to the hi556 sensor. Typically a "Device (LNK0) {}" entry in the tables belongs to the main sensor.

norbusan commented 1 year ago

Hi all,

[success message]

just joining in with a different but similar hardware: Lenovo ThinkPad X1 Carbon Gen 10, model 21CBCTO1WW

I got the webcam working with the following steps:

With that in place I see a lot of log messages concerning IPU:

$ dmesg | grep -i ipu
[    0.011669] ACPI: SSDT 0x0000000089826000 000150 (v02 LENOVO IpuSsdt  00001000 INTL 20200717)
[    0.817481] pci 0000:00:05.0: DMAR: Passthrough IOMMU for integrated Intel IPU
[   10.043151] intel-ipu6 intel-ipu: enabling device (0000 -> 0002)
[   10.043260] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.043270] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.043271] intel-ipu6 intel-ipu: mapped as: 0x000000009f91e87e
[   10.043332] intel-ipu6 intel-ipu: IPU in secure mode
[   10.043335] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.043336] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.060194] intel-ipu6 intel-ipu: IPC reset done
[   10.060198] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.061333] intel-ipu6 intel-ipu: FW version: 20220510
[   10.062508] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.062520] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.062521] intel-ipu6 intel-ipu: mapped as: 0x000000006b8c1666
[   10.062584] intel-ipu6 intel-ipu: IPU in secure mode
[   10.062585] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.062586] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.064939] intel-ipu6 intel-ipu: IPC reset done
[   10.064944] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.065040] intel-ipu6 intel-ipu: FW version: 20220510
[   10.066048] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.066059] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.066060] intel-ipu6 intel-ipu: mapped as: 0x0000000000d10621
[   10.066112] intel-ipu6 intel-ipu: IPU in secure mode
[   10.066113] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.066114] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.068468] intel-ipu6 intel-ipu: IPC reset done
[   10.068468] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.068577] intel-ipu6 intel-ipu: FW version: 20220510
[   10.100039] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.100050] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.100051] intel-ipu6 intel-ipu: mapped as: 0x000000009f91e87e
[   10.100093] intel-ipu6 intel-ipu: IPU in secure mode
[   10.100095] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.100096] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.103207] intel-ipu6 intel-ipu: IPC reset done
[   10.103213] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.103359] intel-ipu6 intel-ipu: FW version: 20220510
[   10.124501] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.124513] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.124514] intel-ipu6 intel-ipu: mapped as: 0x000000009f91e87e
[   10.124588] intel-ipu6 intel-ipu: IPU in secure mode
[   10.124589] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.124590] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.126437] intel-ipu6 intel-ipu: IPC reset done
[   10.126437] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.126510] intel-ipu6 intel-ipu: FW version: 20220510
[   10.216300] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.216311] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.216312] intel-ipu6 intel-ipu: mapped as: 0x000000006b8c1666
[   10.216361] intel-ipu6 intel-ipu: IPU in secure mode
[   10.216367] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.216368] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.235485] intel-ipu6 intel-ipu: IPC reset done
[   10.235489] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.235633] intel-ipu6 intel-ipu: FW version: 20220510
[   10.238425] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.238436] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.238437] intel-ipu6 intel-ipu: mapped as: 0x000000006b8c1666
[   10.238477] intel-ipu6 intel-ipu: IPU in secure mode
[   10.238479] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.238481] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.241021] intel-ipu6 intel-ipu: IPC reset done
[   10.241022] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.241145] intel-ipu6 intel-ipu: FW version: 20220510
[   10.263576] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.263595] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.263596] intel-ipu6 intel-ipu: mapped as: 0x000000006b8c1666
[   10.263820] intel-ipu6 intel-ipu: IPU in secure mode
[   10.263822] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.263823] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.266406] intel-ipu6 intel-ipu: IPC reset done
[   10.266413] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.266523] intel-ipu6 intel-ipu: FW version: 20220510
[   10.267540] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.267551] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.267552] intel-ipu6 intel-ipu: mapped as: 0x0000000000d10621
[   10.267678] intel-ipu6 intel-ipu: IPU in secure mode
[   10.267679] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.267680] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.269512] intel-ipu6 intel-ipu: IPC reset done
[   10.269513] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.269593] intel-ipu6 intel-ipu: FW version: 20220510
[   10.307519] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.307534] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.307535] intel-ipu6 intel-ipu: mapped as: 0x000000001758fcf0
[   10.307569] intel-ipu6 intel-ipu: IPU in secure mode
[   10.307570] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.307571] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.317190] intel-ipu6 intel-ipu: IPC reset done
[   10.317191] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.317284] intel-ipu6 intel-ipu: FW version: 20220510
[   10.373970] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.375379] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.375380] intel-ipu6 intel-ipu: mapped as: 0x000000009f91e87e
[   10.375443] intel-ipu6 intel-ipu: IPU in secure mode
[   10.375444] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.375444] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.377993] intel-ipu6 intel-ipu: IPC reset done
[   10.378009] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.378109] intel-ipu6 intel-ipu: FW version: 20220510
[   10.407695] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.407713] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.407714] intel-ipu6 intel-ipu: mapped as: 0x000000009f91e87e
[   10.407817] intel-ipu6 intel-ipu: IPU in secure mode
[   10.407819] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.407820] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.409654] intel-ipu6 intel-ipu: IPC reset done
[   10.409660] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.409763] intel-ipu6 intel-ipu: FW version: 20220510
[   10.481998] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.482012] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.482014] intel-ipu6 intel-ipu: mapped as: 0x000000009f91e87e
[   10.482055] intel-ipu6 intel-ipu: IPU in secure mode
[   10.482058] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.482059] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.504768] intel-ipu6 intel-ipu: IPC reset done
[   10.504770] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.504964] intel-ipu6 intel-ipu: FW version: 20220510
[   10.655783] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.655797] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.655798] intel-ipu6 intel-ipu: mapped as: 0x0000000055f52ac6
[   10.655825] intel-ipu6 intel-ipu: IPU in secure mode
[   10.655826] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.655827] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.657810] intel-ipu6 intel-ipu: IPC reset done
[   10.657812] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.657905] intel-ipu6 intel-ipu: FW version: 20220510
[   10.700773] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.700793] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.700794] intel-ipu6 intel-ipu: mapped as: 0x0000000055f52ac6
[   10.700875] intel-ipu6 intel-ipu: IPU in secure mode
[   10.700881] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.700882] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.702977] intel-ipu6 intel-ipu: IPC reset done
[   10.702979] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.703091] intel-ipu6 intel-ipu: FW version: 20220510
[   10.914599] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   10.914654] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   10.914656] intel-ipu6 intel-ipu: mapped as: 0x0000000055f52ac6
[   10.917528] intel-ipu6 intel-ipu: IPU in secure mode
[   10.917530] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   10.917542] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   10.919402] intel-ipu6 intel-ipu: IPC reset done
[   10.919408] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   10.919517] intel-ipu6 intel-ipu: FW version: 20220510
[   11.128414] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   11.129443] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   11.129444] intel-ipu6 intel-ipu: mapped as: 0x00000000325cf0bc
[   11.129875] intel-ipu6 intel-ipu: IPU in secure mode
[   11.129876] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   11.129877] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   11.148779] intel-ipu6 intel-ipu: IPC reset done
[   11.148782] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   11.148885] intel-ipu6 intel-ipu: FW version: 20220510
[   11.281618] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   11.281718] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   11.281719] intel-ipu6 intel-ipu: mapped as: 0x000000001758fcf0
[   11.281767] intel-ipu6 intel-ipu: IPU in secure mode
[   11.281770] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   11.281772] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   11.300885] intel-ipu6 intel-ipu: IPC reset done
[   11.300886] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   11.300984] intel-ipu6 intel-ipu: FW version: 20220510
[   11.340483] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   11.340502] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   11.340504] intel-ipu6 intel-ipu: mapped as: 0x000000001758fcf0
[   11.340743] intel-ipu6 intel-ipu: IPU in secure mode
[   11.340745] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   11.340746] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   11.342500] intel-ipu6 intel-ipu: IPC reset done
[   11.342503] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   11.342607] intel-ipu6 intel-ipu: FW version: 20220510
[   11.559318] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   11.559363] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   11.559364] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   11.559398] intel-ipu6 intel-ipu: IPU in secure mode
[   11.559399] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   11.559400] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   11.561722] intel-ipu6 intel-ipu: IPC reset done
[   11.561724] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   11.561838] intel-ipu6 intel-ipu: FW version: 20220510
[   11.738062] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   11.738080] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   11.738081] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   11.738186] intel-ipu6 intel-ipu: IPU in secure mode
[   11.738187] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   11.738194] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   11.757504] intel-ipu6 intel-ipu: IPC reset done
[   11.757505] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   11.757660] intel-ipu6 intel-ipu: FW version: 20220510
[   12.003615] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.003659] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.003661] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.003709] intel-ipu6 intel-ipu: IPU in secure mode
[   12.003711] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.003712] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.022999] intel-ipu6 intel-ipu: IPC reset done
[   12.023003] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.023128] intel-ipu6 intel-ipu: FW version: 20220510
[   12.243772] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.243815] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.243818] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.243940] intel-ipu6 intel-ipu: IPU in secure mode
[   12.243943] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.243945] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.263013] intel-ipu6 intel-ipu: IPC reset done
[   12.263020] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.263254] intel-ipu6 intel-ipu: FW version: 20220510
[   12.352063] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.352091] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.352092] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.352136] intel-ipu6 intel-ipu: IPU in secure mode
[   12.352137] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.352138] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.370772] intel-ipu6 intel-ipu: IPC reset done
[   12.370775] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.370934] intel-ipu6 intel-ipu: FW version: 20220510
[   12.379043] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.379055] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.379056] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.379150] intel-ipu6 intel-ipu: IPU in secure mode
[   12.379151] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.379152] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.382009] intel-ipu6 intel-ipu: IPC reset done
[   12.382011] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.382104] intel-ipu6 intel-ipu: FW version: 20220510
[   12.398002] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.398016] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.398017] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.398078] intel-ipu6 intel-ipu: IPU in secure mode
[   12.398079] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.398080] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.402947] intel-ipu6 intel-ipu: IPC reset done
[   12.402950] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.403038] intel-ipu6 intel-ipu: FW version: 20220510
[   12.408382] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.408394] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.408395] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.408425] intel-ipu6 intel-ipu: IPU in secure mode
[   12.408426] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.408427] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.410191] intel-ipu6 intel-ipu: IPC reset done
[   12.410193] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.410275] intel-ipu6 intel-ipu: FW version: 20220510
[   12.436717] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.436736] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.436737] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.436779] intel-ipu6 intel-ipu: IPU in secure mode
[   12.436780] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.436781] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.438630] intel-ipu6 intel-ipu: IPC reset done
[   12.438632] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.438721] intel-ipu6 intel-ipu: FW version: 20220510
[   12.459797] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.459815] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.459817] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.459875] intel-ipu6 intel-ipu: IPU in secure mode
[   12.459876] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.459878] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.461694] intel-ipu6 intel-ipu: IPC reset done
[   12.461697] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.461797] intel-ipu6 intel-ipu: FW version: 20220510
[   12.466827] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.466842] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.466843] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.466925] intel-ipu6 intel-ipu: IPU in secure mode
[   12.466927] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.466928] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.468751] intel-ipu6 intel-ipu: IPC reset done
[   12.468752] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.468837] intel-ipu6 intel-ipu: FW version: 20220510
[   12.470287] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.470337] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.470338] intel-ipu6 intel-ipu: mapped as: 0x0000000055f52ac6
[   12.470371] intel-ipu6 intel-ipu: IPU in secure mode
[   12.470372] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.470373] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.472217] intel-ipu6 intel-ipu: IPC reset done
[   12.472222] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.472306] intel-ipu6 intel-ipu: FW version: 20220510
[   12.476656] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.476725] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.476726] intel-ipu6 intel-ipu: mapped as: 0x000000008d578957
[   12.476751] intel-ipu6 intel-ipu: IPU in secure mode
[   12.476752] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.476753] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.478534] intel-ipu6 intel-ipu: IPC reset done
[   12.478540] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.478629] intel-ipu6 intel-ipu: FW version: 20220510
[   12.480979] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.480991] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.480992] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.481088] intel-ipu6 intel-ipu: IPU in secure mode
[   12.481089] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.481090] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.482931] intel-ipu6 intel-ipu: IPC reset done
[   12.482937] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.483031] intel-ipu6 intel-ipu: FW version: 20220510
[   12.484322] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.484329] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.484330] intel-ipu6 intel-ipu: mapped as: 0x0000000055f52ac6
[   12.484354] intel-ipu6 intel-ipu: IPU in secure mode
[   12.484355] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.484356] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.486199] intel-ipu6 intel-ipu: IPC reset done
[   12.486201] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.486282] intel-ipu6 intel-ipu: FW version: 20220510
[   12.558930] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.558953] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.558955] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.558995] intel-ipu6 intel-ipu: IPU in secure mode
[   12.558997] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.558998] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.560818] intel-ipu6 intel-ipu: IPC reset done
[   12.560821] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.560916] intel-ipu6 intel-ipu: FW version: 20220510
[   12.562555] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.562570] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.562572] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.562605] intel-ipu6 intel-ipu: IPU in secure mode
[   12.562606] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.562607] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.564423] intel-ipu6 intel-ipu: IPC reset done
[   12.564424] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.564519] intel-ipu6 intel-ipu: FW version: 20220510
[   12.594038] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.594058] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.594059] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.594093] intel-ipu6 intel-ipu: IPU in secure mode
[   12.594094] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.594095] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.595920] intel-ipu6 intel-ipu: IPC reset done
[   12.595925] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.596068] intel-ipu6 intel-ipu: FW version: 20220510
[   12.597923] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.597936] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.597937] intel-ipu6 intel-ipu: mapped as: 0x0000000055f52ac6
[   12.597996] intel-ipu6 intel-ipu: IPU in secure mode
[   12.597997] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.597998] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.599849] intel-ipu6 intel-ipu: IPC reset done
[   12.599854] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.599965] intel-ipu6 intel-ipu: FW version: 20220510
[   12.601550] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.601567] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.601569] intel-ipu6 intel-ipu: mapped as: 0x000000008d578957
[   12.601629] intel-ipu6 intel-ipu: IPU in secure mode
[   12.601631] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.601632] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.603448] intel-ipu6 intel-ipu: IPC reset done
[   12.603450] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.603543] intel-ipu6 intel-ipu: FW version: 20220510
[   12.604835] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.605009] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.605010] intel-ipu6 intel-ipu: mapped as: 0x000000000d426dcd
[   12.605163] intel-ipu6 intel-ipu: IPU in secure mode
[   12.605164] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.605165] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.607008] intel-ipu6 intel-ipu: IPC reset done
[   12.607017] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.607096] intel-ipu6 intel-ipu: FW version: 20220510
[   12.608322] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.608330] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.608331] intel-ipu6 intel-ipu: mapped as: 0x0000000004beb0f7
[   12.608356] intel-ipu6 intel-ipu: IPU in secure mode
[   12.608357] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.608358] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.610209] intel-ipu6 intel-ipu: IPC reset done
[   12.610216] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.610292] intel-ipu6 intel-ipu: FW version: 20220510
[   12.611435] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.611441] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.611442] intel-ipu6 intel-ipu: mapped as: 0x000000009c581205
[   12.611518] intel-ipu6 intel-ipu: IPU in secure mode
[   12.611519] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.611520] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.613348] intel-ipu6 intel-ipu: IPC reset done
[   12.613348] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.613389] intel-ipu6 intel-ipu: FW version: 20220510
[   12.615559] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.615567] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.615567] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.615654] intel-ipu6 intel-ipu: IPU in secure mode
[   12.615655] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.615655] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.617518] intel-ipu6 intel-ipu: IPC reset done
[   12.617518] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.617589] intel-ipu6 intel-ipu: FW version: 20220510
[   12.618888] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.618894] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.618894] intel-ipu6 intel-ipu: mapped as: 0x0000000055f52ac6
[   12.618981] intel-ipu6 intel-ipu: IPU in secure mode
[   12.618982] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.618982] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.620800] intel-ipu6 intel-ipu: IPC reset done
[   12.620801] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.620870] intel-ipu6 intel-ipu: FW version: 20220510
[   12.625042] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.625081] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.625082] intel-ipu6 intel-ipu: mapped as: 0x000000009ae01000
[   12.625167] intel-ipu6 intel-ipu: IPU in secure mode
[   12.625172] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.625175] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.627001] intel-ipu6 intel-ipu: IPC reset done
[   12.627003] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.627213] intel-ipu6 intel-ipu: FW version: 20220510
[   12.635101] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[   12.635306] intel-ipu6 intel-ipu: physical base address 0x603c000000
[   12.635307] intel-ipu6 intel-ipu: mapped as: 0x00000000325cf0bc
[   12.635333] intel-ipu6 intel-ipu: IPU in secure mode
[   12.635335] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[   12.635336] intel-ipu6 intel-ipu: IPU camera mask = 0xff
[   12.637173] intel-ipu6 intel-ipu: IPC reset done
[   12.637175] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[   12.637230] intel-ipu6 intel-ipu: FW version: 20220510
[   12.638955] intel-ipu6 intel-ipu: Found supported sensor INT3474:01
[   12.639000] intel-ipu6 intel-ipu: Connected 1 cameras
[   12.640446] intel-ipu6 intel-ipu: Sending BOOT_LOAD to CSE
[   12.649724] intel-ipu6 intel-ipu: Sending AUTHENTICATE_RUN to CSE
[   12.659422] intel-ipu6-psys intel-ipu6-psys0: pkg_dir entry count:8
[   12.659525] intel-ipu6-psys intel-ipu6-psys0: psys probe minor: 0
[   12.663200] intel-ipu6-isys intel-ipu6-isys0: bind ov2740 13-0036 nlanes is 2 port is 1
[   12.663266] intel-ipu6-isys intel-ipu6-isys0: All sensor registration completed.
[   12.723334] intel-ipu6 intel-ipu: CSE authenticate_run done
[   12.723348] intel-ipu6 intel-ipu: IPU6-v3 driver version 1.0
[   13.663337] intel-ipu6-isys intel-ipu6-isys0: isys port open ready failed -16
[   13.663342] intel-ipu6-isys intel-ipu6-isys0: Device close failure: -16

I have the following devices:

lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-0 -> ../../../devices/pci0000:00/0000:00:15.0/i2c_designware.0/i2c-0/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-1 -> ../../../devices/pci0000:00/0000:00:19.0/i2c_designware.1/i2c-1/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-10 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-10/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-11 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-11/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-12 -> ../../../devices/pci0000:00/0000:00:14.0/usb3/3-8/3-8:1.0/ljca-i2c.2.auto/i2c-12/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-13 -> ../../../devices/pci0000:00/0000:00:14.0/usb3/3-8/3-8:1.0/ljca-i2c.3.auto/i2c-13/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-14 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-eDP-1/i2c-14/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-15 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-1/i2c-15/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-16 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-2/i2c-16/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-17 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-3/i2c-17/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-18 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-4/i2c-18/
lrwxrwxrwx 1 root root 0 Nov  1 23:06 i2c-2 -> ../../../devices/pci0000:00/0000:00:1f.4/i2c-2/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-3 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-3/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-4 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-4/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-5 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-5/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-6 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-6/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-7 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-7/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-8 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-8/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-9 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-9/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-INT3474:01 -> ../../../devices/pci0000:00/0000:00:14.0/usb3/3-8/3-8:1.0/ljca-i2c.3.auto/i2c-13/i2c-INT3474:01/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-INT347D:00 -> ../../../devices/pci0000:00/0000:00:14.0/usb3/3-8/3-8:1.0/ljca-i2c.2.auto/i2c-12/i2c-INT347D:00/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-LATT2021:00 -> ../../../devices/pci0000:00/0000:00:14.0/usb3/3-8/3-8:1.0/ljca-i2c.2.auto/i2c-12/i2c-LATT2021:00/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-NXP1001:00 -> ../../../devices/pci0000:00/0000:00:19.0/i2c_designware.1/i2c-1/i2c-NXP1001:00/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-OVTI9234:00 -> ../../../devices/pci0000:00/0000:00:14.0/usb3/3-8/3-8:1.0/ljca-i2c.2.auto/i2c-12/i2c-OVTI9234:00/
lrwxrwxrwx 1 root root 0 Nov  1 23:08 i2c-SYNA8016:00 -> ../../../devices/pci0000:00/0000:00:15.0/i2c_designware.0/i2c-0/i2c-SYNA8016:00/

After that I managed to get a video output with

sudo -E gst-launch-1.0 icamerasrc device-name=ov2740-uf buffer-count=7 ! video/x-raw,format=NV12,width=1280,height=720 ! videoconvert ! ximagesink

Next I will try relayd or loopback according to the comments here.

Thanks a lot for all your work

norbusan commented 1 year ago

Additional information: With this repo: https://github.com/stefanpartheym/archlinux-ipu6-webcam and in particular the v4l2loopback and v4l2-relayd packages installed and loade using

modprobe v4l2loopback exclusive_caps=1

I get video output in MS Edge (Linux) in Jit.si and Google Meet.

Incredible!

jeffreyfq commented 1 year ago

@jeffreyfq the ACPI tables unfortunately are not always written in such a way that they are easily readable. E.g. the ACPI hw-id (HID/CID) may come out of a variable set by the BIOS.

E.g. you say there is no INT3537 in your DSDT (did you also check the SSDTs?) but since you do have a i2c-INT3537:00 device you clearly have an ACPI device in your tables with a INT3537 HID and this is also why the hi556 module is loading.

It is also interesting to see if the driver is actually binding to the device. Can you do:

ls -l /sys/bus/i2c/devices/INT3537:00/

And see if there is a driver symlink in there ? And the same for the other i2c-devices.

Note that it might be tricky to get things to work on laptop models which do not have an officially supported Linux OS option (typically an Ubuntu OEM install) . On these laptop models some extra work / fixes may be necessary and it may be quite tricky to figure out what changes are necessary.

Can you attach a full dmesg output from after your latest attempt here? And also please run sudo acpidump -o acpidump.txt and attach the acpidump.txt file here. Or send them both to me directly at hdegoede@redhat.com. Note I'm not making any promises here, but I can at least take a quick look. Also I'm quite busy this week so it may be a while before I get back to you.

@jwrdegoede Thanks, of course I understand if you don't have time for this. But in case you can have a quick look, and maybe find something I could check, it would be great.


E.g. you say there is no INT3537 in your DSDT (did you also check the SSDTs?) but since you do have a i2c-INT3537:00 device you clearly have an ACPI device in your tables with a INT3537 HID and this is also why the hi556 module is loading.

I now figured out, I don't have the ov2740 sensor. The camera is advertised as 5Mp and ov2740 is below that, I also booted windows and looked in the device manager. I have the hi556 sensor in my device!

This means that the loading of the kernel module is indeed ok. The entries shown by doing a grep -A9 "INT3537" dsdt.dsl on the dst table are obviously misleading and are not activated.


ls -l /sys/bus/i2c/devices/INT3537:00/

And see if there is a driver symlink in there ? And the same for the other i2c-devices.

There is a symlink:

jfq@jeffreyhp:~$ ls -l /sys/bus/i2c/devices/i2c-INT3537\:00
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-INT3537:00 -> ../../../devices/pci0000:00/0000:00:19.0/i2c_designware.4/i2c-5/i2c-INT3537:00

These are the symlinks of the other devices:

jfq@jeffreyhp:~$ ls -l /sys/bus/i2c/devices/i2c-*
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-0 -> ../../../devices/pci0000:00/0000:00:1f.4/i2c-0
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-1 -> ../../../devices/pci0000:00/0000:00:10.0/i2c_designware.0/i2c-1
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-10 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-10
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-11 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-11
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-12 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-12
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-13 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-13
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-14 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-14
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-15 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-eDP-1/i2c-15
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-16 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-1/i2c-16
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-17 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-2/i2c-17
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-18 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-3/i2c-18
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-19 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-4/i2c-19
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-2 -> ../../../devices/pci0000:00/0000:00:10.1/i2c_designware.1/i2c-2
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-20 -> ../../../devices/pci0000:00/0000:00:02.0/drm/card0/card0-DP-5/i2c-20
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-3 -> ../../../devices/pci0000:00/0000:00:15.0/i2c_designware.2/i2c-3
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-4 -> ../../../devices/pci0000:00/0000:00:15.1/i2c_designware.3/i2c-4
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-5 -> ../../../devices/pci0000:00/0000:00:19.0/i2c_designware.4/i2c-5
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-6 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-6
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-7 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-7
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-8 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-8
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-9 -> ../../../devices/pci0000:00/0000:00:02.0/i2c-9
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-ELAN2513:00 -> ../../../devices/pci0000:00/0000:00:15.1/i2c_designware.3/i2c-4/i2c-ELAN2513:00
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-INT3537:00 -> ../../../devices/pci0000:00/0000:00:19.0/i2c_designware.4/i2c-5/i2c-INT3537:00
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-OVTI00AB:00 -> ../../../devices/pci0000:00/0000:00:10.1/i2c_designware.1/i2c-2/i2c-OVTI00AB:00
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-SYNA32C0:00 -> ../../../devices/pci0000:00/0000:00:15.0/i2c_designware.2/i2c-3/i2c-SYNA32C0:00
lrwxrwxrwx 1 root root 0 Nov  2 10:05 /sys/bus/i2c/devices/i2c-TXNW3643:01 -> ../../../devices/pci0000:00/0000:00:10.1/i2c_designware.1/i2c-2/i2c-TXNW3643:01

Can you attach a full dmesg output from after your latest attempt here? And also please run sudo acpidump -o acpidump.txt and attach the acpidump.txt file here. Or send them both to me directly at hdegoede@redhat.com. Note I'm not making any promises here, but I can at least take a quick look. Also I'm quite busy this week so it may be a while before I get back to you.

dmesg output: dmesg.txt sudo acpidump -o acpidump.txt: There is a file-size limit, I will send the two files via e-mail


@jeffreyfq Also please run: cat /sys/bus/i2c/devices/INT3537:00/firmware_node/path and let us know what the output is? This will tell us which "Device (NAME0000) {}" in the ACPI tables corresponds to the hi556 sensor. Typically a "Device (LNK0) {}" entry in the tables belongs to the main sensor.

This is the path (I can see the same path in the windows device manager for the sensor)

jfq@jeffreyhp:~$ cat /sys/bus/i2c/devices/i2c-INT3537\:00/firmware_node/path 
\_SB_.PC00.LNK0

This is the output of gstreamer:

jfq@jeffreyhp:~$ GST_DEBUG=4 sudo -E gst-launch-1.0 icamerasrc buffer-count=7 ! video/x-raw,format=NV12,width=1280,height=720 ! videoconvert ! ximagesink
[sudo] password for jfq: 
0:00:00.000031502 10024 0x556faa543800 INFO                GST_INIT gst.c:592:init_pre: Initializing GStreamer Core Library version 1.20.3
0:00:00.000047469 10024 0x556faa543800 INFO                GST_INIT gst.c:593:init_pre: Using library installed in /usr/lib/x86_64-linux-gnu
0:00:00.000051946 10024 0x556faa543800 INFO                GST_INIT gst.c:611:init_pre: Linux jeffreyhp 6.0.5 #5 SMP PREEMPT_DYNAMIC Wed Nov 2 00:17:15 JST 2022 x86_64
0:00:00.000166308 10024 0x556faa543800 INFO                GST_INIT gstmessage.c:129:_priv_gst_message_initialize: init messages
0:00:00.000376037 10024 0x556faa543800 INFO                GST_INIT gstcontext.c:86:_priv_gst_context_initialize: init contexts
0:00:00.000480935 10024 0x556faa543800 INFO      GST_PLUGIN_LOADING gstplugin.c:324:_priv_gst_plugin_initialize: registering 0 static plugins
0:00:00.000538417 10024 0x556faa543800 INFO      GST_PLUGIN_LOADING gstplugin.c:232:gst_plugin_register_static: registered static plugin "staticelements"
0:00:00.000541654 10024 0x556faa543800 INFO      GST_PLUGIN_LOADING gstplugin.c:234:gst_plugin_register_static: added static plugin "staticelements", result: 1
0:00:00.000581239 10024 0x556faa543800 INFO            GST_REGISTRY gstregistry.c:1827:ensure_current_registry: reading registry cache: /home/jfq/.cache/gstreamer-1.0/registry.x86_64.bin
0:00:00.006684863 10024 0x556faa543800 INFO            GST_REGISTRY gstregistrybinary.c:683:priv_gst_registry_binary_read_cache: loaded /home/jfq/.cache/gstreamer-1.0/registry.x86_64.bin in 0.006090 seconds
0:00:00.006716704 10024 0x556faa543800 INFO            GST_REGISTRY gstregistry.c:1693:scan_and_update_registry: Validating plugins from registry cache: /home/jfq/.cache/gstreamer-1.0/registry.x86_64.bin
0:00:00.007479082 10024 0x556faa543800 INFO            GST_REGISTRY gstregistry.c:1785:scan_and_update_registry: Registry cache has not changed
0:00:00.007483835 10024 0x556faa543800 INFO            GST_REGISTRY gstregistry.c:1862:ensure_current_registry: registry reading and updating done, result = 1
0:00:00.007486497 10024 0x556faa543800 INFO                GST_INIT gst.c:833:init_post: GLib runtime version: 2.74.0
0:00:00.007489548 10024 0x556faa543800 INFO                GST_INIT gst.c:835:init_post: GLib headers version: 2.72.2
0:00:00.007490968 10024 0x556faa543800 INFO                GST_INIT gst.c:837:init_post: initialized GStreamer successfully
0:00:00.007501758 10024 0x556faa543800 INFO            GST_PIPELINE gstparse.c:344:gst_parse_launch_full: parsing pipeline description 'icamerasrc buffer-count=7 ! video/x-raw,format=NV12,width=1280,height=720 ! videoconvert ! ximagesink '
0:00:00.012734697 10024 0x556faa543800 INFO      GST_PLUGIN_LOADING gstplugin.c:987:_priv_gst_plugin_load_file_for_registry: plugin "/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgsticamerasrc.so" loaded
0:00:00.012743115 10024 0x556faa543800 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:489:gst_element_factory_create_with_properties: creating element "icamerasrc"
0:00:00.012853789 10024 0x556faa543800 INFO              CamBaseSrc gstcambasesrc.cpp:428:gst_cam_base_src_init: DBG: @gst_cam_base_src_init number of added templates=3

0:00:00.012869637 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstelement.c:759:gst_element_add_pad:<GstCamBaseSrc@0x556faa851ec0> adding pad 'src'
0:00:00.012872831 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:1238:gst_camerasrc_init: 

0:00:00.012983484 10024 0x556faa543800 INFO      GST_PLUGIN_LOADING gstplugin.c:987:_priv_gst_plugin_load_file_for_registry: plugin "/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstvideoconvert.so" loaded
0:00:00.012986819 10024 0x556faa543800 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:489:gst_element_factory_create_with_properties: creating element "videoconvert"
0:00:00.013070725 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstelement.c:759:gst_element_add_pad:<GstBaseTransform@0x556faa877b30> adding pad 'sink'
0:00:00.013077032 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstelement.c:759:gst_element_add_pad:<GstBaseTransform@0x556faa877b30> adding pad 'src'
0:00:00.013409820 10024 0x556faa543800 INFO      GST_PLUGIN_LOADING gstplugin.c:987:_priv_gst_plugin_load_file_for_registry: plugin "/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstximagesink.so" loaded
0:00:00.013413508 10024 0x556faa543800 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:489:gst_element_factory_create_with_properties: creating element "ximagesink"
0:00:00.013454881 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstelement.c:759:gst_element_add_pad:<GstBaseSink@0x556faa880330> adding pad 'sink'
0:00:00.013464573 10024 0x556faa543800 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:489:gst_element_factory_create_with_properties: creating element "pipeline"
0:00:00.013503637 10024 0x556faa543800 INFO            GST_PIPELINE gst/parse/grammar.y:683:gst_parse_perform_link: linking some pad of Gstcamerasrc named camerasrc0 to some pad of GstVideoConvert named videoconvert0 (0/0) with caps "video/x-raw, format=(string)NV12, width=(int)1280, height=(int)720"
0:00:00.013674078 10024 0x556faa543800 INFO      GST_PLUGIN_LOADING gstplugin.c:987:_priv_gst_plugin_load_file_for_registry: plugin "/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstcoreelements.so" loaded
0:00:00.013676687 10024 0x556faa543800 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:489:gst_element_factory_create_with_properties: creating element "capsfilter"
0:00:00.013694886 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstelement.c:759:gst_element_add_pad:<GstBaseTransform@0x556faa888290> adding pad 'sink'
0:00:00.013698433 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstelement.c:759:gst_element_add_pad:<GstBaseTransform@0x556faa888290> adding pad 'src'
0:00:00.013702086 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2069:gst_bin_get_state_func:<pipeline0> getting state
0:00:00.013709000 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<capsfilter0> completed state change to NULL
0:00:00.013715150 10024 0x556faa543800 INFO               GST_EVENT gstevent.c:1660:gst_event_new_reconfigure: creating reconfigure event
0:00:00.013721972 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstutils.c:1816:gst_element_link_pads_full: trying to link element camerasrc0:(any) to element capsfilter0:sink
0:00:00.013725846 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstelement.c:1016:gst_element_get_static_pad: found pad capsfilter0:sink
0:00:00.013729843 10024 0x556faa543800 INFO                GST_PADS gstutils.c:1632:prepare_link_maybe_ghosting: camerasrc0 and capsfilter0 in same bin, no need for ghost pads
0:00:00.013737152 10024 0x556faa543800 INFO                GST_PADS gstpad.c:2382:gst_pad_link_prepare: trying to link camerasrc0:src and capsfilter0:sink
0:00:00.013742321 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2950:gst_camerasrc_query: CameraId=0, handling caps query.
0:00:00.013745314 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2792:gst_camerasrc_get_caps: CameraId=0.
0:00:00.013750221 10024 0x556faa543800 INFO                GST_PADS gstpad.c:4357:gst_pad_peer_query:<capsfilter0:src> pad has no peer
0:00:00.013755952 10024 0x556faa543800 INFO                GST_PADS gstpad.c:2590:gst_pad_link_full: linked camerasrc0:src and capsfilter0:sink, successful
0:00:00.013758154 10024 0x556faa543800 INFO               GST_EVENT gstevent.c:1660:gst_event_new_reconfigure: creating reconfigure event
0:00:00.013761188 10024 0x556faa543800 INFO               GST_EVENT gstpad.c:5946:gst_pad_send_event_unchecked:<camerasrc0:src> Received event on flushing pad. Discarding
0:00:00.013766188 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstutils.c:1816:gst_element_link_pads_full: trying to link element capsfilter0:src to element videoconvert0:(any)
0:00:00.013769109 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstelement.c:1016:gst_element_get_static_pad: found pad capsfilter0:src
0:00:00.013772461 10024 0x556faa543800 INFO                GST_PADS gstutils.c:1079:gst_pad_check_link: trying to link capsfilter0:src and videoconvert0:sink
0:00:00.013776579 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2950:gst_camerasrc_query: CameraId=0, handling caps query.
0:00:00.013778973 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2792:gst_camerasrc_get_caps: CameraId=0.
0:00:00.013784278 10024 0x556faa543800 INFO                GST_PADS gstpad.c:4357:gst_pad_peer_query:<videoconvert0:src> pad has no peer
0:00:00.013868181 10024 0x556faa543800 INFO                GST_PADS gstutils.c:1632:prepare_link_maybe_ghosting: capsfilter0 and videoconvert0 in same bin, no need for ghost pads
0:00:00.013872037 10024 0x556faa543800 INFO                GST_PADS gstpad.c:2382:gst_pad_link_prepare: trying to link capsfilter0:src and videoconvert0:sink
0:00:00.013875270 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2950:gst_camerasrc_query: CameraId=0, handling caps query.
0:00:00.013877552 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2792:gst_camerasrc_get_caps: CameraId=0.
0:00:00.013881834 10024 0x556faa543800 INFO                GST_PADS gstpad.c:4357:gst_pad_peer_query:<videoconvert0:src> pad has no peer
0:00:00.013955985 10024 0x556faa543800 INFO                GST_PADS gstpad.c:2590:gst_pad_link_full: linked capsfilter0:src and videoconvert0:sink, successful
0:00:00.013958355 10024 0x556faa543800 INFO               GST_EVENT gstevent.c:1660:gst_event_new_reconfigure: creating reconfigure event
0:00:00.013960421 10024 0x556faa543800 INFO               GST_EVENT gstpad.c:5946:gst_pad_send_event_unchecked:<capsfilter0:src> Received event on flushing pad. Discarding
0:00:00.013965954 10024 0x556faa543800 INFO            GST_PIPELINE gst/parse/grammar.y:683:gst_parse_perform_link: linking some pad of GstVideoConvert named videoconvert0 to some pad of GstXImageSink named ximagesink0 (0/0) with caps "(NULL)"
0:00:00.013968968 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstutils.c:1816:gst_element_link_pads_full: trying to link element videoconvert0:(any) to element ximagesink0:(any)
0:00:00.013972301 10024 0x556faa543800 INFO                GST_PADS gstutils.c:1079:gst_pad_check_link: trying to link videoconvert0:src and ximagesink0:sink
0:00:00.013975122 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2950:gst_camerasrc_query: CameraId=0, handling caps query.
0:00:00.013977061 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2792:gst_camerasrc_get_caps: CameraId=0.
0:00:00.014012831 10024 0x556faa543800 INFO                GST_PADS gstutils.c:1632:prepare_link_maybe_ghosting: videoconvert0 and ximagesink0 in same bin, no need for ghost pads
0:00:00.014016650 10024 0x556faa543800 INFO                GST_PADS gstpad.c:2382:gst_pad_link_prepare: trying to link videoconvert0:src and ximagesink0:sink
0:00:00.014019556 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2950:gst_camerasrc_query: CameraId=0, handling caps query.
0:00:00.014021838 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2792:gst_camerasrc_get_caps: CameraId=0.
0:00:00.014053127 10024 0x556faa543800 INFO                GST_PADS gstpad.c:2590:gst_pad_link_full: linked videoconvert0:src and ximagesink0:sink, successful
0:00:00.014055540 10024 0x556faa543800 INFO               GST_EVENT gstevent.c:1660:gst_event_new_reconfigure: creating reconfigure event
0:00:00.014057805 10024 0x556faa543800 INFO               GST_EVENT gstpad.c:5946:gst_pad_send_event_unchecked:<videoconvert0:src> Received event on flushing pad. Discarding
Setting pipeline to PAUSED ...
0:00:00.014086136 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<ximagesink0> current NULL pending VOID_PENDING, desired next READY
0:00:00.015236725 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<ximagesink0> completed state change to READY
0:00:00.015246974 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<ximagesink0> notifying about state-changed NULL to READY (VOID_PENDING pending)
0:00:00.015256811 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'ximagesink0' changed state to 2(READY) successfully
0:00:00.015261829 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<videoconvert0> current NULL pending VOID_PENDING, desired next READY
0:00:00.015264467 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<videoconvert0> completed state change to READY
0:00:00.015267041 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<videoconvert0> notifying about state-changed NULL to READY (VOID_PENDING pending)
0:00:00.015270054 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'videoconvert0' changed state to 2(READY) successfully
0:00:00.015273001 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<capsfilter0> current NULL pending VOID_PENDING, desired next READY
0:00:00.015288510 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<capsfilter0> completed state change to READY
0:00:00.015291032 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<capsfilter0> notifying about state-changed NULL to READY (VOID_PENDING pending)
0:00:00.015294087 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'capsfilter0' changed state to 2(READY) successfully
0:00:00.015297121 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<camerasrc0> current NULL pending VOID_PENDING, desired next READY
0:00:00.015300943 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2890:gst_camerasrc_change_state: CameraId=0, changing state: NULL -> READY.
0:00:00.015303769 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<camerasrc0> completed state change to READY
0:00:00.015306368 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<camerasrc0> notifying about state-changed NULL to READY (VOID_PENDING pending)
0:00:00.015309579 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'camerasrc0' changed state to 2(READY) successfully
0:00:00.015314254 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2778:gst_element_continue_state:<pipeline0> committing state from NULL to READY, pending PAUSED, next PAUSED
0:00:00.015317120 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<pipeline0> notifying about state-changed NULL to READY (PAUSED pending)
0:00:00.015326693 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2786:gst_element_continue_state:<pipeline0> continue state change READY to PAUSED, final PAUSED
0:00:00.015332675 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<ximagesink0> current READY pending VOID_PENDING, desired next PAUSED
0:00:00.015338348 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2935:gst_bin_change_state_func:<pipeline0> child 'ximagesink0' is changing state asynchronously to PAUSED
0:00:00.015341367 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<videoconvert0> current READY pending VOID_PENDING, desired next PAUSED
0:00:00.015345447 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<videoconvert0> completed state change to PAUSED
0:00:00.015348163 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<videoconvert0> notifying about state-changed READY to PAUSED (VOID_PENDING pending)
0:00:00.015356195 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'videoconvert0' changed state to 3(PAUSED) successfully
0:00:00.015359291 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<capsfilter0> current READY pending VOID_PENDING, desired next PAUSED
0:00:00.015362837 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<capsfilter0> completed state change to PAUSED
0:00:00.015365834 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<capsfilter0> notifying about state-changed READY to PAUSED (VOID_PENDING pending)
0:00:00.015369540 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'capsfilter0' changed state to 3(PAUSED) successfully
0:00:00.015372592 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<camerasrc0> current READY pending VOID_PENDING, desired next PAUSED
0:00:00.015375685 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2890:gst_camerasrc_change_state: CameraId=0, changing state: READY -> PAUSED.
0:00:00.015379107 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2820:gst_camerasrc_start: CameraId=0.
0:00:00.015382069 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2828:gst_camerasrc_start: Deinterlace_method=0, io_mode=0 interlace_field=0
[11-02 11:04:12.765] CamHAL[INF] aiqb file name ov13b10.aiqb
[11-02 11:04:12.765] CamHAL[ERR] there is no aiqb file:ov13b10
[11-02 11:04:12.765] CamHAL[INF] aiqb file name ov13b10.aiqb
[11-02 11:04:12.765] CamHAL[ERR] there is no aiqb file:ov13b10
[11-02 11:04:12.765] CamHAL[INF] aiqb file name ov8856.aiqb
[11-02 11:04:12.765] CamHAL[ERR] there is no aiqb file:ov8856
[11-02 11:04:12.765] CamHAL[INF] aiqb file name ov8856.aiqb
[11-02 11:04:12.765] CamHAL[ERR] there is no aiqb file:ov8856
[11-02 11:04:12.765] CamHAL[INF] aiqb file name ov01a10.aiqb
[11-02 11:04:12.765] CamHAL[INF] aiqb file name ov01a10.aiqb
[11-02 11:04:12.765] CamHAL[INF] aiqb file name ov01a10.aiqb
[11-02 11:04:12.766] CamHAL[INF] aiqb file name ov01a10.aiqb
[11-02 11:04:12.766] CamHAL[INF] aiqb file name OV02C10_1BG203N3_ADL.aiqb
[11-02 11:04:12.766] CamHAL[INF] aiqb file name OV02C10_1BG203N3_ADL.aiqb
[11-02 11:04:12.766] CamHAL[INF] aiqb file name OV2740_CJFLE23_ADL.aiqb
[11-02 11:04:12.766] CamHAL[INF] aiqb file name OV2740_CJFLE23_ADL.aiqb
[11-02 11:04:12.766] CamHAL[INF] aiqb file name HM2170_1SG205N3_ADL.aiqb
[11-02 11:04:12.766] CamHAL[INF] aiqb file name HM2170_1SG205N3_ADL.aiqb
[11-02 11:04:12.766] CamHAL[INF] aiqb file name hi556.aiqb
[11-02 11:04:12.766] CamHAL[INF] aiqb file name hi556.aiqb
[11-02 11:04:12.766] CamHAL[INF] aiqb file name ov01a1s.aiqb
[11-02 11:04:12.766] CamHAL[INF] aiqb file name ov01a1s.aiqb
[11-02 11:04:12.766] CamHAL[ERR] Failed to find DevName for cameraId: 0, get video node: ov13b10 , devname: /dev/v4l-subdev1
0:00:00.192074434 10024 0x556faa543800 INFO              CamBaseSrc gstcambasesrc.cpp:1347:gst_cam_base_src_do_seek:<camerasrc0> seeking: time segment start=0:00:00.000000000, offset=0:00:00.000000000, stop=99:99:99.999999999, rate=1.000000, applied_rate=1.000000, flags=0x00, time=0:00:00.000000000, base=0:00:00.000000000, position 0:00:00.000000000, duration 99:99:99.999999999
0:00:00.192108757 10024 0x556faa543800 INFO                    task gsttask.c:516:gst_task_set_lock: setting stream lock 0x556faa854120 on task 0x556fb03ee050
0:00:00.192115384 10024 0x556faa543800 INFO                GST_PADS gstpad.c:6291:gst_pad_start_task:<camerasrc0:src> created task 0x556fb03ee050
0:00:00.192166951 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<camerasrc0> completed state change to PAUSED
0:00:00.192172810 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<camerasrc0> notifying about state-changed READY to PAUSED (VOID_PENDING pending)
0:00:00.192183149 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2971:gst_bin_change_state_func:<pipeline0> child 'camerasrc0' changed state to 3(PAUSED) successfully without preroll
0:00:00.192189159 10024 0x556faa543800 INFO                pipeline gstpipeline.c:533:gst_pipeline_change_state:<pipeline0> pipeline is live
0:00:00.192191513 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<pipeline0> completed state change to PAUSED
0:00:00.192194210 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<pipeline0> notifying about state-changed READY to PAUSED (VOID_PENDING pending)
Pipeline is live and does not need PREROLL ...
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
0:00:00.192339082 10024 0x556faa86d520 INFO        GST_ELEMENT_PADS gstelement.c:1013:gst_element_get_static_pad: no such pad 'sink' in element "camerasrc0"
0:00:00.192356027 10024 0x556faa86d520 INFO              icamerasrc gstcamerasrc.cpp:2950:gst_camerasrc_query: CameraId=0, handling uri query.
0:00:00.192358749 10024 0x556faa543800 INFO               GST_EVENT gstevent.c:1530:gst_event_new_latency: creating latency event 0:00:00.000000000
0:00:00.192362273 10024 0x556faa86d520 FIXME                default gstutils.c:4025:gst_pad_create_stream_id_internal:<camerasrc0:src> Creating random stream-id, consider implementing a deterministic way of creating a stream-id
0:00:00.192367473 10024 0x556faa543800 INFO                     bin gstbin.c:2759:gst_bin_do_latency_func:<pipeline0> configured latency of 0:00:00.000000000
0:00:00.192378612 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<ximagesink0> current READY pending PAUSED, desired next PLAYING
0:00:00.192382511 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2935:gst_bin_change_state_func:<pipeline0> child 'ximagesink0' is changing state asynchronously to PLAYING
0:00:00.192387110 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<videoconvert0> current PAUSED pending VOID_PENDING, desired next PLAYING
0:00:00.192390264 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<videoconvert0> completed state change to PLAYING
0:00:00.192393225 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<videoconvert0> notifying about state-changed PAUSED to PLAYING (VOID_PENDING pending)
0:00:00.192397203 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'videoconvert0' changed state to 4(PLAYING) successfully
0:00:00.192403131 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<capsfilter0> current PAUSED pending VOID_PENDING, desired next PLAYING
0:00:00.192406001 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<capsfilter0> completed state change to PLAYING
0:00:00.192408881 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<capsfilter0> notifying about state-changed PAUSED to PLAYING (VOID_PENDING pending)
0:00:00.192413990 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'capsfilter0' changed state to 4(PLAYING) successfully
0:00:00.192415192 10024 0x556faa86d520 INFO              icamerasrc gstcamerasrc.cpp:2969:gst_camerasrc_negotiate: CameraId=0.
0:00:00.192418056 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2890:gst_camerasrc_change_state: CameraId=0, changing state: PAUSED -> PLAYING.
0:00:00.192422442 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<camerasrc0> completed state change to PLAYING
0:00:00.192425831 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<camerasrc0> notifying about state-changed PAUSED to PLAYING (VOID_PENDING pending)
0:00:00.192429909 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'camerasrc0' changed state to 4(PLAYING) successfully
0:00:00.192421009 10024 0x556faa86d520 INFO              icamerasrc gstcamerasrc.cpp:2950:gst_camerasrc_query: CameraId=0, handling caps query.
0:00:00.192449375 10024 0x556faa86d520 INFO              icamerasrc gstcamerasrc.cpp:2792:gst_camerasrc_get_caps: CameraId=0.
New clock: GstSystemClock
0:00:00.192537198 10024 0x556faa86d520 INFO              icamerasrc gstcamerasrc.cpp:2928:gst_camerasrc_fixate: CameraId=0.
0:00:00.192545776 10024 0x556faa86d520 INFO              CamBaseSrc gstcambasesrc.cpp:889:gst_cam_base_src_set_caps: pad:src, format:NV12 width:1280 height:720

0:00:00.192551246 10024 0x556faa86d520 INFO              icamerasrc gstcamerasrc.cpp:2653:gst_camerasrc_set_caps: CameraId=0, StreamId=0 name of pad=src Thread Id=10027.
0:00:00.192579743 10024 0x556faa86d520 INFO              icamerasrc gstcamerasrc.cpp:2560:gst_camerasrc_get_caps_info: CameraId=0, StreamId=0 Caps info: format=NV12 width=1280 height=720 field=0 framerate 30/1.
0:00:00.192582713 10024 0x556faa86d520 INFO              icamerasrc gstcamerasrcbufferpool.cpp:172:gst_camerasrc_buffer_pool_new: CameraId=0 StreamId=0.
0:00:00.192628921 10024 0x556faa86d520 INFO              icamerasrc gstcamerasrcbufferpool.cpp:248:gst_camerasrc_buffer_pool_set_config: CameraId=0, StreamId=0.
0:00:00.192634910 10024 0x556faa86d520 INFO              icamerasrc gstcamerasrcbufferpool.cpp:236:gst_camerasrc_buffer_pool_new: CameraId=0, StreamId=0 Buffer pool config: min buffers=2, max buffers=10, buffer bpl=1280, bpp=12, size=1384320
0:00:00.192639406 10024 0x556faa86d520 INFO              icamerasrc gstcamerasrc.cpp:2733:gst_camerasrc_set_caps: CameraId=0, streamId=0 input format: NULL(fourcc=-1).input width:=0, input height=0.
0:00:00.192641993 10024 0x556faa86d520 INFO              icamerasrc gstcamerasrc.cpp:2746:gst_camerasrc_set_caps: camera stream usage: i=[0], stream_usage=[0], src_stream_usate=[0].
[11-02 11:04:12.772] CamHAL[ERR] Get entity fail for calling getEntityById
[11-02 11:04:12.772] CamHAL[ERR] Get entity fail for calling getEntityById
[11-02 11:04:12.772] CamHAL[ERR] setup Link ov13b10  [-1:0] ==> Intel IPU6 CSI-2  [-1x0] enable 1 failed.
[11-02 11:04:12.772] CamHAL[ERR] set MediaCtlConf McLink failed: ret = -1
[11-02 11:04:12.772] CamHAL[ERR] set up mediaCtl failed
[11-02 11:04:12.772] CamHAL[ERR] @configure Device Configure failed
[11-02 11:04:12.772] CamHAL[ERR] failed to config streams.
0:00:00.195931507 10024 0x556faa86d520 ERROR             icamerasrc gstcamerasrc.cpp:2763:gst_camerasrc_set_caps: CameraId=0, StreamId=0 failed to config stream for format NV12 1280x720.
0:00:00.195942223 10024 0x556faa86d520 WARN              CamBaseSrc gstcambasesrc.cpp:3143:gst_cam_base_src_loop:<camerasrc0> error: src pad: Internal data flow error.
0:00:00.195946960 10024 0x556faa86d520 WARN              CamBaseSrc gstcambasesrc.cpp:3143:gst_cam_base_src_loop:<camerasrc0> error: streaming task paused, reason not-negotiated (-4)
0:00:00.195954033 10024 0x556faa86d520 INFO        GST_ERROR_SYSTEM gstelement.c:2271:gst_element_message_full_with_details:<camerasrc0> posting message: src pad: Internal data flow error.
ERROR: from element /GstPipeline:pipeline0/Gstcamerasrc:camerasrc0: src pad: Internal data flow error.
Additional debug info:
gstcambasesrc.cpp(3143): gst_cam_base_src_loop (): /GstPipeline:pipeline0/Gstcamerasrc:camerasrc0:
streaming task paused, reason not-negotiated (-4)
0:00:00.195988127 10024 0x556faa86d520 INFO        GST_ERROR_SYSTEM gstelement.c:2298:gst_element_message_full_with_details:<camerasrc0> posted error message: src pad: Internal data flow error.
Execution ended after 0:00:00.003733476
Setting pipeline to NULL ...
0:00:00.196029336 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<ximagesink0> current PAUSED pending VOID_PENDING, desired next READY
0:00:00.196107859 10024 0x556faa86d520 INFO                    task gsttask.c:368:gst_task_func:<camerasrc0:src> Task going to paused
0:00:00.196164394 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<ximagesink0> completed state change to READY
0:00:00.196175896 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<ximagesink0> notifying about state-changed PAUSED to READY (VOID_PENDING pending)
0:00:00.196181997 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'ximagesink0' changed state to 2(READY) successfully
0:00:00.196187024 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<videoconvert0> current PLAYING pending VOID_PENDING, desired next READY
0:00:00.196191881 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2778:gst_element_continue_state:<videoconvert0> committing state from PLAYING to PAUSED, pending READY, next READY
0:00:00.196195426 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<videoconvert0> notifying about state-changed PLAYING to PAUSED (READY pending)
0:00:00.196198555 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2786:gst_element_continue_state:<videoconvert0> continue state change PAUSED to READY, final READY
0:00:00.196204736 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<videoconvert0> completed state change to READY
0:00:00.196207498 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<videoconvert0> notifying about state-changed PAUSED to READY (VOID_PENDING pending)
0:00:00.196211264 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'videoconvert0' changed state to 2(READY) successfully
0:00:00.196214408 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<capsfilter0> current PLAYING pending VOID_PENDING, desired next READY
0:00:00.196217572 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2778:gst_element_continue_state:<capsfilter0> committing state from PLAYING to PAUSED, pending READY, next READY
0:00:00.196220202 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<capsfilter0> notifying about state-changed PLAYING to PAUSED (READY pending)
0:00:00.196223191 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2786:gst_element_continue_state:<capsfilter0> continue state change PAUSED to READY, final READY
0:00:00.196227676 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<capsfilter0> completed state change to READY
0:00:00.196230227 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<capsfilter0> notifying about state-changed PAUSED to READY (VOID_PENDING pending)
0:00:00.196233326 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'capsfilter0' changed state to 2(READY) successfully
0:00:00.196236177 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<camerasrc0> current PLAYING pending VOID_PENDING, desired next READY
0:00:00.196239736 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2890:gst_camerasrc_change_state: CameraId=0, changing state: PLAYING -> PAUSED.
0:00:00.196243612 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2778:gst_element_continue_state:<camerasrc0> committing state from PLAYING to PAUSED, pending READY, next READY
0:00:00.196246255 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<camerasrc0> notifying about state-changed PLAYING to PAUSED (READY pending)
0:00:00.196249355 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2786:gst_element_continue_state:<camerasrc0> continue state change PAUSED to READY, final READY
0:00:00.196251910 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2890:gst_camerasrc_change_state: CameraId=0, changing state: PAUSED -> READY.
0:00:00.196308305 10024 0x556faa86d520 INFO                    task gsttask.c:370:gst_task_func:<camerasrc0:src> Task resume from paused
0:00:00.196324352 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2863:gst_camerasrc_stop: CameraId=0.
0:00:00.221351741 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<camerasrc0> completed state change to READY
0:00:00.221365311 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<camerasrc0> notifying about state-changed PAUSED to READY (VOID_PENDING pending)
0:00:00.221374694 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'camerasrc0' changed state to 2(READY) successfully
0:00:00.221382481 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2778:gst_element_continue_state:<pipeline0> committing state from PAUSED to READY, pending NULL, next NULL
0:00:00.221384992 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<pipeline0> notifying about state-changed PAUSED to READY (NULL pending)
0:00:00.221403738 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2786:gst_element_continue_state:<pipeline0> continue state change READY to NULL, final NULL
0:00:00.221413488 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<ximagesink0> current READY pending VOID_PENDING, desired next NULL
0:00:00.306119158 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<ximagesink0> completed state change to NULL
0:00:00.306137687 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<ximagesink0> notifying about state-changed READY to NULL (VOID_PENDING pending)
0:00:00.306151539 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'ximagesink0' changed state to 1(NULL) successfully
0:00:00.306160251 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<videoconvert0> current READY pending VOID_PENDING, desired next NULL
0:00:00.306166428 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<videoconvert0> completed state change to NULL
0:00:00.306168911 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<videoconvert0> notifying about state-changed READY to NULL (VOID_PENDING pending)
0:00:00.306196585 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'videoconvert0' changed state to 1(NULL) successfully
0:00:00.306200053 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<capsfilter0> current READY pending VOID_PENDING, desired next NULL
0:00:00.306202795 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<capsfilter0> completed state change to NULL
0:00:00.306205075 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<capsfilter0> notifying about state-changed READY to NULL (VOID_PENDING pending)
0:00:00.306208288 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'capsfilter0' changed state to 1(NULL) successfully
0:00:00.306210623 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2479:gst_bin_element_set_state:<camerasrc0> current READY pending VOID_PENDING, desired next NULL
0:00:00.306215454 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:2890:gst_camerasrc_change_state: CameraId=0, changing state: READY -> NULL.
0:00:00.306220344 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<camerasrc0> completed state change to NULL
0:00:00.306222497 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<camerasrc0> notifying about state-changed READY to NULL (VOID_PENDING pending)
0:00:00.306225312 10024 0x556faa543800 INFO              GST_STATES gstbin.c:2928:gst_bin_change_state_func:<pipeline0> child 'camerasrc0' changed state to 1(NULL) successfully
0:00:00.306274750 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2806:gst_element_continue_state:<pipeline0> completed state change to NULL
0:00:00.306277361 10024 0x556faa543800 INFO              GST_STATES gstelement.c:2706:_priv_gst_element_state_changed:<pipeline0> notifying about state-changed READY to NULL (VOID_PENDING pending)
Freeing pipeline ...
0:00:00.306295889 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstpad.c:2137:gst_pad_unlink: unlinking camerasrc0:src(0x556faa8540b0) and capsfilter0:sink(0x556faa8549f0)
0:00:00.306301592 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstpad.c:2192:gst_pad_unlink: unlinked camerasrc0:src and capsfilter0:sink
0:00:00.306304873 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstpad.c:2137:gst_pad_unlink: unlinking capsfilter0:src(0x556faa854c40) and videoconvert0:sink(0x556faa854300)
0:00:00.306307362 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstpad.c:2192:gst_pad_unlink: unlinked capsfilter0:src and videoconvert0:sink
0:00:00.306309731 10024 0x556faa543800 INFO           GST_PARENTAGE gstbin.c:1803:gst_bin_remove_func:<pipeline0> removed child "capsfilter0"
0:00:00.306319224 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3382:gst_element_dispose:<capsfilter0> 0x556faa888290 dispose
0:00:00.306321884 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstelement.c:875:gst_element_remove_pad:<capsfilter0> removing pad 'sink'
0:00:00.306334223 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstelement.c:875:gst_element_remove_pad:<capsfilter0> removing pad 'src'
0:00:00.306337255 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3428:gst_element_dispose:<capsfilter0> 0x556faa888290 parent class dispose
0:00:00.306339862 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3460:gst_element_finalize:<capsfilter0> 0x556faa888290 finalize
0:00:00.306341888 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3465:gst_element_finalize:<capsfilter0> 0x556faa888290 finalize parent
0:00:00.306345099 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstpad.c:2137:gst_pad_unlink: unlinking videoconvert0:src(0x556faa854550) and ximagesink0:sink(0x556faa8547a0)
0:00:00.306348008 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstpad.c:2192:gst_pad_unlink: unlinked videoconvert0:src and ximagesink0:sink
0:00:00.306350544 10024 0x556faa543800 INFO           GST_PARENTAGE gstbin.c:1803:gst_bin_remove_func:<pipeline0> removed child "ximagesink0"
0:00:00.306354282 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3382:gst_element_dispose:<ximagesink0> 0x556faa880330 dispose
0:00:00.306356431 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstelement.c:875:gst_element_remove_pad:<ximagesink0> removing pad 'sink'
0:00:00.306359160 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3428:gst_element_dispose:<ximagesink0> 0x556faa880330 parent class dispose
0:00:00.306377837 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3460:gst_element_finalize:<ximagesink0> 0x556faa880330 finalize
0:00:00.306380338 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3465:gst_element_finalize:<ximagesink0> 0x556faa880330 finalize parent
0:00:00.306383121 10024 0x556faa543800 INFO           GST_PARENTAGE gstbin.c:1803:gst_bin_remove_func:<pipeline0> removed child "videoconvert0"
0:00:00.306386271 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3382:gst_element_dispose:<videoconvert0> 0x556faa877b30 dispose
0:00:00.306388741 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstelement.c:875:gst_element_remove_pad:<videoconvert0> removing pad 'sink'
0:00:00.306392200 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstelement.c:875:gst_element_remove_pad:<videoconvert0> removing pad 'src'
0:00:00.306395112 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3428:gst_element_dispose:<videoconvert0> 0x556faa877b30 parent class dispose
0:00:00.306398288 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3460:gst_element_finalize:<videoconvert0> 0x556faa877b30 finalize
0:00:00.306400290 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3465:gst_element_finalize:<videoconvert0> 0x556faa877b30 finalize parent
0:00:00.306404457 10024 0x556faa543800 INFO           GST_PARENTAGE gstbin.c:1803:gst_bin_remove_func:<pipeline0> removed child "camerasrc0"
0:00:00.306407738 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:888:gst_camerasrc_dispose: CameraId=0.
0:00:00.306409864 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3382:gst_element_dispose:<camerasrc0> 0x556faa851ec0 dispose
0:00:00.306412410 10024 0x556faa543800 INFO        GST_ELEMENT_PADS gstelement.c:875:gst_element_remove_pad:<camerasrc0> removing pad 'src'
0:00:00.306415291 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3428:gst_element_dispose:<camerasrc0> 0x556faa851ec0 parent class dispose
0:00:00.306417767 10024 0x556faa543800 INFO              icamerasrc gstcamerasrc.cpp:896:gst_camerasrc_finalize: CameraId=0.
0:00:00.306427004 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3460:gst_element_finalize:<camerasrc0> 0x556faa851ec0 finalize
0:00:00.306429494 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3465:gst_element_finalize:<camerasrc0> 0x556faa851ec0 finalize parent
0:00:00.306432145 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3382:gst_element_dispose:<pipeline0> 0x556faa882120 dispose
0:00:00.306448248 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3428:gst_element_dispose:<pipeline0> 0x556faa882120 parent class dispose
0:00:00.306450418 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3460:gst_element_finalize:<pipeline0> 0x556faa882120 finalize
0:00:00.306452753 10024 0x556faa543800 INFO         GST_REFCOUNTING gstelement.c:3465:gst_element_finalize:<pipeline0> 0x556faa882120 finalize parent
0:00:00.306456376 10024 0x556faa543800 INFO                GST_INIT gst.c:1124:gst_deinit: deinitializing GStreamer
0:00:00.307620642 10024 0x556faa543800 INFO                GST_INIT gst.c:1268:gst_deinit: deinitialized GStreamer
jfq@jeffreyhp:~$ 

The first error is ERROR icamerasrc gstcamerasrc.cpp:2763:gst_camerasrc_set_caps: CameraId=0, StreamId=0 failed to config stream for format NV12 1280x720 but the stream format should be working according to instructions on https://github.com/intel/icamerasrc/tree/icamerasrc_slim_api I also tried the native resolution of the sensor without success.


As a summary:

Ipu-related dmesg looks promising:

[    5.395959] intel-ipu6 intel-ipu: IPC reset done
[    5.395964] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[    5.397349] input: Intel HID events as /devices/platform/INTC1070:00/input/input20
[    5.397516] intel-ipu6 intel-ipu: FW version: 20220510
[    5.398061] intel-hid INTC1070:00: platform supports 5 button array
[    5.398469] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[    5.398492] intel-ipu6 intel-ipu: physical base address 0x612c000000
[    5.398494] intel-ipu6 intel-ipu: mapped as: 0x000000008c68d292
[    5.398555] intel-ipu6 intel-ipu: IPU in secure mode
[    5.398557] intel-ipu6 intel-ipu: IPU secure touch = 0x80000000
[    5.398558] intel-ipu6 intel-ipu: IPU camera mask = 0x0
[    5.399564] input: Intel HID 5 button array as /devices/platform/INTC1070:00/input/input21
[    5.400640] Consider using thermal netlink events interface
[    5.401296] intel-ipu6 intel-ipu: IPC reset done
[    5.401298] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[    5.401404] intel-ipu6 intel-ipu: FW version: 20220510
[    5.403190] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[    5.403211] intel-ipu6 intel-ipu: physical base address 0x612c000000
[    5.403213] intel-ipu6 intel-ipu: mapped as: 0x00000000e78537ec
[    5.403262] intel-ipu6 intel-ipu: IPU in secure mode
[    5.403264] intel-ipu6 intel-ipu: IPU secure touch = 0x80000000
[    5.403266] intel-ipu6 intel-ipu: IPU camera mask = 0x0
[    5.404153] intel_rapl_common: Found RAPL domain package
[    5.405652] intel-ipu6 intel-ipu: IPC reset done
[    5.405656] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[    5.405777] intel-ipu6 intel-ipu: FW version: 20220510
[    5.409736] int3472-discrete INT3472:01: JFQ sensor name is i2c-INT3537:00 (discrete.c) <-- I added this for debug!!
[    5.410317] int3472-discrete INT3472:01: Check string for module named CJFKE26 <-- I added this for debug!!
[    5.411116] int3472-discrete INT3472:01: JFQ resource type  INT3472_GPIO_TYPE_RESET<-- I added this for debug!!
[    5.411264] int3472-discrete INT3472:01: JFQ resource type  INT3472_GPIO_TYPE_POWER_ENABLE <-- I added this for debug!!
[    5.411772] intel-ipu6 intel-ipu: Device 0x465d (rev: 0x2)
[    5.411800] intel-ipu6 intel-ipu: physical base address 0x612c000000
[    5.411801] intel-ipu6 intel-ipu: mapped as: 0x000000008c68d292
[    5.411851] intel-ipu6 intel-ipu: IPU in secure mode
[    5.411855] intel-ipu6 intel-ipu: IPU secure touch = 0x80000000
[    5.411857] intel-ipu6 intel-ipu: IPU camera mask = 0x0
[    5.412271] int3472-discrete INT3472:01: JFQ resource type  INT3472_GPIO_TYPE_PRIVACY_LED <-- I added this for debug!!
[    5.412935] int3472-discrete INT3472:01: GPIO type 0x12 unknown; the sensor may not work
[    5.412940] int3472-discrete INT3472:01: No clk GPIO. The privacy LED won't work
[    5.412942] int3472-discrete INT3472:01: JFQ probe return ok (discrete.c)
[    5.413785] intel-ipu6 intel-ipu: IPC reset done
[    5.413788] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[    5.413917] intel-ipu6 intel-ipu: FW version: 20220510
[    5.418037] int3472-discrete INT3472:02: JFQ sensor name is i2c-OVTI00AB:00 (discrete.c)
[    5.418422] intel-ipu6 intel-ipu: Found supported sensor INT3537:00
[    5.418447] int3472-discrete INT3472:02: Check string for module named CJFKE26 <-- I added this for debug!!
[    5.418507] intel-ipu6 intel-ipu: Connected 1 cameras
[    5.419110] int3472-discrete INT3472:02: JFQ resource type  INT3472_GPIO_TYPE_RESET <-- I added this for debug!!
[    5.419229] int3472-discrete INT3472:02: JFQ resource type  INT3472_GPIO_TYPE_POWER_ENABLE <-- I added this for debug!!
[    5.420294] intel-ipu6 intel-ipu: Sending BOOT_LOAD to CSE
[    5.420748] int3472-discrete INT3472:02: JFQ probe return ok (discrete.c)
[    5.430011] intel-ipu6 intel-ipu: Sending AUTHENTICATE_RUN to CSE
[    5.446324] intel-ipu6-psys intel-ipu6-psys0: pkg_dir entry count:8
[    5.446464] intel-ipu6-psys intel-ipu6-psys0: psys probe minor: 0
[    5.487099] mei_me 0000:00:16.0: enabling device (0000 -> 0002)

Later in the dmesg I get the following errors/messages that do not seem right:

intel vsc not ready

and

i2c i2c-INT3537:00: deferred probe pending

This tells me that there might be a dependency the vsc driver is waiting for. I added the latt2021 kernel patch, but I don't have the device. I tried to get a print-out of devices modules wait for. For this purpose I added the following to the drivers/acpi/scan.c to the acpi_scan_check_dep function at around line 1976:

....
        if (skip)
            continue;

        dep = kzalloc(sizeof(*dep), GFP_KERNEL);
        if (!dep)
            continue;

        count++;

        acpi_handle_debug(handle, "JFQ adding acpi _DEP device %s to device\n", info->hardware_id.string);    // <-- HRERE!!!!!!

        dep->supplier = dep_devices.handles[i];
        dep->consumer = handle;
        dep->honor_dep = honor_dep;

        mutex_lock(&acpi_dep_list_lock);
        list_add_tail(&dep->node , &acpi_dep_list);
        mutex_unlock(&acpi_dep_list_lock);
    }

    return count;
}

But I can not see any output in the dmesg of this, could be that there is no acpi device waiting or the acpi_handle_debug does not print to dmesg. Not sure, maybe this is the wrong place to check devices that hinder module loading.


Another thing I wanted to mention, during boot I can see the message:

[    5.409736] int3472-discrete INT3472:01: JFQ sensor name is i2c-INT3537:00 (discrete.c)
...
[    5.412935] int3472-discrete INT3472:01: GPIO type 0x12 unknown; the sensor may not work
[    5.412940] int3472-discrete INT3472:01: No clk GPIO. The privacy LED won't work
[    5.412942] int3472-discrete INT3472:01: JFQ probe return ok (discrete.c)

Modprobing works, but there is the message GPIO type 0x12 unknown; the sensor may not work, so there is a new GPIO type, I confirmed that INT3472_GPIO_TYPE_RESET, INT3472_GPIO_TYPE_POWER_ENABLE, INT3472_GPIO_TYPE_PRIVACY_LED are set. But No clk GPIO. The privacy LED won't work occurs as well.

My suspicion is that the new/unknown GPIO type 0x12 is maybe the physical lid of the sensor that can be closed opened by an electric mechanism (there is a key on the keyboard that physically closes/opens a lid in front of the camera lens). This is maybe why it is not yet defined in the driver. But it is just a guess for now.

fhloston commented 1 year ago

I still fail to use /dev/video0 with vlc or firefox with v4l2loopback and v4l2-relayd

With vlc and trying to playback /dev/video0 at least the camera led turns on, but i see no picture. I see vlc detecting YUV format - even though i have set the format to NV12.

Any ideas what I could be holding wrong?

Update: OK, I have been holding it wrong, cheese and zoom just work. Update2: https://bugzilla.mozilla.org/show_bug.cgi?id=1761519

drogenlied commented 1 year ago

@fhloston as a workaround for the NV12 issue you can edit the v4l-relayd.service file, check my comment https://github.com/intel/ipu6-drivers/issues/48#issuecomment-1296241668

csdvrx commented 1 year ago

Maybe it is contained in the DSDT, but not verbatim, so I just added dev_info(int3472->dev, "Sensor _DSM: %s\n", obj->string.pointer); to skl_int3472_get_sensor_module_config(...) and saved the work of figuring out where that string ultimately comes from. (...) and changed ov9734_acpi_ids[] in drivers/media/i2c/ov9734.c  

That's a very practical way to do it, but the solution may not scalable as you will only find the _DSM for the precise version of the camera you're using.

For example, the Nano has 2 different _DSM for each camera, depending if the screen is touchscreen enabled or not

/ Lenovo ThinkPad X1 Yoga Gen7 - OV9234 monochromatic sensor? / { "6BF115T2", { 0 }, NULL, true },

If you have access to the Windows partition, an alternative is to check the .inf files like:

/w11/Windows/System32/DriverStore/FileRepository/ov2740.infamd64 and /w11/Windows/System32/DriverStore/FileRepository/ov9234.infamd64

You will find there the names without much need to experiment:

OV2740:

OV9234:

but the ov9734 sensor driver does not like its monochrome sibling variant and fails with -EINVAL during probing. No crash though.

I think you may be requesting a resolution or a format that's not supported.

Check /win/Windows/System32/drivers/graph_settings_OV9234_6BF115T2_ADL.xml for supported formats, ex:

grep main.format /win/Windows/System32/drivers/graph_settings_OV9234_6BF115T2_ADL.xml
    <main format="YUV420_10_PL" width="640" height="384" />
    <main format="YUV420_8_SP" width="640" height="360" peer="video0" />
    <main format="YUV420_10_PL" width="640" height="384" />
    <main format="YUV420_8_SP" width="640" height="360" peer="video0" />
    <main format="YUV420_10_PL" width="640" height="384" />
    <main format="YUV420_8_SP" width="640" height="360" peer="video0" />
    <main format="YUV420_10_PL" width="640" height="384" />
    <main format="YUV420_8_SP" width="640" height="360" peer="video0" />
    <main format="YUV420_10_PL" width="640" height="384" />
    <main format="YUV420_8_SP" width="640" height="360" peer="still0" />
    <main format="YUV420_10_PL" width="640" height="384" />
    <main format="YUV420_8_SP" width="640" height="360" peer="still0" />
    <main format="YUV420_10_PL" width="640" height="384" />
    <main format="YUV420_8_SP" width="640" height="360" peer="still0" />
    <main format="YUV420_10_PL" width="640" height="384" />
    <main format="YUV420_8_SP" width="640" height="360" peer="still0" />
ctrlcctrlv commented 1 year ago

I'm now here after opening #106.

Thanks for helpful comments.

But I see:

Scope (_SB.PC00.I2C2)
    {
        Device (CAM0)
        {
            Name (_ADR, Zero)  // _ADR: Address
            Name (_HID, "INT3471")  // _HID: Hardware ID
            Name (_CID, "INT3481")  // _CID: Compatible ID
            Name (_DDN, "IMX135-CRDG2")  // _DDN: DOS Device Name
            Name (_UID, "0")  // _UID: Unique ID
            Name (_DEP, Package (0x01)  // _DEP: Dependencies
            {
                PMIC
            })
            Name (_PLD, Package (0x01)  // _PLD: Physical Location of Device
            {
                ToPLD (
                    PLD_Revision           = 0x2,
                    PLD_IgnoreColor        = 0x1,
                    PLD_Red                = 0x0,
                    PLD_Green              = 0x0,
                    PLD_Blue               = 0x0,
                    PLD_Width              = 0x0,
                    PLD_Height             = 0x0,
                    PLD_UserVisible        = 0x1,
                    PLD_Dock               = 0x0,
                    PLD_Lid                = 0x0,
                    PLD_Panel              = "BACK",
                    PLD_VerticalPosition   = "CENTER",
                    PLD_HorizontalPosition = "RIGHT",
                    PLD_Shape              = "VERTICALRECTANGLE",
                    PLD_GroupOrientation   = 0x0,
                    PLD_GroupToken         = 0x0,
                    PLD_GroupPosition      = 0x0,
                    PLD_Bay                = 0x0,
                    PLD_Ejectable          = 0x1,
                    PLD_EjectRequired      = 0x1,
                    PLD_CabinetNumber      = 0x0,
                    PLD_CardCageNumber     = 0x0,
                    PLD_Reference          = 0x0,
                    PLD_Rotation           = 0x0,
                    PLD_Order              = 0x0,
                    PLD_VerticalOffset     = 0xFFFF,
                    PLD_HorizontalOffset   = 0xFFFF)

            })
[...]
Scope (_SB.PC00.I2C4)
    {
        Device (CAM1)
        {
            Name (_ADR, Zero)  // _ADR: Address
            Name (_HID, "INT3474")  // _HID: Hardware ID
            Name (_CID, "INT3484")  // _CID: Compatible ID
            Name (_DDN, "OV2740-CRDG2")  // _DDN: DOS Device Name
            Name (_UID, "0")  // _UID: Unique ID
            Name (_DEP, Package (0x01)  // _DEP: Dependencies
            {
                ^^I2C2.PMIC
            })
            Name (_PLD, Package (0x01)  // _PLD: Physical Location of Device
            {
                ToPLD (
                    PLD_Revision           = 0x2,
                    PLD_IgnoreColor        = 0x1,
                    PLD_Red                = 0x0,
                    PLD_Green              = 0x0,
                    PLD_Blue               = 0x0,
                    PLD_Width              = 0x0,
                    PLD_Height             = 0x0,
                    PLD_UserVisible        = 0x1,
                    PLD_Dock               = 0x0,
                    PLD_Lid                = 0x0,
                    PLD_Panel              = "FRONT",
                    PLD_VerticalPosition   = "CENTER",
                    PLD_HorizontalPosition = "RIGHT",
                    PLD_Shape              = "VERTICALRECTANGLE",
                    PLD_GroupOrientation   = 0x0,
                    PLD_GroupToken         = 0x0,
                    PLD_GroupPosition      = 0x0,
                    PLD_Bay                = 0x0,
                    PLD_Ejectable          = 0x1,
                    PLD_EjectRequired      = 0x1,
                    PLD_CabinetNumber      = 0x0,
                    PLD_CardCageNumber     = 0x0,
                    PLD_Reference          = 0x0,
                    PLD_Rotation           = 0x0,
                    PLD_Order              = 0x0,
                    PLD_VerticalOffset     = 0xFFFF,
                    PLD_HorizontalOffset   = 0xFFFF)

            })

So I have what an Arducam IMX135?? lol

And OV2740-CRDG2 is Omnivision OV2740?

yorik commented 11 months ago

I also have a problem with Lenovo Thinkpad X1 carbon gen 11: it loads, but there is no usable camera, even with kernel 6.4.4 (also for some reason CONFIG_INTEL_SKL_INT3472 is disabled in Debian, so I have to rebuild kernel).

$ grep -A4 '(CAM' dsdt.dsl ``` Device (CAM0) { Name (_HID, "INT3471") // _HID: Hardware ID Name (_DDN, "IMX135-CRDG2") // _DDN: DOS Device Name Name (_UID, "0") // _UID: Unique ID -- Device (CAM1) { Name (_HID, "INT3474") // _HID: Hardware ID Name (_DDN, "OV2740-CRDG2") // _DDN: DOS Device Name Name (_UID, "0") // _UID: Unique ID ```
$ lsmod | grep "ivsc\|ipu\|ov" ``` overlay 184320 0 intel_ipu6_isys 155648 0 videobuf2_dma_contig 24576 1 intel_ipu6_isys videobuf2_v4l2 36864 2 intel_ipu6_isys,uvcvideo videobuf2_common 73728 6 videobuf2_vmalloc,videobuf2_dma_contig,videobuf2_v4l2,intel_ipu6_isys,uvcvideo,videobuf2_memops intel_ipu6_psys 110592 0 intel_ipu6 118784 2 intel_ipu6_isys,intel_ipu6_psys ov2740 24576 1 v4l2_fwnode 32768 2 intel_ipu6_isys,ov2740 v4l2_async 28672 3 v4l2_fwnode,intel_ipu6_isys,ov2740 videodev 327680 7 v4l2_async,v4l2_fwnode,videobuf2_v4l2,v4l2loopback,intel_ipu6_isys,uvcvideo,ov2740 mc 86016 8 v4l2_async,videodev,snd_usb_audio,videobuf2_v4l2,intel_ipu6_isys,uvcvideo,videobuf2_common,ov2740 async_raid6_recov 20480 1 raid456 async_memcpy 16384 2 raid456,async_raid6_recov async_pq 16384 2 raid456,async_raid6_recov async_xor 16384 3 async_pq,raid456,async_raid6_recov async_tx 16384 5 async_pq,async_memcpy,async_xor,raid456,async_raid6_recov raid6_pq 122880 3 async_pq,raid456,async_raid6_recov ```
$ v4l2-ctl --list-devices ``` ipu6 (PCI:pci:pci0000:00): /dev/video1 /dev/video2 /dev/video3 /dev/video4 /dev/video5 /dev/video6 /dev/video7 /dev/video8 ipu6 (pci:pci0000:00): /dev/media0 Intel MIPI Camera (platform:v4l2loopback-000): /dev/video0 ```
$ gst-launch-1.0 icamerasrc device-name=ov2740-uf buffer-count=7 ! video/x-raw,format=NV12,width=1280,height=720 ! videoconvert ! ximagesink ``` Setting pipeline to PAUSED ... [08-14 17:10:17.991] CamHAL[INF] aiqb file name OV2740_CJFLE23_ADL.aiqb [08-14 17:10:17.992] CamHAL[INF] aiqb file name OV2740_CJFLE23_ADL.aiqb [08-14 17:10:17.992] CamHAL[ERR] Open: Failed to open device node /dev/v4l-subdev16 No such device Pipeline is live and does not need PREROLL ... Pipeline is PREROLLED ... Setting pipeline to PLAYING ... New clock: GstSystemClock [08-14 17:10:17.999] CamHAL[ERR] SetFormat: Invaild Device status: 0 [08-14 17:10:17.999] CamHAL[ERR] set format ov2740 12-0036 [225:0] [1932x1092] V4L2_MBUS_FMT_SGRBG10_1X10 failed. [08-14 17:10:17.999] CamHAL[ERR] Open: Failed to open device node /dev/v4l-subdev1 No such device [08-14 17:10:17.999] CamHAL[ERR] SetFormat: Invaild Device status: 0 [08-14 17:10:17.999] CamHAL[ERR] set format Intel IPU6 CSI-2 1 [4:0] [1932x1092] V4L2_MBUS_FMT_SGRBG10_1X10 failed. [08-14 17:10:17.999] CamHAL[ERR] Open: Failed to open device node /dev/v4l-subdev8 No such device [08-14 17:10:17.999] CamHAL[ERR] SetFormat: Invaild Device status: 0 [08-14 17:10:17.999] CamHAL[ERR] set format Intel IPU6 CSI2 BE SOC 0 [25:0] [1932x1092] V4L2_MBUS_FMT_SGRBG10_1X10 failed. [08-14 17:10:18.13] CamHAL[ERR] SetControl: Device node /dev/v4l-subdev1 is not opened! No such device [08-14 17:10:18.13] CamHAL[ERR] SetControl: Device node /dev/v4l-subdev1 SetControl(int, int) error: No such device [08-14 17:10:18.13] CamHAL[ERR] set v4l2 store csi2 header failed, ret=-22 [08-14 17:10:18.13] CamHAL[ERR] Failed to create buffer pool:-22 [08-14 17:10:18.13] CamHAL[ERR] Configure device(Generic) failed:-12 [08-14 17:10:18.13] CamHAL[ERR] Create devices failed:-12 [08-14 17:10:18.13] CamHAL[ERR] @configure Device Configure failed [08-14 17:10:18.13] CamHAL[ERR] failed to config streams. ERROR: from element /GstPipeline:pipeline0/Gstcamerasrc:camerasrc0: src pad: Internal data flow error. Additional debug info: gstcambasesrc.cpp(3143): gst_cam_base_src_loop (): /GstPipeline:pipeline0/Gstcamerasrc:camerasrc0: streaming task paused, reason not-negotiated (-4) Execution ended after 0:00:00.018683543 Setting pipeline to NULL ... [08-14 17:10:18.15] CamHAL[ERR] Close: Device node /dev/v4l-subdev1 is not opened! Resource temporarily unavailable [08-14 17:10:18.15] CamHAL[ERR] Close: Device node /dev/v4l-subdev1 is not opened! Resource temporarily unavailable [08-14 17:10:18.15] CamHAL[ERR] Close: Device node /dev/v4l-subdev16 is not opened! Resource temporarily unavailable [08-14 17:10:18.15] CamHAL[ERR] Close: Device node /dev/v4l-subdev16 is not opened! Resource temporarily unavailable [08-14 17:10:18.15] CamHAL[ERR] Close: Device node /dev/v4l-subdev8 is not opened! Resource temporarily unavailable [08-14 17:10:18.15] CamHAL[ERR] Close: Device node /dev/v4l-subdev8 is not opened! Resource temporarily unavailable Freeing pipeline ... ```
$ sudo dmesg | grep -i "ipu6\|ljca\|int34" ``` [ 24.125114] intel-ipu6 0000:00:05.0: enabling device (0000 -> 0002) [ 24.125561] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 24.125585] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 24.125587] intel-ipu6 0000:00:05.0: mapped as: 0x0000000076f45617 [ 24.125664] intel-ipu6 0000:00:05.0: IPU in secure mode [ 24.125667] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 24.125668] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 24.143881] intel-ipu6 0000:00:05.0: IPC reset done [ 24.143886] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 24.145960] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 24.148698] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 24.160602] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 24.160622] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 24.160623] intel-ipu6 0000:00:05.0: mapped as: 0x0000000076f45617 [ 24.160667] intel-ipu6 0000:00:05.0: IPU in secure mode [ 24.160671] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 24.160673] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 24.163500] intel-ipu6 0000:00:05.0: IPC reset done [ 24.163502] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 24.163651] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 24.166271] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 24.183999] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 24.184020] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 24.184022] intel-ipu6 0000:00:05.0: mapped as: 0x0000000076f45617 [ 24.184108] intel-ipu6 0000:00:05.0: IPU in secure mode [ 24.184112] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 24.184114] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 24.187953] intel-ipu6 0000:00:05.0: IPC reset done [ 24.187955] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 24.188104] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 24.193660] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 24.221374] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 24.221396] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 24.221398] intel-ipu6 0000:00:05.0: mapped as: 0x0000000076f45617 [ 24.235559] intel-ipu6 0000:00:05.0: IPU in secure mode [ 24.235563] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 24.235565] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 24.241162] intel-ipu6 0000:00:05.0: IPC reset done [ 24.241167] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 24.241314] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 24.244046] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 24.275740] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 24.275760] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 24.275762] intel-ipu6 0000:00:05.0: mapped as: 0x0000000076f45617 [ 24.275807] intel-ipu6 0000:00:05.0: IPU in secure mode [ 24.275809] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 24.275810] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 24.278186] intel-ipu6 0000:00:05.0: IPC reset done [ 24.278190] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 24.278350] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 24.282116] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 24.319127] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 24.319154] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 24.319156] intel-ipu6 0000:00:05.0: mapped as: 0x0000000076f45617 [ 24.319203] intel-ipu6 0000:00:05.0: IPU in secure mode [ 24.319205] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 24.319207] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 24.321092] intel-ipu6 0000:00:05.0: IPC reset done [ 24.321096] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 24.321246] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 24.324027] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 24.379251] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 24.379284] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 24.379286] intel-ipu6 0000:00:05.0: mapped as: 0x00000000b0383eb8 [ 24.379343] intel-ipu6 0000:00:05.0: IPU in secure mode [ 24.379347] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 24.379349] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 24.381367] intel-ipu6 0000:00:05.0: IPC reset done [ 24.381369] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 24.381462] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 24.382757] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 24.405712] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 24.405740] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 24.405742] intel-ipu6 0000:00:05.0: mapped as: 0x000000003fb8eb24 [ 24.405789] intel-ipu6 0000:00:05.0: IPU in secure mode [ 24.405791] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 24.405792] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 24.407616] intel-ipu6 0000:00:05.0: IPC reset done [ 24.407617] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 24.407762] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 24.410600] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 24.487322] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 24.487339] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 24.487341] intel-ipu6 0000:00:05.0: mapped as: 0x00000000d49ff24c [ 24.487416] intel-ipu6 0000:00:05.0: IPU in secure mode [ 24.487418] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 24.487419] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 24.489206] intel-ipu6 0000:00:05.0: IPC reset done [ 24.489208] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 24.489368] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 24.492085] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 24.729256] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 24.729431] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 24.729432] intel-ipu6 0000:00:05.0: mapped as: 0x00000000dd52b8df [ 24.729469] intel-ipu6 0000:00:05.0: IPU in secure mode [ 24.729471] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 24.729473] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 24.731318] intel-ipu6 0000:00:05.0: IPC reset done [ 24.731319] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 24.731420] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 24.732760] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 24.821678] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 24.822826] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 24.822829] intel-ipu6 0000:00:05.0: mapped as: 0x00000000131f4bbb [ 24.822876] intel-ipu6 0000:00:05.0: IPU in secure mode [ 24.822879] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 24.822881] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 24.825396] intel-ipu6 0000:00:05.0: IPC reset done [ 24.825399] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 24.825964] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 24.828740] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 25.278412] ljca 1-8:1.0: LJCA USB device init success [ 25.278477] usbcore: registered new interface driver ljca [ 25.280290] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 25.280331] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 25.280334] intel-ipu6 0000:00:05.0: mapped as: 0x00000000131f4bbb [ 25.280633] intel-ipu6 0000:00:05.0: IPU in secure mode [ 25.280641] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 25.280644] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 25.300122] intel-ipu6 0000:00:05.0: IPC reset done [ 25.300140] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 25.300415] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 25.304209] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 25.323676] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 25.323702] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 25.323705] intel-ipu6 0000:00:05.0: mapped as: 0x000000003fb8eb24 [ 25.323759] intel-ipu6 0000:00:05.0: IPU in secure mode [ 25.323762] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 25.323763] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 25.326401] intel-ipu6 0000:00:05.0: IPC reset done [ 25.326404] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 25.326620] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 25.332014] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 25.363196] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 25.363228] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 25.363231] intel-ipu6 0000:00:05.0: mapped as: 0x00000000131f4bbb [ 25.363380] intel-ipu6 0000:00:05.0: IPU in secure mode [ 25.363383] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 25.363386] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 25.365239] intel-ipu6 0000:00:05.0: IPC reset done [ 25.365244] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 25.365518] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 25.369246] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 25.372799] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 25.372813] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 25.372815] intel-ipu6 0000:00:05.0: mapped as: 0x000000003fb8eb24 [ 25.372858] intel-ipu6 0000:00:05.0: IPU in secure mode [ 25.372860] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 25.372861] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 25.374647] intel-ipu6 0000:00:05.0: IPC reset done [ 25.374649] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 25.374792] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 25.379284] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 25.445671] ljca-i2c ljca-i2c.26.auto: hid INTC1097 uid 0 new uid1 [ 25.448825] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 25.448850] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 25.448853] intel-ipu6 0000:00:05.0: mapped as: 0x00000000131f4bbb [ 25.448920] intel-ipu6 0000:00:05.0: IPU in secure mode [ 25.448922] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 25.448924] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 25.468110] intel-ipu6 0000:00:05.0: IPC reset done [ 25.468113] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 25.468261] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 25.471096] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 25.515997] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 25.516015] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 25.516017] intel-ipu6 0000:00:05.0: mapped as: 0x00000000131f4bbb [ 25.516061] intel-ipu6 0000:00:05.0: IPU in secure mode [ 25.516062] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 25.516064] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 25.517877] intel-ipu6 0000:00:05.0: IPC reset done [ 25.517878] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 25.517967] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 25.520042] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 25.547932] intel-ipu6 0000:00:05.0: Device 0xa75d (rev: 0x1) [ 25.547952] intel-ipu6 0000:00:05.0: physical base address 0x603c000000 [ 25.547954] intel-ipu6 0000:00:05.0: mapped as: 0x00000000131f4bbb [ 25.548054] intel-ipu6 0000:00:05.0: IPU in secure mode [ 25.548056] intel-ipu6 0000:00:05.0: IPU secure touch = 0x0 [ 25.548057] intel-ipu6 0000:00:05.0: IPU camera mask = 0xff [ 25.550234] intel-ipu6 0000:00:05.0: IPC reset done [ 25.550239] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6ep_fw.bin [ 25.550466] intel-ipu6 0000:00:05.0: firmware: direct-loading firmware intel/ipu6ep_fw.bin [ 25.554137] intel-ipu6 0000:00:05.0: FW version: 20230102 [ 25.571127] intel-ipu6 0000:00:05.0: Found supported sensor INT3474:01 [ 25.571338] intel-ipu6 0000:00:05.0: Connected 1 cameras [ 25.572705] intel-ipu6 0000:00:05.0: Sending BOOT_LOAD to CSE [ 25.581312] intel-ipu6 0000:00:05.0: Sending AUTHENTICATE_RUN to CSE [ 25.650805] intel-ipu6 0000:00:05.0: CSE authenticate_run done [ 25.650846] intel-ipu6 0000:00:05.0: IPU6-v3 driver version 1.0 [ 25.652115] intel-ipu6-isys intel-ipu6-isys0: bind ov2740 12-0036 nlanes is 2 port is 1 [ 25.652835] intel-ipu6-isys intel-ipu6-isys0: All sensor registration completed. [ 25.678582] intel-ipu6-psys intel-ipu6-psys0: pkg_dir entry count:8 [ 25.678780] intel-ipu6-psys intel-ipu6-psys0: psys probe minor: 0 [ 114.546678] intel-ipu6-isys intel-ipu6-isys0: Format not found in mapping table. ```
$ sha256sum /lib/firmware/intel/ipu6ep_fw.bin
4603c7b261889a544c1110b8f5044a1ae39196b3f1730dd35c684530ea46cc70  /lib/firmware/intel/ipu6ep_fw.bin

ipu6-drivers is built on c3b762b275f6cbba473458859736b76548a80568 using DKMS instruction.

fhloston commented 10 months ago

Have you also enabled CONFIG_VIDEO_V4L2_SUBDEV_API=y?

The wishlist bug for including CONFIG_INTEL_SKL_INT3472=m already exists:

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1038385

yorik commented 10 months ago

@fhloston, thank you for the idea! It finally somewhat works! I can see picture via gst-launch-1.0 icamerasrc buffer-count=7 ! video/x-raw,format=NV12,width=1280,height=720 ! videoconvert ! xvimagesink

But /usr/bin/v4l2-relayd -i "icamerasrc buffer-count=7" -o "appsrc name=appsrc caps=video/x-raw,format=NV12,width=1280,height=720,framerate=30/1 ! videoconvert ! v4l2sink name=v4l2sink device=/dev/video0" crashes with segmentation fault:

Aug 15 13:05:37 kernel: appsrc:src[78466]: segfault at 6b ip 00007f6d46fc85cd sp 00007f6d45c50728 error 4 in libgstreamer-1.0.so.0.2204.0[7f6d46f74000+b7000] likely on CPU 2 (core 4, socket 0)
Aug 15 13:05:37 kernel: Code: 06 00 e8 b6 cc fa ff 31 c0 eb ae 66 90 48 85 ff 74 23 48 85 f6 74 07 48 8b 47 60 48 89 06 48 85 d2 74 07 48 8b 47 50 48 89 02 <48> 8b 47 68 c3 66 0f 1f 44 00 00 48 83 ec 08 48 8d 15 88 7a 06 00
fhloston commented 10 months ago

v4l2-relayd enchantment looks a bit different here:

/usr/bin/v4l2-relayd -i icamerasrc buffer-count=7 -o appsrc name=appsrc caps=video/x-raw,format=NV12,width=1280,height=720,framerate=30/1 ! videoconvert ! video/x-raw,format=YUY2 ! v4l2sink name=v4l2sink device=/dev/video0

yorik commented 10 months ago

Without putting args for -i and -o into quotes it starts ok, but relay no video. With the quotes it crashes. Unit file runs it with quotes.

I tried both options with ! video/x-raw,format=YUY2 part and without, it makes no difference (at least for now).

fhloston commented 10 months ago

I also used 6.4.4 for a while but have reverted back to 6.3.7...

yorik commented 10 months ago

After playing I managed to fix sigfault, but I have no idea how... My best guess is that enabling debug in module v4l2loopback fix it...

So gst-launch-1.0 -v icamerasrc ! video/x-raw,format=NV12,width=1280,height=720,framerate=30/1 ! videoconvert ! video/x-raw,format=YUY2 ! v4l2sink device=/dev/video0 works wonderfully in chrome or mpv, but the camera is always on. I guess I can use it for now, manually switch it on and off when needed...

Unfortunately v4l2-relayd -d -i icamerasrc -o "appsrc name=appsrc caps=video/x-raw,format=NV12,width=1280,height=720,framerate=30/1 ! videoconvert ! video/x-raw,format=YUY2 ! v4l2sink name=v4l2sink device=/dev/video0" never enables camera and only gives black box as result.

Debugging shows nothing useful:(

P.S. I was surprised how bad video quality of this camera, I'd expect something amazing...