Bug 451561

Summary: Freeze on hovering panel thumbnails: kwin_wayland_drm: an error occurred while swapping buffers "EGL_BAD_SURFACE"
Product: [Plasma] kwin Reporter: Thiago Sueto <herzenschein>
Component: wayland-genericAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: aleixpol, nate, xaver.hugl
Priority: NOR Keywords: wayland-only
Version First Reported In: git master   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Thiago Sueto 2022-03-16 09:13:04 UTC
SUMMARY
Recent Plasma Wayland from git has been freezing often for me, and I think it's happening when hovering panel thumbnails, as often the freeze happens precisely when the thumbnail appears, but without content in it.

It's a complete freeze of the system, I can't enter input, move the mouse or change to a TTY, and if it stays long enough, it doesn't even send information to the monitor. Had to forcefully shutdown via the button on my laptop.

The only useful information I can find is the following to errors (--priority err) in journalctl:

kwin_wayland[2240]: kwin_wayland_drm: an error occurred while swapping buffers "EGL_BAD_SURFACE"
kwin_wayland[2240]: kscreenlocker: Greeter Process not available

I haven't checked if it's actually crashing yet, I didn't have coredumpctl installed. I'll be checking for more information this week. What should I use to provide better information for this?

Operating System: openSUSE Tumbleweed 20220312
KDE Plasma Version: 5.24.80
KDE Frameworks Version: 5.93.0
Qt Version: 5.15.2
Kernel Version: 5.16.11-1-default (64-bit)
Graphics Platform: Wayland
Processors: 4 × Intel® Core™ i7-5500U CPU @ 2.40GHz
Memory: 7.7 GiB of RAM
Graphics Processor: Mesa Intel® HD Graphics 5500
Comment 1 Thiago Sueto 2022-03-16 09:22:28 UTC
Correction: it does let me switch to a TTY. The only error I see when switching to it, logging in and inspecting journalctl is the EGL_BAD_SURFACE one.

Also, now that I tried, moving the mouse constantly does seem to flicker it, even if it doesn't actually move.

And yeah, it's definitely 100% occurring when hovering panel thumbnails, but only when it fails to fetch the contents. Sometimes it works fine, namely when the contents are fetched correctly.
Comment 2 Thiago Sueto 2022-03-16 11:46:42 UTC
Hmm, this might be related to pipewire (seeing as the panel thumbnails use that). If it helps, my current version is 0.3.48 and I have wireplumber 0.4.8.

I get the exact same freeze with the exact same error message when attempting to share a window on OBS Studio 27.2.3. Sharing a screen works fine, though.
Comment 3 Zamundaaa 2022-04-25 13:30:00 UTC
Is this still happening? I think you were affected by the commit https://invent.kde.org/plasma/kwin/-/merge_requests/2145 fixed
Comment 4 Thiago Sueto 2022-04-25 15:52:05 UTC
The OBS window capturing and the panel thumbnails issue seems to be gone, but I did experience a freeze with overview that might or might not be related, as it didn't seem to produce the same error in journalctl.

I'll test for a few more days and see if I can reproduce it still.
Comment 5 Thiago Sueto 2022-04-27 17:22:56 UTC
This is no longer reproducible for me. Thank you.