Jellyfin Forum
HW Transcoding RK3588 arch not working - Printable Version

+- Jellyfin Forum (https://forum.jellyfin.org)
+-- Forum: Support (https://forum.jellyfin.org/f-support)
+--- Forum: Troubleshooting (https://forum.jellyfin.org/f-troubleshooting)
+--- Thread: HW Transcoding RK3588 arch not working (/t-hw-transcoding-rk3588-arch-not-working)



HW Transcoding RK3588 arch not working - Crashdummy - 2025-03-08

Hi there
I am currently struggling to get hardware transcoding working on arch and I've got not idea why.
I've followed this guide ( https://jellyfin.org/docs/general/administration/hardware-acceleration/rockchip/ ) but there are a few things I dont get.
When I run the verification I get errors.

Code:
$ sudo /usr/lib/jellyfin-ffmpeg/ffmpeg -v debug -init_hw_device rkmpp=rk -init_hw_device opencl=ocl@rk
ffmpeg version 7.0.2-Jellyfin Copyright (c) 2000-2024 the FFmpeg developers
  built with gcc 14.1.1 (GCC) 20240507
  configuration: --prefix=/usr/lib/jellyfin-ffmpeg --target-os=linux --extra-version=Jellyfin --disable-doc --disable-ffplay --disable-ptx-compression --disable-shared --disable-libxcb --disable-sdl2 --disable-xlib --enable-gpl --enable-version3 --enable-static --enable-gmp --enable-gnutls --enable-chromaprint --enable-libfontconfig --enable-libass --enable-libbluray --enable-libdrm --enable-libfreetype --enable-libfribidi --enable-libmp3lame --enable-libopus --enable-libopenmpt --enable-libtheora --enable-libvorbis --enable-libdav1d --enable-libwebp --enable-libvpx --enable-libx264 --enable-libx265 --enable-libzvbi --enable-libzimg --enable-libshaderc --enable-libplacebo --enable-vulkan --enable-opencl --enable-vaapi --enable-amf --enable-libvpl --enable-ffnvcodec --enable-cuda --enable-cuda-llvm --enable-cuvid --enable-nvdec --enable-nvenc
  libavutil      59.  8.100 / 59.  8.100
  libavcodec    61.  3.100 / 61.  3.100
  libavformat    61.  1.100 / 61.  1.100
  libavdevice    61.  1.100 / 61.  1.100
  libavfilter    10.  1.100 / 10.  1.100
  libswscale      8.  1.100 /  8.  1.100
  libswresample  5.  1.100 /  5.  1.100
  libpostproc    58.  1.100 / 58.  1.100
Splitting the commandline.
Reading option '-v' ... matched as option 'v' (set logging level) with argument 'debug'.
Reading option '-init_hw_device' ... matched as option 'init_hw_device' (initialise hardware device) with argument 'rkmpp=rk'.
Reading option '-init_hw_device' ... matched as option 'init_hw_device' (initialise hardware device) with argument 'opencl=ocl@rk'.
Finished splitting the commandline.
Parsing a group of options: global .
Applying option v (set logging level) with argument debug.
Applying option init_hw_device (initialise hardware device) with argument rkmpp=rk.
Device creation failed: -12.
Failed to set value 'rkmpp=rk' for option 'init_hw_device': Cannot allocate memory
Error parsing global options: Cannot allocate memory

It looks like the the jellyfin-ffmpeg is missing
Code:
--enable-rkmpp
.
The
Code:
ffmpeg-mpp-git
has this enabled but it still throws errors.

Code:
$ sudo ffmpeg -v debug -init_hw_device rkmpp=rk -init_hw_device opencl=ocl@rk
[sudo] password for crashdummy:
ffmpeg version f5c7e0d63b Copyright (c) 2000-2024 the FFmpeg developers
  built with gcc 14.1.1 (GCC) 20240507
  configuration: --prefix=/usr --disable-debug --disable-static --disable-stripping --enable-amf --enable-avisynth --enable-cuda-llvm --enable-fontconfig --enable-frei0r --enable-gmp --enable-gpl --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libdav1d --enable-libdrm --enable-libdvdnav --enable-libdvdread --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libharfbuzz --enable-libiec61883 --enable-libjack --enable-libjxl --enable-libmodplug --enable-libmp3lame --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libplacebo --enable-libpulse --enable-librsvg --enable-librubberband --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libsrt --enable-libssh --enable-libtheora --enable-libv4l2 --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxcb --enable-libxml2 --enable-libxvid --enable-libzimg --enable-mbedtls --enable-opencl --enable-opengl --enable-shared --enable-vapoursynth --enable-version3 --enable-librist --disable-vulkan --disable-doc --enable-rkmpp --enable-rkrga
  libavutil      59. 39.100 / 59. 39.100
  libavcodec    61. 19.101 / 61. 19.101
  libavformat    61.  7.100 / 61.  7.100
  libavdevice    61.  3.100 / 61.  3.100
  libavfilter    10.  4.100 / 10.  4.100
  libswscale      8.  3.100 /  8.  3.100
  libswresample  5.  3.100 /  5.  3.100
  libpostproc    58.  3.100 / 58.  3.100
Splitting the commandline.
Reading option '-v' ... matched as option 'v' (set logging level) with argument 'debug'.
Reading option '-init_hw_device' ... matched as option 'init_hw_device' (initialise hardware device) with argument 'rkmpp=rk'.
Reading option '-init_hw_device' ... matched as option 'init_hw_device' (initialise hardware device) with argument 'opencl=ocl@rk'.
Finished splitting the commandline.
Parsing a group of options: global .
Applying option v (set logging level) with argument debug.
Applying option init_hw_device (initialise hardware device) with argument rkmpp=rk.
Applying option init_hw_device (initialise hardware device) with argument opencl=ocl@rk.
Device creation failed: -38.
Failed to set value 'opencl=ocl@rk' for option 'init_hw_device': Function not implemented
Error parsing global options: Function not implemented

Regarding the libmali opencl The note mentions
> Only needed before using HDR tone-mapping on RK3588/3588S. This is done to ensure that the user space firmware and kernel driver versions match, otherwise OpenCL will not work properly.

Wouldnt that mean I can ignore this ?
It doesnt look like its actually working because when I monitor the load using
Code:
$ sudo watch -n 1 cat /sys/kernel/debug/rkrga/load

It always remains at 0 load

Code:
num of scheduler = 3
================= load ==================
scheduler[0]: rga3
load = 0%
-----------------------------------
scheduler[1]: rga3
load = 0%
-----------------------------------
scheduler[2]: rga2
load = 0%
-----------------------------------

Am I forgetting anything ?
My System is a Radxa Rocks 5b+ and i used the community arch installer.
https://github.com/kwankiu/archlinux-installer

Code:
OS: Arch Linux ARM aarch64
Host: Radxa ROCK 5B Plus
Kernel: Linux 6.1.75-rockchip-g7725578fd0ae-dirty
CPU: rk3588 (8) @ 2.30 GHz
GPU: Rockchip rk3588-mali [Integrated]
Memory: 2.10 GiB / 31.04 GiB (7%)



RE: HW Transcoding RK3588 arch not working - TheDreadPirate - 2025-03-09

@nyanmisaka - Can you help with this?