eGPU issues with external monitor

about two weeks ago I asked for some help with getting my Egpu setup working with my Thinkpad T480 internal screen and it worked as expected. since then I bought myself an external monitor since I’ve been told that how you get the best performance with it. doing that though has brought in some unique issues starting with the bizarre slowdown on the external monitor when I set it as a single display in gnome settings or close my laptop screen. If I try to play games on Steam, I actually get worse performance on the external monitor than I did on the internal monitor! Both Fallout New Vegas and Team Fortress 2 went from 60 fps to 40 fps on the exact same setting’s (i.e the one I used when playing the games using only the laptop screen) and also seem to be hard wired to whatever resolution my internal laptop screen is (trying to change it in team fortress 2 seems to cause it to lock up). I’m really confused what’s going here cause when I run the command DRI_PRIME=1 glxinfo | grep “OpenGL renderer” it does show my rx 580 being used which should means it’s working. So what should be my next step to trouble shoot this?

Please post the output of inxi -Fazy and xrandr --listproviders.

hmmmm all I get is Error 22: Unsupported option: and
Check -h for correct parameters.

okay I switched and to && and this is what outputted

System:
Kernel: 5.10.2-2-MANJARO x86_64 bits: 64 compiler: gcc v: 10.2.0
parameters: BOOT_IMAGE=/boot/vmlinuz-5.10-x86_64
root=UUID=4033143d-94ab-4548-8bc2-e9217e6e1a98 rw quiet apparmor=1
security=apparmor udev.log_priority=3
Desktop: GNOME 3.38.2 tk: GTK 3.24.24 wm: gnome-shell dm: GDM 3.38.2.1
Distro: Manjaro Linux
Machine:
Type: Laptop System: LENOVO product: 20L5S36000 v: ThinkPad T480
serial: Chassis: type: 10 serial:
Mobo: LENOVO model: 20L5S36000 v: SDK0J40697 WIN serial:
UEFI: LENOVO v: N24ET56W (1.31 ) date: 02/19/2020
Battery:
ID-1: BAT1 charge: 37.1 Wh condition: 46.4/47.5 Wh (98%) volts: 12.1/10.8
model: LGC 01AV491 type: Li-ion serial: status: Charging cycles: 31
CPU:
Info: Quad Core model: Intel Core i7-8650U bits: 64 type: MT MCP
arch: Kaby Lake note: check family: 6 model-id: 8E (142) stepping: A (10)
microcode: E0 L2 cache: 8 MiB
flags: avx avx2 lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
bogomips: 33615
Speed: 799 MHz min/max: 400/4200 MHz Core speeds (MHz): 1: 799 2: 800 3: 800
4: 800 5: 798 6: 800 7: 800 8: 800
Vulnerabilities: Type: itlb_multihit status: KVM: VMX disabled
Type: l1tf
mitigation: PTE Inversion; VMX: conditional cache flushes, SMT vulnerable
Type: mds mitigation: Clear CPU buffers; SMT vulnerable
Type: meltdown mitigation: PTI
Type: spec_store_bypass
mitigation: Speculative Store Bypass disabled via prctl and seccomp
Type: spectre_v1
mitigation: usercopy/swapgs barriers and __user pointer sanitization
Type: spectre_v2 mitigation: Full generic retpoline, IBPB: conditional,
IBRS_FW, STIBP: conditional, RSB filling
Type: srbds mitigation: Microcode
Type: tsx_async_abort mitigation: Clear CPU buffers; SMT vulnerable
Graphics:
Device-1: Intel UHD Graphics 620 vendor: Lenovo driver: i915 v: kernel
bus ID: 00:02.0 chip ID: 8086:5917
Device-2: AMD Ellesmere [Radeon RX 470/480/570/570X/580/580X/590]
vendor: Sapphire Limited Nitro+ driver: amdgpu v: kernel bus ID: 09:00.0
chip ID: 1002:67df
Device-3: IMC Networks Integrated Camera type: USB driver: uvcvideo
bus ID: 1-8:5 chip ID: 13d3:56a6 serial:
Display: x11 server: X.org 1.20.10 compositor: gnome-shell
driver: amdgpu,ati,intel unloaded: modesetting alternate: fbdev,vesa
resolution: <missing: xdpyinfo>
OpenGL: renderer: Mesa Intel UHD Graphics 620 (KBL GT2) v: 4.6 Mesa 20.3.1
direct render: Yes
Audio:
Device-1: Intel Sunrise Point-LP HD Audio vendor: Lenovo ThinkPad T480
driver: snd_hda_intel v: kernel alternate: snd_soc_skl bus ID: 00:1f.3
chip ID: 8086:9d71
Device-2: AMD Ellesmere HDMI Audio [Radeon RX 470/480 / 570/580/590]
vendor: Sapphire Limited driver: snd_hda_intel v: kernel bus ID: 09:00.1
chip ID: 1002:aaf0
Sound Server: ALSA v: k5.10.2-2-MANJARO
Network:
Device-1: Intel Ethernet I219-LM vendor: Lenovo driver: e1000e v: kernel
port: efa0 bus ID: 00:1f.6 chip ID: 8086:15d7
IF: enp0s31f6 state: down mac:
Device-2: Intel Wireless 8265 / 8275 driver: iwlwifi v: kernel port: efa0
bus ID: 03:00.0 chip ID: 8086:24fd
IF: wlp3s0 state: up mac:
Drives:
Local Storage: total: 476.94 GiB used: 72.5 GiB (15.2%)
SMART Message: Required tool smartctl not installed. Check --recommends
ID-1: /dev/nvme0n1 maj-min: 259:0 vendor: Samsung model: MZVLB512HAJQ-000L7
size: 476.94 GiB block size: physical: 512 B logical: 512 B speed: 31.6 Gb/s
lanes: 4 serial: rev: 5L2QEXA7 temp: 25.9 C
Partition:
ID-1: / raw size: 476.64 GiB size: 468.16 GiB (98.22%)
used: 72.5 GiB (15.5%) fs: ext4 dev: /dev/nvme0n1p2 maj-min: 259:2
ID-2: /boot/efi raw size: 300 MiB size: 299.4 MiB (99.80%)
used: 280 KiB (0.1%) fs: vfat dev: /dev/nvme0n1p1 maj-min: 259:1
Swap:
Alert: No Swap data was found.
Sensors:
System Temperatures: cpu: 38.0 C mobo: N/A gpu: amdgpu temp: 35.0 C
Fan Speeds (RPM): cpu: 2859 gpu: amdgpu fan: 846
Info:
Processes: 259 Uptime: 6m wakeups: 4 Memory: 7.65 GiB used: 2.09 GiB (27.4%)
Init: systemd v: 247 Compilers: gcc: 10.2.0 Packages: 1051 pacman: 1043
lib: 300 flatpak: 8 Shell: Zsh v: 5.8 running in: gnome-terminal
inxi: 3.2.01
Providers: number : 2
Provider 0: id: 0x49 cap: 0xb, Source Output, Sink Output, Sink Offload crtcs: 4 outputs: 6 associated providers: 1 name:Intel
Provider 1: id: 0xb6 cap: 0xf, Source Output, Sink Output, Source Offload, Sink Offload crtcs: 6 outputs: 5 associated providers: 1 name:Radeon RX 580 Series @ pci:0000:09:00.0

I believe this is caused by limitations in the Xorg server, the issue is the same as described here.


Have you tried using Wayland? And what’s the output of sudo cat /sys/kernel/debug/vgaswitcheroo/switch?

switch to wayland then run that command?

Run that command in the X session, so no need to switch to anything.

if I run the command I get the error zsh: no matches found: ? and if I remove the ? it just tells me that cat: /sys/kernel/debug/vgaswitcheroo/switch: No such file or directory

I see. I’m not quite sure if this will achieve anything meaningful, but what happens if you run

xrandr --setprovideroutputsource "Radeon RX 580 Series @ pci:0000:09:00.0" 0x0
xrandr --setprovideroutputsource Intel "Radeon RX 580 Series @ pci:0000:09:00.0"

?

If you get a black screen on both displays, just press Ctrl+Alt+F3, and log in, then reboot.

well running the first one froze my external monitor but it showed xrandr --setprovideroutputsource “Radeon RX 580 Series @ pci:0000:09:00.0” 0x0 let’s see what happens when I run the second one

That was expected.

X Error of failed request: BadValue (integer parameter out of range for operation)
Major opcode of failed request: 140 (RANDR)
Minor opcode of failed request: 35 (RRSetProviderOutputSource)
Value in failed request: 0xb6
Serial number of failed request: 16
Current serial number in output stream: 17

I see. Running xrandr --setprovideroutputsource "Radeon RX 580 Series @ pci:0000:09:00.0" Intel should restore the external monitor. In any case, I suggest you try Wayland.

Interesting. Most of my research made it seem like epgu wouldnt work with wayland

I guess it’s worth a try.

wayland definetly fixed my monitor issue I’ll see what happens now when I run a few games

sorry this took forever but after trying a few games which were still playing very choppily I decided to try shadow of the tomb raider which interestingly enough recognized the amd card but still played super choppy at 30 fps on low and high settings. so now I’m really confused what could be causing this

What’s the output of

glxinfo -B | grep renderer
DRI_PRIME=1 glxinfo -B | grep renderer

?

Extended renderer info (GLX_MESA_query_renderer):
OpenGL renderer string: Mesa Intel® UHD Graphics 620 (KBL GT2)
Extended renderer info (GLX_MESA_query_renderer):
OpenGL renderer string: Radeon RX 580 Series (POLARIS10, DRM 3.40.0, 5.10.2-2-MANJARO, LLVM 11.0.0)

Are you back on X11? You ran the games with DRI_PRIME=1 right?