Created attachment 171825 [details] inxi -Fzxx, dnf list installed \*nvidia\*, flatpak run com.valvesoftware.Steam SUMMARY When launching games via Steam/Heroic Launcher/Bottles Flatpak, they fail to start with the error 'Error: couldn’t switch to requested monitor resolution'. However, in the native clients for Steam/Heroic, everything works fine. This issue occurs only with games running on Vulkan/DXVK, while games using OpenGL run without problems in Flatpak. Interestingly, if you run 'vulkaninfo', the games will start correctly until the next reboot. STEPS TO REPRODUCE 1. Launch Steam/Heroic Flatpak 2. Launch any game using Vulkan/DXVK 3. Get an error SOFTWARE/OS VERSIONS Operating System: Fedora Linux 40 KDE Plasma Version: 6.1.2 KDE Frameworks Version: 6.3.0 Qt Version: 6.7.2 Kernel Version: 6.9.9-200.fc40.x86_64 (64-bit) Graphics Platform: Wayland Processors: 12 × 11th Gen Intel® Core™ i5-11400H @ 2.70GHz Memory: 15.3 ГиБ of RAM Graphics Processor: Mesa Intel® UHD Graphics dGPU: NVIDIA GeForce RTX 3060 Laptop GPU Driver: 555.58.02 Manufacturer: HP Product Name: Victus by HP Laptop ADDITIONAL INFORMATION This only happens with proprietary Nvidia drivers, nouveau doesn't have this problem. Other distributions (Arch/openSUSE) do not have this problem. In the X11 session, the error does not occur either. https://forums.developer.nvidia.com/t/error-couldn-t-switch-to-requested-monitor-resolution/291376
Created attachment 171826 [details] Screenshot error
May be useful: https://bugzilla.rpmfusion.org/show_bug.cgi?id=7004 https://github.com/flatpak/flatpak/issues/5802 https://github.com/NVIDIA/open-gpu-kernel-modules/issues/698
As it turned out, this issue affects not only Fedora but also Arch, specifically CachyOS
Based on my tests, this seems to be exclusively a KDE issue, as the problem does not occur in other DEs, such as GNOME. Interestingly, in GNOME, you don’t even need to enter any commands in the launch parameters for games to forcefully use Nvidia instead of Intel. Additionally, if you connect the laptop to an external monitor, this error does not occur in KDE, as Nvidia is used directly, as far as I understand.
If you enable the nvidia-persistenced daemon by running: "sudo systemctl enable nvidia-persistenced --now", it seems to resolve this issue. Additionally, you no longer need to add "__NV_PRIME_RENDER_OFFLOAD=1 __VK_LAYER_NV_optimus=NVIDIA_only __GLX_VENDOR_LIBRARY_NAME=nvidia" to the launch parameters to force games to use the Nvidia GPU instead of Intel. However, I don't fully understand the exact purpose of this daemon. Moreover, it's not required in other desktop environments, where it's disabled by default. If this isn't a KDE-specific issue, I'd like to understand where to look for answers and who I can reach out to for help. Thank you.
> However, I don't fully understand the exact purpose of this daemon. Moreover, it's not required in other desktop environments, where it's disabled by default. It is required by the NVidia driver for suspend. I'm not sure either what's going on here, but I think the best place you could get answers is https://forums.developer.nvidia.com/c/gpu-graphics/linux
(In reply to Zamundaaa from comment #6) > > However, I don't fully understand the exact purpose of this daemon. Moreover, it's not required in other desktop environments, where it's disabled by default. > It is required by the NVidia driver for suspend. > > I'm not sure either what's going on here, but I think the best place you > could get answers is https://forums.developer.nvidia.com/c/gpu-graphics/linux This issue is already being discussed here: https://github.com/NVIDIA/open-gpu-kernel-modules/issues/698 But so far, we don't have any ideas on why exactly it's happening. Are you sure the report should be closed?
Yes. KWin doesn't really have anything to do with Flatpak or what the Vulkan driver is doing under the hood.