1 Commits

Author SHA1 Message Date
marfrit ba4b6fd240 iter38 close: multi-device probe — 5/5 codecs in one libva session
Closes the last architectural open item from iter37 campaign-close.

VA_DRIVER_INIT now opens BOTH rkvdec and hantro fds when no env
override is set. RequestQueryConfigProfiles enumerates the union
(via any_fd_supports_output_format helper). RequestCreateConfig
calls request_switch_device_for_profile to retarget the active fd
to the device that serves the profile; tears down output_pool +
capture_pool + video_format cache on switch so the next
RequestCreateContext rebuilds them on the new device.

Bonus iter38b: fixed latent bounds-check bug in
RequestQueryConfigProfiles — profile array bounds checks should use
MAX_PROFILES (11), not MAX_CONFIG_ATTRIBUTES (10). Pre-iter38 single-
device probes never returned more than 9 profiles so the off-by-one
never bit. iter38's 10-profile union surfaced it.

Result: 5/5 codecs PASS bit-exact vs kdirect with NO env override.

  $ vainfo (no env)
  v4l2-request: auto-selected: /dev/video3 + /dev/media1
  v4l2-request: iter38: also opened hantro at /dev/video2 + /dev/media0
  → all 10 profiles enumerated (MPEG2+H264+HEVC+VP8+VP9)

Backend tip 7ac934e.
2026-05-14 18:58:17 +00:00