https://bugs.kde.org/show_bug.cgi?id=525955

            Bug ID: 525955
           Summary: kwin_wayland segfaults in Compositor::setupLayers
                    during fullscreen Vulkan gaming, crashes whole session
    Classification: Plasma
           Product: kwin
      Version First 6.7.5
       Reported In:
          Platform: Other
                OS: Linux
            Status: REPORTED
          Severity: normal
          Priority: NOR
         Component: generic-crash
          Assignee: [email protected]
          Reporter: [email protected]
  Target Milestone: ---

Summary: kwin_wayland segfaults in Compositor::setupLayers during fullscreen
Vulkan gaming, crashes whole session

Component: generic-crash (maybe platform-drm, not sure which is right — feel
free to move it)

Version: kwin 6.7.5, CachyOS

Was playing Deadlock (fullscreen, Vulkan, running through Proton
GE-Proton10-29) and kwin_wayland just died mid-game. Not a slowdown or a
stutter first, just instantly gone. Screen goes black basically, and literally
everything else on my desktop lost its Wayland connection at the same time —
Plasma, Konsole, KRunner, KCalc, kded, the xdg-desktop-portal services,
kactivitymanagerd, ksecretd, kdeconnectd, all of it. journalctl is just
wall-to-wall "The Wayland connection broke. Did the Wayland compositor die?"
from every single process, all within about 20ms of each other. Both
xdg-desktop-portal-kde and xdg-desktop-portal-gtk hard crashed too.

The game itself (deadlock.exe) also crashed, but about 48 seconds after kwin
did, and its "crash" is just Wine's own SIGSEGV handler catching a dead surface
— so I'm pretty confident that's just fallout from kwin dying underneath it,
not a separate bug in the game.

Setup:

kwin 6.7.5
mesa 26.2.2
AMD GPU (RADV/radeonsi, confirmed from the thread names in the coredump)
Plasma Wayland session

Kernel log for the actual segfault:

kwin_wayland[906]: segfault at 48600000010 ip 00007f068dabc43e sp
00007fffce2efdc0 error 6 in libc.so.6[bc43e,7f068da24000+1b0000] likely on CPU
6 (core 0, socket 0)

That fault address (0x48600000010) isn't a real pointer — nothing on this
system lives anywhere near that range — so this smells like heap corruption
rather than a plain null deref or an OOM kill. error 6 means it was a write to
an unmapped page from userspace.

Backtrace from coredumpctl:

#0  0x00007f068dabc43e n/a (libc.so.6 + 0xbc43e)
#1  0x00007f068dabd88a n/a (libc.so.6 + 0xbd88a)
#2  0x00007f068e4fbd36 QArrayData::allocate(...) (libQt6Core.so.6 + 0x2fbd36)
#3  0x00007f0690fb875e n/a (libkwin.so.6 + 0x1b875e)
#4  0x00007f0690fb8d4d n/a (libkwin.so.6 + 0x1b8d4d)
#5  0x00007f0690fb035f KWin::Compositor::setupLayers(...) (libkwin.so.6 +
0x1b035f)
#6  0x00007f0690fb27c4 KWin::Compositor::composite(RenderLoop*) (libkwin.so.6 +
0x1b27c4)
#7  0x00007f068e40f13b n/a (libQt6Core.so.6 + 0x20f13b)
#8  0x00007f0691019ec7 KWin::RenderLoop::frameRequested(RenderLoop*)
(libkwin.so.6 + 0x219ec7)
#9  0x00007f068e406039 QObject::event(QEvent*) (libQt6Core.so.6 + 0x206039)
#10 0x00007f068f50642b QApplicationPrivate::notify_helper(...)
(libQt6Widgets.so.6 + 0x10642b)
#11 0x00007f068e395ee8 QCoreApplication::notifyInternal2(...) (libQt6Core.so.6
+ 0x195ee8)
#12 0x00007f068e5a1a2a QTimerInfoList::activateTimers() (libQt6Core.so.6 +
0x3a1a2a)
#13 0x00007f068e5ae5a5 QEventDispatcherUNIX::processEvents(...)
(libQt6Core.so.6 + 0x3ae5a5)
#14 0x00007f068f1f8a22 QUnixEventDispatcherQPA::processEvents(...)
(libQt6Gui.so.6 + 0x7f8a22)
#15 0x00007f068e3a4c54 QEventLoop::exec(...) (libQt6Core.so.6 + 0x1a4c54)
#16 0x00007f068e3999e4 QCoreApplication::exec() (libQt6Core.so.6 + 0x1999e4)
#17 0x000055a3cd64e007 n/a (kwin_wayland + 0x3f007)
#18 0x00007f068da27d0e n/a (libc.so.6 + 0x27d0e)
#19 0x00007f068da27e4b __libc_start_main (libc.so.6 + 0x27e4b)
#20 0x000055a3cd653ea5 n/a (kwin_wayland + 0x44ea5)

Everything else in the coredump is just idle RADV/gallium worker threads
sitting in pthread_cond_wait, so nothing weird happening on other threads at
the time — the crash is squarely in the main thread's compositing path, right
when it's setting up output layers for a frame.

Steps to reproduce: honestly not 100% sure how to trigger it on demand — it
happened during normal play, no alt-tabbing or resolution change that I
noticed. Fullscreen Vulkan + Proton seems to be the common thread. Will update
if I figure out something more reliable.

Happy to attach the actual core dump or run more gdb/coredumpctl stuff against
it if it'd help — I've still got it on disk.

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to