You need to enable JavaScript to run this app.
最新活动
大模型
产品
解决方案
定价
生态与合作
支持与服务
开发者
了解我们

在Meteor Lake平台的XPS 14 9440(Ubuntu 23.10 + 6.8主线内核)上配置IPU6摄像头的问题求助

在Meteor Lake平台的XPS 14 9440(Ubuntu 23.10 + 6.8主线内核)上配置IPU6摄像头的问题求助

我尝试让Meteor Lake平台的XPS 14 9440在Ubuntu 23.10上的摄像头正常工作。因为这款笔记本基于Meteor Lake,必须使用版本≥6.7的内核才能获得完整的平台支持,目前我用的是6.8主线内核:

$ uname -a
Linux christoph-XPS-14-9440 6.8.1-060801-generic #202403151937 SMP PREEMPT_DYNAMIC Fri Mar 15 19:52:22 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux

遗憾的是,截至2024年3月29日,还没有针对≥6.7内核的预编译IPU6驱动——因为需要等待两个正在合并的PR完成,驱动才能在新内核上正常运行。

我现在有几个困惑点,同时也遇到了编译问题,希望能得到帮助:

  • 我该如何让IPU6驱动正常工作?
  • 我完全搞不懂各个组件的作用和协作逻辑:ipu6是核心驱动,那icameraIPU6 HAL是什么?它们又怎么和Gstreamer配合,让摄像头能在Google Chrome这类应用里使用?

我已经尝试的操作

我自行编译了ipu6-drivers(包含ivsc-driver),看起来已经成功编译并加载:

dmesg日志验证

$ sudo dmesg | grep ipu6
[    2.930531] intel_ipu6: loading out-of-tree module taints kernel.
[    2.930538] intel_ipu6: module verification failed: signature and/or required key missing - tainting kernel
[    2.952118] intel-ipu6 0000:00:05.0: enabling device (0000 -> 0002)
[    2.953006] intel-ipu6 0000:00:05.0: Device 0x7d19 (rev: 0x4)
[    2.953039] intel-ipu6 0000:00:05.0: physical base address 0x5a2c000000
[    2.953043] intel-ipu6 0000:00:05.0: mapped as: 0x00000000dd7e4357
[    2.953110] intel-ipu6 0000:00:05.0: IPU in secure mode
[    2.953114] intel-ipu6 0000:00:05.0: IPU secure touch = 0x80000000
[    2.953115] intel-ipu6 0000:00:05.0: IPU camera mask = 0x0
[    2.964890] intel-ipu6 0000:00:05.0: IPC reset done
[    2.964895] intel-ipu6 0000:00:05.0: cpd file name: intel/ipu6epmtl_fw.bin
[    3.029032] intel-ipu6 0000:00:05.0: FW version: 20230925
[    3.053964] intel-ipu6 0000:00:05.0: Found supported sensor OVTI02C1:00
[    3.054199] intel-ipu6 0000:00:05.0: Connected 1 cameras
[    3.055424] intel-ipu6 0000:00:05.0: Sending BOOT_LOAD to CSE
[    3.090594] intel-ipu6 0000:00:05.0: Sending AUTHENTICATE_RUN to CSE
[    3.137096] intel-ipu6 0000:00:05.0: CSE authenticate_run done
[    3.137135] intel-ipu6 0000:00:05.0: IPU6-v4 driver version 1.0
[    4.221346] intel-ipu6-psys intel-ipu6-psys0: pkg_dir entry count:8
[    4.223677] intel-ipu6-psys intel-ipu6-psys0: psys probe minor: 0

lsmod验证

$ lsmod | grep ipu6
intel_ipu6_isys       159744  0
videobuf2_dma_contig    24576  1 intel_ipu6_isys
videobuf2_v4l2         40960  1 intel_ipu6_isys
videobuf2_common       86016  4 videobuf2_dma_contig,videobuf2_v4l2,intel_ipu6_isys,videobuf2_memops
intel_ipu6_psys       110592  0
v4l2_fwnode            40960  2 ov02c10,intel_ipu6_isys
v4l2_async             28672  3 v4l2_fwnode,ov02c10,intel_ipu6_isys
videodev              364544  5 v4l2_async,v4l2_fwnode,videobuf2_v4l2,ov02c10,intel_ipu6_isys
intel_ipu6            122880  2 intel_ipu6_isys,intel_ipu6_psys
mc                     86016  7 v4l2_async,videodev,snd_usb_audio,videobuf2_v4l2,ov02c10,intel_ipu6_isys,videobuf2_common

遇到的编译问题

按照理解,我还需要编译ipu6-camera-halicamerasrc才能让摄像头在应用中工作。我按照README的要求,克隆了ipu6-camera-hal仓库,并将其放在icamerasrc仓库的icamerasrc_slim_api分支旁边,目录结构如下:

# 参考README的构建说明整理的目录结构
cp build.sh .. && cd ..
# 工作目录:
# ├── build.sh
# ├── icamerasrc
# ├── ipu6-camera-hal
# └── out

实际目录验证:

$ ls
build.sh  icamerasrc  ipu6-camera-hal  out

但运行build.sh时,ipu6-camera-hal编译成功,icamerasrc却编译失败,错误信息如下:

mv -f .deps/libgsticamerasrc_la-gstcampushsrc.Tpo .deps/libgsticamerasrc_la-gstcampushsrc.Plo
utils.cpp: In function 'gboolean CameraSrcUtils::gst_video_info_from_dma_drm_caps(GstVideoInfo*, const GstCaps*)':
utils.cpp:361:8: error: 'gst_video_is_dma_drm_caps' was not declared in this scope; did you mean 'gst_video_info_from_caps'?
  361 |   if (!gst_video_is_dma_drm_caps(caps)) {
      |        ^~~~~~~~~~~~~~~~~~~~~~~~~
      |        gst_video_info_from_caps
utils.cpp:366:5: error: 'GstVideoInfoDmaDrm' was not declared in this scope; did you mean 'GstVideoInfo'?
  366 |     GstVideoInfoDmaDrm drm_info;
      |     ^~~~~~~~~~~~~~~~~~
      |     GstVideoInfo
utils.cpp:367:44: error: 'drm_info' was not declared in this scope; did you mean 'g_info'?
  367 |     if (!gst_video_info_dma_drm_from_caps(&drm_info, caps)) {
      |                                            ^~~~~~~~
      |                                            g_info

之前遇到类似问题时,安装缺失的依赖包就能解决,但这次我找不到对应的解决方案,希望能得到大家的帮助。

备注:内容来源于stack exchange,提问作者Christoph Stickel

火山引擎 最新活动