Using amdgpu instead of radeon kernel driver

I have a laptop with a discrete AMD GPU (specifically Radeon 520). Recently, I am having problems with stuttering videos with Firefox. Further details about my issue be read on my reddit post,

When I execute lspci -v, the following information are shown about the display controller.

Display controller: Advanced Micro Devices, Inc. [AMD/ATI] Jet PRO [Radeon R5 M230 / R7 M260DX / Radeon 520 Mobile] (rev c3)
...
Kernel driver in use: radeon
Kernel modules: radeon, amdgpu

One suggestion I received is to change the kernel driver I use for the display controller. However, I am not sure how to do this as it is not detailed in the Fedora documentation. ArchWiki’s documentation about changing the kernel driver is so confusing; I am not even sure where to start.

Another question I would like to ask is why radeon is the default kernel driver I have. I have looked into the specifications of my GPU and it looks like it supports the GCN architecture.

1 Like

Welcome to Ask Fedora, @lewisdb

I am having trouble deciding which family your graphics chipset is in Here is the full information reference that should show the answer, but I don’t see anything specifically labeled R5 or Radeon 520. If my guess that it is an R500 chipset is correct, then yes, the radeon driver is the right one. But I’m not positive about my guess.

https://wiki.freedesktop.org/xorg/RadeonFeature/

PS - I looked up your specific card on the AMD site. All of the driver info has to do with Windows. But your card appears to be much newer than the R500 family of chipsets. I do not understand why they have to make all the naming so confusing.

1 Like

So I’ve tried using the other kernel driver, amdgpu, but Fedora’s performance became so slow. It was worse when playing videos in Firefox or any other browser. I guess that driver isn’t really compatible with my GPU.

Upon further investigation, I think the graphics driver wasn’t the culprit here but the audio driver. I only hear the audio stutter and audio dropouts when the tabs are inactive so it’s probably an audio buffer issue (although I’m not sure about this).

I tried playing with PulseAudio’s configuration file but it didn’t help at all. I am not sure if this is an issue on how Firefox manages separate tabs as separate processes compared to how Chromium-based browsers do it. I also tried using the pipewire-pulseaudio package but I’m still experiencing the same problem.

Do you have xorg-x11-drv-amdgpu installed?
Did you boot with those kernel parameters radeon.si_support=0 amdgpu.si_support=1?

amdgpu is still considered experimental for Southern Islands (SI - your GPU) and Sea Islands (CIK) (that’s first and second wave of GCN GPUs, respectively), but it’s the easiest way to run Vulkan applications. Besides, most issues are already ironed out.

1 Like

Do you have xorg-x11-drv-amdgpu installed?

Yes

Did you boot with those kernel parameters radeon.si_support=0 amdgpu.si_support=1 ?

Yes

Although my Chromium-based browser (Vivaldi), runs fine with Vulkan enabled using the radeon kernel driver.

That’s the minimum that should suffice in most cases to switch to amdgpu. Did you add any other changes?

It’s probably rendered on cpu or not actually using vulkan. Run vulkaninfo and you’ll probably only have one GPU - LLVM - until enabling amdgpu:

Device Properties and Extensions:
=================================
GPU0:
VkPhysicalDeviceProperties:
---------------------------
        apiVersion     = 4194306 (1.0.2)
        driverVersion  = 1 (0x0001)
        vendorID       = 0x10005
        deviceID       = 0x0000
        deviceType     = PHYSICAL_DEVICE_TYPE_CPU
        deviceName     = llvmpipe (LLVM 11.0.0, 256 bits)

Compare apiVersion in vulkaninfo with usedApiVersion in chrome://gpu/ in Vivaldi. On my computer usedApiVersion is between GPU0 (llvmpipe - software renderer, working on CPU) and my GPU1, so it has to be working on GPU.

Sorry to resurrect this topic quite a long time after the last reply, but I stumbled upon this thread looking for something else, and it’s an issue I have struggled with in the past and wanted to add the following information for people who may stumble on this later:

The issue that causes this same symptom for me (video playback is choppy, other browsers work fine) is the openh264 decoder used by Firefox. The solution that has always worked for me is to install ffmpeg from RPMFusion. After that, firefox should be have similar performance to chromium and others.