kodi hardware decoder on bullseye

Good day,

currently I am struggling to get the hardware decoder working for h264 in kodi 19 on my RPi 3B.

  • dietpi 7.8.2 (armv7l)
  • kodi 19.3 (from untested repo)
  • ffmpeg 4.3.3 (from main repo)

I added following to config.txt:

I enabled Prime DRM decoding and hardware acceleration in kodi, but it shows still ‘SW’ instead of ‘HW’ while playing video files.

Did I miss something? Any suggestions?

Just spotted your post, and am now wondering if this is the same problem that I am having on my Pi 3B. As Kodi playback of video files is now choppy and it worked fine previously on Buster.

There is a topic here about Kodi I am not sure if you have seen it so thought I would link it in case it is of some help.

dtoverlay=rpivid-v4l2 is only relevant on RPi 4 for HEVC decoding.

gpu_mem should not be increased anymore, leave it untouched.

As long as you do not watch 4k videos on RPi 4, leave CMA size untouched as well, and use the full KMS driver instead of the fake KMS driver. So the only change on RPi 3 should be:


and hardware acceleration with Prime DRM decoding in Kodi.

Thank you for that hint!
The solution for me was:

rm /etc/modprobe.d/dietpi-disable_rpi_camera.conf
modprobe bcm2835_codec bcm2835_v4l2 bcm2835_isp

Finally kodi uses the hardware decoder :smiley:

Thank you too.
I removed the gpu_mem, cms and rpivid-v4l2 parameters.
But I prefere to use the fake KMS as it’s possible to switch the hdmi port on & off by the tvservice command.
Or is there a similar command for the KMS driver?

It should be possible to keep bcm2835_isp blacklisted, probably bcm2835_v4l2 as well. Probably bcm2835_codec is the only driver required for video decoding. But good that we found the culprit in general.

Yeap, I can confirm that only bcm2835_codec is needed :sunglasses:

Many thanks for testing and verifying this :slight_smile:. I wanted to ask the RPi firmware engineers about this, to be sure the other two are not used for anything else than the RPi camera module.