Bug 106713 - Freezing on fullscreen when using Wayland and/or amdgpu module
Summary: Freezing on fullscreen when using Wayland and/or amdgpu module
Alias: None
Product: Wayland
Classification: Unclassified
Component: XWayland (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Wayland bug list
QA Contact: Xorg Project Team
: 107230 109711 (view as bug list)
Depends on:
Reported: 2018-05-29 15:34 UTC by epigramx
Modified: 2019-02-22 09:51 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Description epigramx 2018-05-29 15:34:13 UTC
This is a relatively complex issue but I have pin-pointed it to a combination of Wayland (not Xorg) and amdgpu module (not radeon) on R9 290 hardware.

I realize this could be related to the upstream of amdgpu too but it's most likely a higher level issue than that.

The distro is current debian sid for months.

The issue was reliably reproducible when using Dolphin emulator on XWayland. At fullscreen it would freeze the rendering; it would either stay frozen indefinitely, or, even if it would unfreeze, it would only happen after exiting fullscreen. The issue goes away with a) Xorg b) rarely with specific backends only (e.g. Vulkan and not OpenGL).

The issue also goes away more easily c) when radeon module is used.

I realize the issue report isn't extremely descriptive in terms of debugging. Let me know if there is an easy way to get some data right at the point of those freezes. From my perspective there is no feedback by default; not from dolphin at least.
Comment 1 raneon 2018-06-25 20:35:34 UTC
Since the upgrade to xorg 1.20 I have a similar issue. If I start F1 2017 (Vulkan) on Plasma on Wayland in fullscreen mode, the game will just freeze with a black screen. If I start the game again, it tries to report that crash to Feral, not sure if they can help as it didn't happen with xorg 1.19.
If I select the window mode in the Feral launcher, the game starts, the intro video will be shown and I can play.

Arch Linux
Linux 4.17.2 with AMDGPU.DC=1
Plasma 5.13.1
Wayland 1.15
xorg 1.20
Mesa-git with RADV (2018-06-25)
Radeon RX480
Comment 3 raneon 2018-08-09 20:48:33 UTC
Just upgrade to xorg 1.20.1 in the hope this release would fix this bug. If I start F1 2017 (Vulkan) in fullscreen, I can see now the loading screen, so at least something must have changed. But once the games tries to play the into video, a black screen will be shown again. If I enforce the window mode via Kwin (ALT+F3) with a window boarder, the game usually can be started, but sometimes it crashed and created a report for Feral.

Arch Linux
Linux 4.17.14 with AMDGPU.DC=1
Plasma 5.13.3
Wayland 1.15
xorg 1.20.1
Mesa-git with RADV (2018-08-08)
Radeon RX480
Comment 4 raneon 2018-08-09 20:55:38 UTC
Another game where I have this issue is on Witcher 3 in Wine with DXVK (Vulkan). If the game loads, only a black screen will be shown until I set the game to window mode with window boarders. Tested as well on Plasma Wayland.
Comment 5 raneon 2018-08-20 20:40:58 UTC
In Warhammer 40000: Dawn of War III with Vulkan enabled, I had to change as well to window mode with window boarders to see the output after starting in the game a new match, but at least I could run the benchmark without any issues.
Comment 6 raneon 2018-08-20 21:20:49 UTC
Serious Sam Fusion 2017 (beta) and The Talos Principle are affected as well, they even crash if I don't set the fast enough to window mode with Kwin (ALT + F3).
Comment 7 Michel Dänzer 2018-10-16 09:57:51 UTC
I can't seem to reproduce this, does it still happen with Mesa >= 18.2.y and libX11 >= 1.6.7?
Comment 8 Michel Dänzer 2018-10-16 10:47:34 UTC
I spoke too soon, Talos Principle hangs using Vulkan if "Enable V-Sync" is enabled in the graphics options. Mesa's x11_manage_fifo_queues hangs in xcb_wait_for_special_event here:

      while (chain->last_present_msc < target_msc) {
         xcb_generic_event_t *event =
            xcb_wait_for_special_event(chain->conn, chain->special_event);

So it looks like a PresentCompleteNotify event is either lost somewhere, or has the wrong MSC value.
Comment 10 Michel Dänzer 2018-10-25 16:00:53 UTC
Thanks for the report, fixed in xserver Git master:

commit ace551d8a2603e37b18237a52f62d627c75d9e2a
Author: Michel Dänzer <michel.daenzer@amd.com>
Date:   Thu Oct 18 17:42:01 2018 +0200

    xwayland: Complete "synchronous" Present flips from xwl_present_msc_bump
Comment 11 Michel Dänzer 2018-10-27 14:09:27 UTC
*** Bug 107230 has been marked as a duplicate of this bug. ***
Comment 12 Benjamin Xiao 2019-02-11 11:03:56 UTC
Will this fix be backported into a 1.20.x release? Currently running into this issue with any Vulkan games, including Proton games.
Comment 13 Michel Dänzer 2019-02-11 11:37:58 UTC
The fix is already on the server-1.20-branch in Git, so it'll be in the 1.20.4 release. Unfortunately, there's no specific plan yet for when that'll happen. Meanwhile, maybe ask your distro to pull fixes from the release branch.
Comment 14 Michel Dänzer 2019-02-22 09:51:39 UTC
*** Bug 109711 has been marked as a duplicate of this bug. ***

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.