intel-ipu7-camera: use v4l2-relayd for on-demand camera feed

Replace camera-feed-watch and camera-session with v4l2-relayd, a
single-process daemon that manages the icamerasrc -> v4l2loopback feed.
v4l2-relayd uses V4L2_EVENT_PRI_CLIENT_USAGE kernel events to detect
when an app starts/stops streaming, providing zero-polling on-demand
camera activation with LED control.

This is a generic solution that works with all PipeWire apps (Snapshot,
Chromium, Firefox, etc.) without per-app wrappers or .desktop patching.

The key advantage over the previous camera-feed-watch approach: v4l2-relayd
keeps a single persistent v4l2sink writer, switching only the data source
(splash vs icamerasrc) via appsrc. This avoids the PipeWire stale mmap
buffer issue that caused degraded framerate on subsequent camera sessions
when the writer process changed.

Changes:
- Add v4l2-relayd as package dependency
- Add /etc/v4l2-relayd.d/ipu7.conf with icamerasrc pipeline config
- Add systemd service override for GST_PLUGIN_PATH and device access
- Remove camera-feed-watch, camera-feed-watch.service, camera-session,
  camera-feed.service, and Snapshot .desktop patching
- Restore PipeWireCamera feature flag for Chromium/Brave/Chrome
- Enable v4l2-relayd@ipu7.service at install time
This commit is contained in:
Gaggery Tsai committed 2026-03-24 22:14:08 -07:00
1 parent 5024f3d41c
commit cc1508c75c
8 files changed
+58 -186

No files matched your search

@@ -1 +1,2 @@
v4l2loopback
# v4l2loopback is loaded by camera-init.service instead of here.
# Loading here causes a race with PipeWire that breaks exclusive_caps.