Ffmpeg and hardware h264 decode

Thanks @numbqq @ivan.li
I used that one Armbian 24.2.1 bookworm
I needed to add some packages by myself optee-userspace_0.5-202311_arm64.deband optee-video-firmware_0.4-202311_arm64.deb from https://dl.khadas.com/repos/vim4-5.15/pool/main/o/.
The firmware /lib/firmware/video/video_ucode.bin is provided by the armbian-firmware package.

Package: armbian-firmware
Version: 24.2.1
Priority: optional
Section: kernel
Maintainer: Armbian Linux <info@armbian.com>
Installed-Size: 235 MB
Provides: linux-firmware, firmware-brcm80211, firmware-ralink, firmware-samsung, firmware-realtek, armbian-firmware-full
Conflicts: linux-firmware, firmware-brcm80211, firmware-ralink, firmware-samsung, firmware-realtek, armbian-firmware-full
Armbian-Original-Hash: 1-SA6b6f-B90f5-R448a
Download-Size: 75,2 MB
APT-Manual-Installed: yes
APT-Sources: http://imola.armbian.com/apt bookworm/main arm64 Packages
Description: Armbian - Linux firmware
dpkg -L armbian-firmware |grep video_ucode.bin
/lib/firmware/video/video_ucode.bin
sha1sum /lib/firmware/video/video_ucode.bin
19d8bbabf3dd03170f55943c46074920504fa7c4  /lib/firmware/video/video_ucode.bin
systemctl status video-firmware-preload-khadas
× video-firmware-preload-khadas.service - Amlogic OPTEE Video Firmware Preload Service
     Loaded: loaded (/lib/systemd/system/video-firmware-preload-khadas.service; enabled; preset: enabled)
     Active: failed (Result: exit-code) since Sat 2024-05-11 12:45:15 CEST; 1s ago
   Duration: 2.022s
    Process: 130209 ExecStart=/usr/bin/tee_preload_fw /lib/firmware/video/video_ucode.bin (code=exited, status=255/EXCEPTION)
   Main PID: 130209 (code=exited, status=255/EXCEPTION)
        CPU: 2.005s

mai 11 12:45:13 khadas-vim4 systemd[1]: Started video-firmware-preload-khadas.service - Amlogic OPTEE Video Firmware Preload Service.
mai 11 12:45:15 khadas-vim4 tee_preload_fw[130209]: fw_path = /lib/firmware/video/video_ucode.bin
mai 11 12:45:15 khadas-vim4 tee_preload_fw[130209]: MM-module-name:Video firmware CA,Version:1.0.5-g3604ffd(build:958)
mai 11 12:45:15 khadas-vim4 tee_preload_fw[130209]: TEEC_InvokeCommand failed with code 0xffff000f origin 0x4
mai 11 12:45:15 khadas-vim4 tee_preload_fw[130209]: tee preload video fw fail
mai 11 12:45:15 khadas-vim4 systemd[1]: video-firmware-preload-khadas.service: Main process exited, code=exited, status=255/EXCEPTION
mai 11 12:45:15 khadas-vim4 systemd[1]: video-firmware-preload-khadas.service: Failed with result 'exit-code'.
mai 11 12:45:15 khadas-vim4 systemd[1]: video-firmware-preload-khadas.service: Consumed 2.005s CPU time.