Bug 472080

Summary: Kwin crash in pw_protocol_native_connection_begin
Product: [Plasma] kwin Reporter: Patrick Silva <bugseforuns>
Component: generalAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED UPSTREAM    
Severity: crash CC: kde
Priority: NOR    
Version First Reported In: 5.27.6   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
URL: https://gitlab.freedesktop.org/pipewire/pipewire/-/issues/3243
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Patrick Silva 2023-07-08 19:10:08 UTC
SUMMARY
My hdmi monitor was in power saving mode, I moved my mouse, the monitor left the power saving mode and then kwin_wayland crashed.


Operating System: Arch Linux 
KDE Plasma Version: 5.27.6
KDE Frameworks Version: 5.107.0
Qt Version: 5.15.10
Graphics Platform: Wayland

Invalid thread ID: appy all bt

Thread 10 (Thread 0x7faf867fe6c0 (LWP 681)):
#0  0x00007fafab913c0f in __GI___poll (fds=0x7faf740013d0, nfds=1, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:29
#1  0x00007fafaa36da9f in sysprof_collector_get () at /usr/lib/libglib-2.0.so.0
#2  0x00007faf867fdca0 in  ()
#3  0x000055bd5ea14f38 in  ()
#4  0x00007faf74001310 in  ()
#5  0x00007faf7400136c in  ()
#6  0x0000000000000024 in  ()
#7  0x000055bd5e4a8d20 in  ()
#8  0x00007fafac89a484 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) (this=0x7faf74000b90, flags=...) at ../../include/QtCore/../../src/corelib/global/qflags.h:69
#9  0x00007fafac6f72b6 in QThread::exec() (this=<optimized out>) at ../../include/QtCore/../../src/corelib/global/qflags.h:121
#10 0x00007fafad6c2ab0 in  () at /usr/lib/libQt5Qml.so.5
#11 0x00007fafac6f34da in operator() (__closure=<optimized out>) at thread/qthread_unix.cpp:350
#12 (anonymous namespace)::terminate_on_exception<QThreadPrivate::start(void*)::<lambda()> > (t=<optimized out>) at thread/qthread_unix.cpp:287
#13 QThreadPrivate::start(void*) (arg=0x55bd5ea12870) at thread/qthread_unix.cpp:310
#14 0x00007fafab89d44b in start_thread (arg=<optimized out>) at pthread_create.c:444
#15 0x00007fafab920e40 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 9 (Thread 0x7faf94ffe6c0 (LWP 661)):
#0  0x00007fafab899f0e in __futex_abstimed_wait_common64 (private=0, cancel=true, abstime=0x0, op=393, expected=0, futex_word=0x7fafa476f594) at futex-internal.c:57
#1  __futex_abstimed_wait_common (futex_word=futex_word@entry=0x7fafa476f594, expected=expected@entry=0, clockid=clockid@entry=0, abstime=abstime@entry=0x0, private=private@entry=0, cancel=cancel@entry=true) at futex-internal.c:87
#2  0x00007fafab899f8f in __GI___futex_abstimed_wait_cancelable64 (futex_word=futex_word@entry=0x7fafa476f594, expected=expected@entry=0, clockid=clockid@entry=0, abstime=abstime@entry=0x0, private=private@entry=0) at futex-internal.c:139
#3  0x00007fafab89c7a0 in __pthread_cond_wait_common (abstime=0x0, clockid=0, mutex=0x7fafa476f540, cond=0x7fafa476f568) at pthread_cond_wait.c:503
#4  ___pthread_cond_wait (cond=0x7fafa476f568, mutex=0x7fafa476f540) at pthread_cond_wait.c:618
#5  0x00007faf9dec7a4c in cnd_wait () at ../mesa-23.1.3/src/c11/impl/threads_posix.c:135
#6  util_queue_thread_func() () at ../mesa-23.1.3/src/util/u_queue.c:290
#7  0x00007faf9df1495c in impl_thrd_routine() () at ../mesa-23.1.3/src/c11/impl/threads_posix.c:67
#8  0x00007fafab89d44b in start_thread (arg=<optimized out>) at pthread_create.c:444
#9  0x00007fafab920e40 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 8 (Thread 0x7faf6305e6c0 (LWP 34812)):
#0  0x00007fafab921266 in epoll_wait (epfd=88, events=events@entry=0x7faf6305d920, maxevents=32, timeout=-1) at ../sysdeps/unix/sysv/linux/epoll_wait.c:30
#1  0x00007faf9ff24c59 in impl_pollfd_wait (object=<optimized out>, pfd=<optimized out>, ev=0x7faf6305daf0, n_ev=<optimized out>, timeout=<optimized out>) at ../pipewire/spa/plugins/support/system.c:137
#2  0x00007faf9ff174fd in loop_iterate (object=0x55bd604c1e98, timeout=-1) at ../pipewire/spa/plugins/support/loop.c:458
#3  0x00007fafac564892 in do_loop (user_data=0x55bd5e9ce8e0) at ../pipewire/src/pipewire/data-loop.c:64
#4  0x00007fafab89d44b in start_thread (arg=<optimized out>) at pthread_create.c:444
#5  0x00007fafab920e40 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 7 (Thread 0x7faf86fff6c0 (LWP 2412)):
#0  0x00007fafab899f0e in __futex_abstimed_wait_common64 (private=0, cancel=true, abstime=0x0, op=393, expected=0, futex_word=0x55bd5f58ed70) at futex-internal.c:57
#1  __futex_abstimed_wait_common (futex_word=futex_word@entry=0x55bd5f58ed70, expected=expected@entry=0, clockid=clockid@entry=0, abstime=abstime@entry=0x0, private=private@entry=0, cancel=cancel@entry=true) at futex-internal.c:87
#2  0x00007fafab899f8f in __GI___futex_abstimed_wait_cancelable64 (futex_word=futex_word@entry=0x55bd5f58ed70, expected=expected@entry=0, clockid=clockid@entry=0, abstime=abstime@entry=0x0, private=private@entry=0) at futex-internal.c:139
#3  0x00007fafab89c7a0 in __pthread_cond_wait_common (abstime=0x0, clockid=0, mutex=0x55bd5f58ed20, cond=0x55bd5f58ed48) at pthread_cond_wait.c:503
#4  ___pthread_cond_wait (cond=0x55bd5f58ed48, mutex=0x55bd5f58ed20) at pthread_cond_wait.c:618
#5  0x00007faf9dec7a4c in cnd_wait () at ../mesa-23.1.3/src/c11/impl/threads_posix.c:135
#6  util_queue_thread_func() () at ../mesa-23.1.3/src/util/u_queue.c:290
#7  0x00007faf9df1495c in impl_thrd_routine() () at ../mesa-23.1.3/src/c11/impl/threads_posix.c:67
#8  0x00007fafab89d44b in start_thread (arg=<optimized out>) at pthread_create.c:444
#9  0x00007fafab920e40 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 6 (Thread 0x7faf957ff6c0 (LWP 660)):
#0  0x00007fafab899f0e in __futex_abstimed_wait_common64 (private=0, cancel=true, abstime=0x0, op=393, expected=0, futex_word=0x7fafa484b590) at futex-internal.c:57
#1  __futex_abstimed_wait_common (futex_word=futex_word@entry=0x7fafa484b590, expected=expected@entry=0, clockid=clockid@entry=0, abstime=abstime@entry=0x0, private=private@entry=0, cancel=cancel@entry=true) at futex-internal.c:87
#2  0x00007fafab899f8f in __GI___futex_abstimed_wait_cancelable64 (futex_word=futex_word@entry=0x7fafa484b590, expected=expected@entry=0, clockid=clockid@entry=0, abstime=abstime@entry=0x0, private=private@entry=0) at futex-internal.c:139
#3  0x00007fafab89c7a0 in __pthread_cond_wait_common (abstime=0x0, clockid=0, mutex=0x7fafa484b540, cond=0x7fafa484b568) at pthread_cond_wait.c:503
#4  ___pthread_cond_wait (cond=0x7fafa484b568, mutex=0x7fafa484b540) at pthread_cond_wait.c:618
#5  0x00007faf9dec7a4c in cnd_wait () at ../mesa-23.1.3/src/c11/impl/threads_posix.c:135
#6  util_queue_thread_func() () at ../mesa-23.1.3/src/util/u_queue.c:290
#7  0x00007faf9df1495c in impl_thrd_routine() () at ../mesa-23.1.3/src/c11/impl/threads_posix.c:67
#8  0x00007fafab89d44b in start_thread (arg=<optimized out>) at pthread_create.c:444
#9  0x00007fafab920e40 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 5 (Thread 0x7fafa588b6c0 (LWP 658)):
#0  0x00007fafab899f0e in __futex_abstimed_wait_common64 (private=0, cancel=true, abstime=0x0, op=393, expected=0, futex_word=0x55bd5e4ac058) at futex-internal.c:57
#1  __futex_abstimed_wait_common (futex_word=futex_word@entry=0x55bd5e4ac058, expected=expected@entry=0, clockid=clockid@entry=0, abstime=abstime@entry=0x0, private=private@entry=0, cancel=cancel@entry=true) at futex-internal.c:87
#2  0x00007fafab899f8f in __GI___futex_abstimed_wait_cancelable64 (futex_word=futex_word@entry=0x55bd5e4ac058, expected=expected@entry=0, clockid=clockid@entry=0, abstime=abstime@entry=0x0, private=private@entry=0) at futex-internal.c:139
#3  0x00007fafab89c7a0 in __pthread_cond_wait_common (abstime=0x0, clockid=0, mutex=0x55bd5e4ac008, cond=0x55bd5e4ac030) at pthread_cond_wait.c:503
#4  ___pthread_cond_wait (cond=0x55bd5e4ac030, mutex=0x55bd5e4ac008) at pthread_cond_wait.c:618
#5  0x00007faf9dec7a4c in cnd_wait () at ../mesa-23.1.3/src/c11/impl/threads_posix.c:135
#6  util_queue_thread_func() () at ../mesa-23.1.3/src/util/u_queue.c:290
#7  0x00007faf9df1495c in impl_thrd_routine() () at ../mesa-23.1.3/src/c11/impl/threads_posix.c:67
#8  0x00007fafab89d44b in start_thread (arg=<optimized out>) at pthread_create.c:444
#9  0x00007fafab920e40 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 4 (Thread 0x7fafa508a6c0 (LWP 659)):
#0  0x00007fafab913c0f in __GI___poll (fds=0x7faf880013f0, nfds=2, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:29
#1  0x00007fafaa36da9f in sysprof_collector_get () at /usr/lib/libglib-2.0.so.0
#2  0x00007fafa5089cc0 in  ()
#3  0x000055bd5e591e58 in  ()
#4  0x00007faf88001330 in  ()
#5  0x00007faf8800138c in  ()
#6  0x0000000000000024 in  ()
#7  0x000055bd5e4a8d20 in  ()
#8  0x00007fafac89a484 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) (this=0x7faf88000b90, flags=...) at ../../include/QtCore/../../src/corelib/global/qflags.h:69
#9  0x00007fafac6f72b6 in QThread::exec() (this=<optimized out>) at ../../include/QtCore/../../src/corelib/global/qflags.h:121
#10 0x00007fafac6f34da in operator() (__closure=<optimized out>) at thread/qthread_unix.cpp:350
#11 (anonymous namespace)::terminate_on_exception<QThreadPrivate::start(void*)::<lambda()> > (t=<optimized out>) at thread/qthread_unix.cpp:287
#12 QThreadPrivate::start(void*) (arg=0x55bd5e52cef8) at thread/qthread_unix.cpp:310
#13 0x00007fafab89d44b in start_thread (arg=<optimized out>) at pthread_create.c:444
#14 0x00007fafab920e40 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 3 (Thread 0x7fafa69ff6c0 (LWP 656)):
#0  0x00007fafab913c0f in __GI___poll (fds=0x7fafa0001600, nfds=3, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:29
#1  0x00007fafaa36da9f in sysprof_collector_get () at /usr/lib/libglib-2.0.so.0
#2  0x00007fafa69fec90 in  ()
#3  0x000055bd5e4ab868 in  ()
#4  0x00007fafa0001540 in  ()
#5  0x00007fafa000159c in  ()
#6  0x0000000000000024 in  ()
#7  0x000055bd5e4a8d20 in  ()
#8  0x00007fafac89a484 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) (this=0x7fafa0000b90, flags=...) at ../../include/QtCore/../../src/corelib/global/qflags.h:69
#9  0x00007fafac6f72b6 in QThread::exec() (this=this@entry=0x7fafae836660 <(anonymous namespace)::Q_QGS__q_manager::innerFunction()::holder>) at ../../include/QtCore/../../src/corelib/global/qflags.h:121
#10 0x00007fafae7cea9a in QDBusConnectionManager::run() (this=0x7fafae836660 <(anonymous namespace)::Q_QGS__q_manager::innerFunction()::holder>) at /usr/src/debug/qt5-base/qtbase/src/dbus/qdbusconnection.cpp:179
#11 0x00007fafac6f34da in operator() (__closure=<optimized out>) at thread/qthread_unix.cpp:350
#12 (anonymous namespace)::terminate_on_exception<QThreadPrivate::start(void*)::<lambda()> > (t=<optimized out>) at thread/qthread_unix.cpp:287
#13 QThreadPrivate::start(void*) (arg=0x7fafae836660 <(anonymous namespace)::Q_QGS__q_manager::innerFunction()::holder>) at thread/qthread_unix.cpp:310
#14 0x00007fafab89d44b in start_thread (arg=<optimized out>) at pthread_create.c:444
#15 0x00007fafab920e40 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 2 (Thread 0x7faf5874d6c0 (LWP 23329)):
#0  0x00007fafab913c0f in __GI___poll (fds=0x7faf500013d0, nfds=1, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:29
#1  0x00007fafaa36da9f in sysprof_collector_get () at /usr/lib/libglib-2.0.so.0
#2  0x00007faf5874cca0 in  ()
#3  0x000055bd5fada948 in  ()
#4  0x00007faf50001310 in  ()
#5  0x00007faf5000136c in  ()
#6  0x0000000000000024 in  ()
#7  0x000055bd5e4a8d20 in  ()
#8  0x00007fafac89a484 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) (this=0x7faf50000b90, flags=...) at ../../include/QtCore/../../src/corelib/global/qflags.h:69
#9  0x00007fafac6f72b6 in QThread::exec() (this=<optimized out>) at ../../include/QtCore/../../src/corelib/global/qflags.h:121
#10 0x00007fafad6c2ab0 in  () at /usr/lib/libQt5Qml.so.5
#11 0x00007fafac6f34da in operator() (__closure=<optimized out>) at thread/qthread_unix.cpp:350
#12 (anonymous namespace)::terminate_on_exception<QThreadPrivate::start(void*)::<lambda()> > (t=<optimized out>) at thread/qthread_unix.cpp:287
#13 QThreadPrivate::start(void*) (arg=0x55bd5f9c4500) at thread/qthread_unix.cpp:310
#14 0x00007fafab89d44b in start_thread (arg=<optimized out>) at pthread_create.c:444
#15 0x00007fafab920e40 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

Thread 1 (Thread 0x7fafa6eb2ec0 (LWP 647)):
#0  pw_protocol_native_connection_begin (msg=0x0, opcode=<optimized out>, id=<optimized out>, conn=0x0) at ../pipewire/src/modules/module-protocol-native/connection.c:679
#1  impl_ext_begin_proxy (proxy=<optimized out>, opcode=1 '\001', msg=0x0) at ../pipewire/src/modules/module-protocol-native.c:1360
#2  0x00007faf9dd51a60 in core_method_marshal_hello (object=0x55bd5ffea3a0, version=4) at ../pipewire/src/modules/module-protocol-native/protocol-native.c:39
#3  0x00007fafac56762f in core_new (context=0x55bd5f9e0cd0, properties=<optimized out>, user_data_size=<optimized out>) at ../pipewire/src/pipewire/core.c:358
#4  0x00007fafac56797f in core_new (context=<optimized out>, properties=0x55bd5eefb5e0, user_data_size=140734557493104) at ../pipewire/src/pipewire/core.c:309
#5  0x000055bd5ffe6de0 in  ()
#6  0x000055bd5ffe6dd0 in  ()
#7  0x000055bd5ffe6dd0 in  ()
#8  0x00007fff514e97a0 in  ()
#9  0x000055bd5f618600 in  ()
#10 0x000055bd5eeb79f0 in  ()
#11 0x0000000000000000 in  ()
Comment 1 Vlad Zahorodnii 2023-08-24 07:56:03 UTC
Did you update wireplumber or pipewire without rebooting the computer?
Comment 2 Patrick Silva 2023-08-25 11:34:58 UTC
(In reply to Vlad Zahorodnii from comment #1)
> Did you update wireplumber or pipewire without rebooting the computer?

It's possible, i'm not sure though.

I have just updated to pipewire 1:0.3.78-1 and kwin_wayland did not crash after hte monitor leaving the power saving mode this time.
Comment 3 Vlad Zahorodnii 2023-08-30 12:19:47 UTC
It sounds like an upstream issue