Bottles
Bottles copied to clipboard
[BUG] "Discrete GPU" option selects the wrong GPU on a desktop with GPU passthrough
Describe the bug
I admit, the title might not be the best, but read on.
Display:
X.org: true
X.org (port): :99.0
Wayland: true
Graphics:
vendors:
nvidia: &id002
vendor: nvidia
envs:
__NV_PRIME_RENDER_OFFLOAD: '1'
__GLX_VENDOR_LIBRARY_NAME: nvidia
__VK_LAYER_NV_optimus: NVIDIA_only
icd: ''
amd: &id001
vendor: amd
envs:
DRI_PRIME: '1'
icd: /usr/lib/x86_64-linux-gnu/GL/vulkan/icd.d/radeon_icd.x86_64.json:/usr/lib/i386-linux-gnu/GL/vulkan/icd.d/radeon_icd.i686.json
prime:
integrated: *id001
discrete: *id002
Kernel:
Type: Linux
Version: 5.16.0-zen1-1-zen
Distro:
Name: GNOME
Version: '"41 (Flatpak runtime)"'
Tools:
cabextract: true
p7zip: true
patool: true
Bottles_envs: null
In the above healthcheck output, there are two GPUs detected. One Nvidia, one AMD.
The Nvidia GPU is assigned to be passed through to a VM, which means it uses the vfio-pci
driver instead of a display driver.
The "Discrete GPU" option on Bottles picks this GPU instead of the working AMD gpu, which causes DXVK to fail with Required Vulkan extension VK_KHR_surface not supported
and DxvkInstance: Failed to create instance
.
Installation
- Method: Flatpak
- Version 2022.1.14-trento-2
To Reproduce 0. Have two GPUs, make a GPU Passthrough VM
- Create a new Bottle (the default settings enable the "broken" option
- Try to run anything that uses DirectX
- Profit
Expected behavior
Bottles should be able to detect if a GPU "works" or not. A possible solution is to first test if Vulkan or OpenGL works by creating a simple test program that tried to use these APIs, and running it on each GPU, though there could be issues with that approach.
Desktop (please complete the following information):
- OS: Arch Linux
- Version: latest (with KDE, if that changes anything)
- Display server: Wayland
Additional context
01:00.0 VGA compatible controller [0300]: Advanced Micro Devices, Inc. [AMD/ATI] Ellesmere [Radeon RX 470/480/570/570X/580/580X/590] [1002:67df] (rev e7)
Subsystem: Micro-Star International Co., Ltd. [MSI] Radeon RX 580 Armor 4G OC [1462:3418]
Kernel driver in use: amdgpu
Kernel modules: amdgpu
01:00.1 Audio device [0403]: Advanced Micro Devices, Inc. [AMD/ATI] Ellesmere HDMI Audio [Radeon RX 470/480 / 570/580/590] [1002:aaf0]
Subsystem: Micro-Star International Co., Ltd. [MSI] Device [1462:aaf0]
Kernel driver in use: snd_hda_intel
Kernel modules: snd_hda_intel
02:00.0 VGA compatible controller [0300]: NVIDIA Corporation GP107 [GeForce GTX 1050 Ti] [10de:1c82] (rev a1)
Subsystem: ASUSTeK Computer Inc. Device [1043:85d3]
Kernel driver in use: vfio-pci
Kernel modules: nouveau
02:00.1 Audio device [0403]: NVIDIA Corporation GP107GL High Definition Audio Controller [10de:0fb9] (rev a1)
Subsystem: ASUSTeK Computer Inc. Device [1043:85d3]
Kernel driver in use: vfio-pci
Kernel modules: snd_hda_intel
So the problem is Bottles activating that option by default? In your case, just turn it off right?
Yes, turning the option off solves the issue.
On January 17, 2022 10:10:31 AM GMT+03:00, Mirko Brombin @.***> wrote:
So the problem is Bottles activating that option by default? In your case, just turn it off right?
-- Reply to this email directly or view it on GitHub: https://github.com/bottlesdevs/Bottles/issues/940#issuecomment-1014204967 You are receiving this because you authored the thread.
Message ID: @.***>
Yes, turning the option off solves the issue. … On January 17, 2022 10:10:31 AM GMT+03:00, Mirko Brombin @.> wrote: So the problem is Bottles activating that option by default? In your case, just turn it off right? -- Reply to this email directly or view it on GitHub: #940 (comment) You are receiving this because you authored the thread. Message ID: @.>
Ok I'll check how to automate the process, thanks for reporting