You are not logged in.

#1 2020-06-29 01:15:12

ignormies
Member
Registered: 2016-08-15
Posts: 20

Mesa drivers being used, despite having AMD drivers loaded

My (eGPU) AMD RX 5700 XT card is not being used for hardware acceleration despite the drivers being loaded:

┌─[ignormies][~]
└──▪ glxinfo | grep -i opengl
OpenGL vendor string: Intel
OpenGL renderer string: Mesa Intel(R) UHD Graphics 620 (WHL GT2)
┌─[ignormies][~]
└──▪ lsmod | grep amdgpu     
amdgpu               5738496  2
gpu_sched              40960  1 amdgpu
i2c_algo_bit           16384  2 amdgpu,i915
ttm                   118784  1 amdgpu
drm_kms_helper        258048  2 amdgpu,i915
drm                   581632  15 gpu_sched,drm_kms_helper,amdgpu,i915,ttm
┌─[ignormies][~]
└──▪ lspci
08:00.0 PCI bridge: Advanced Micro Devices, Inc. [AMD/ATI] Navi 10 XL Upstream Port of PCI Express Switch (rev c1)
09:00.0 PCI bridge: Advanced Micro Devices, Inc. [AMD/ATI] Navi 10 XL Downstream Port of PCI Express Switch
0a:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Navi 10 [Radeon RX 5600 OEM/5600 XT / 5700/5700 XT] (rev c1)
0a:00.1 Audio device: Advanced Micro Devices, Inc. [AMD/ATI] Navi 10 HDMI Audio

In Gnome+Wayland, the displays are also driven, but I'm (fairly) confident that they are being drawn using the integrated graphics in my CPU and passed through the GPU.
(https://i.imgur.com/NjrSsHy.jpg)
My ultrawide is having some major issues where everything is drawn sheared (except the cursor, oddly), almost like a frequency problem. If I disable the internal display, windows/GUI elements/extra cursors start getting drawn in the wrong places and flickering and it gets fairly laggy.


I have been able to use Nvidia eGPUs just fine and switching to another enclosure with a 1070 in it works fine after adding an xorg.conf configuration and telling Gnome to use X.

Section "Device"
    Identifier     "eGPU"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BusID          "PCI:08:0:0"
    Option         "AllowExternalGpus" "true"
EndSection

I have been unable to get a modified, similar configuration to work with my AMD card on X. Using this configuration, I get a blank or pure green (probably #00ff00) screens with no ability to interact.

Section "Device"
    Identifier     "AMD eGPU"
    Driver         "amdgpu"
    BusID          "PCI:10:0:0"
    Option         "AllowExternalGpus" "true"
EndSection

Lastly, the enclosure+card works perfectly fine on Windows, so it's not the card's fault.

Offline

#2 2020-06-29 01:26:46

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 10,719

Re: Mesa drivers being used, despite having AMD drivers loaded

AllowExternalGpus is a nvidia driver option so it's not entirely surprising it doesn't work. You probably want to look at https://wiki.archlinux.org/index.php/PR … offloading

Offline

#3 2020-06-29 11:24:03

Lone_Wolf
Member
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 8,469

Re: Mesa drivers being used, despite having AMD drivers loaded

BusID          "PCI:10:0:0"

That BusID doesn't match the lspci output.
Edit: lspci uses hex, xorg uses decimal notation , busid does match lspci output.

Your system does appear to use hybrid graphics, thoroughly check the page V1del linked to to understand the possiblities and how to use them.

Last edited by Lone_Wolf (2020-06-30 10:38:51)


Multi-init booting with apg Openrc and systemd coexisting
Automounting : not needed, i prefer pmount
Aur helpers : makepkg + my own local repo === rarely need them

Offline

#4 2020-06-29 12:42:39

seth
Member
Registered: 2012-09-03
Posts: 16,509

Re: Mesa drivers being used, despite having AMD drivers loaded

That BusID doesn't match the lspci output.

It should not - lspci is hexadecimal, xorg.conf useses decimal.
https://wiki.archlinux.org/index.php/Bu … hics_Cards

Offline

#5 2020-06-30 17:53:55

ignormies
Member
Registered: 2016-08-15
Posts: 20

Re: Mesa drivers being used, despite having AMD drivers loaded

Thanks for the responses. I should have made it clear in my original post that

  • I want to use the dedicated eGPU for as much hardware acceleration as possible. My laptop does not have an internal, dedicated GPU (only Intel integrated).

  • I want to be able to use this card with Wayland, not just X. I used the xorg config just to demonstrate that the problem wasn't specific to using Wayland

  • All my displays are connected to the eGPU and I'm not interested in driving the internal screen while using it.

With that being said, is PRIME what I even need to be looking at? I don't think I'm interested in hybrid graphics/dynamic offloading. Plus the instructions for this rely on xrandr which, to my understanding, doesn't work with Wayland?

Offline

#6 2020-06-30 22:14:39

seth
Member
Registered: 2012-09-03
Posts: 16,509

Re: Mesa drivers being used, despite having AMD drivers loaded

"i915.modeset=0" should effectively block the intel chip from being used for display servers - remove all funky xorg configs, do NOT have xf86-video-vesa installed and see what happens.

Offline

#7 2020-07-01 00:11:58

ignormies
Member
Registered: 2016-08-15
Posts: 20

Re: Mesa drivers being used, despite having AMD drivers loaded

Ok I did each of those things and the card was used for hardware acceleration/displays. I did have to manually launch my gnome session, however (gdm hangs on startup).

Attempting to diagnose the issue further, I determined that I can even leave xf86-video-vesa installed, only setting the i915.modeset=0 kernel parameter, and the card is still used.

Last edited by ignormies (2020-07-01 00:17:46)

Offline

#8 2020-07-01 06:22:31

seth
Member
Registered: 2012-09-03
Posts: 16,509

Re: Mesa drivers being used, despite having AMD drivers loaded

How is GDM configured? Wayland or Xorg backend?

and the card is still used

Until it isn't (X11 only)
The VESA driver is capable to run X11 on the modeset disabled i915 chip - and I can't think of a good reason to have it installed on this system.

Offline

#9 2020-07-01 07:41:16

ignormies
Member
Registered: 2016-08-15
Posts: 20

Re: Mesa drivers being used, despite having AMD drivers loaded

How is GDM configured? Wayland or Xorg backend?

I currently have it configured to use the Wayland backend.

I can't think of a good reason to have it installed on this system.

I use this laptop detached from the eGPU on the go, and also occasionally plug in an Nvidia eGPU (I use X11 when I do this). I can't remember why I originally installed xf86-video-vesa, however. It may have just been me trying to resolve this or another issue weeks or months ago. Is it important when running without the eGPU and only with the iGPU?

Offline

#10 2020-07-01 12:30:56

seth
Member
Registered: 2012-09-03
Posts: 16,509

Re: Mesa drivers being used, despite having AMD drivers loaded

I guess GDM/wayland will try to use the intel chip and fail on that - check the journal.
Possibly changing the framebuffer device for the console can help you out here, https://unix.stackexchange.com/question … ole-output

Is it important when running without the eGPU and only with the iGPU?

No.
Respectively: yes.
But no.

The VESA driver will allow you to run on the intel chip w/o KMS enabled, but that's not what you want.
If you want to use both setups, you could start the server w/ different configs where "PrimaryGPU" Option in either device is reversed. Potentially only having the entry "True" for your amdgpu is going to cut it, but this will not impact wayland sessions and idk whether gnome allows you to select the GPU (last I know is that wayland/gnome has no hybrid graphics support, but that could have changed)

So for wayland the only way I know is to control the GPU during the boot phase.

Offline

Board footer

Powered by FluxBB