kwin_wayland crashes involving dri2_create_drawable when Plasma starts and the llvmpipe driver from Mesa 23.0-rc3 and 23.0-rc4 is used
System information
- OS: Fedora Rawhide/38
- GPU: Integrated AMD Radeon R5 00:01.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Wani [Radeon R5/R6/R7 Graphics] (rev ca)
- Kernel version: kernel-6.2.0-0.rc6.20230201gitc0b67534c95c.47.fc38
- Mesa version: 23.0-rc3 and 23.0-rc4
- Xserver version (if applicable): xorg-x11-server-1.20.14-17.fc38
- Desktop manager and compositor: KDE Plasma 5.26.90 and kwin_wayland
- KDE Plasma Version: 5.26.90
- KDE Frameworks Version: 5.102.0
- Qt Version: 5.15.8
Describe the issue
kwin_wayland crashes repeatedly when Plasma starts and the llvmpipe driver from Mesa 23.0-rc3 and 23.0-rc4 is used resulting in a black screen with a flashing text cursor _ at the top left of the screen. This problem happened every time when booting the Fedora Rawhide live image Fedora-KDE-Live-x86_64-Rawhide-20230202.n.0.iso with mesa-23.0.0~rc4-1.fc38 in a GNOME Boxes QEMU/KVM VM with 3D acceleration disabled using the llvmpipe driver. kwin_wayland crashed 10 times in a row. There were also many other Plasma programs that crashed as shown by coredumpctl after the kwin_wayland ones I guess because kwin_wayland didn't start. This problem didn't happen with llvmpipe from mesa-22.3.3-3.fc38 and earlier. Adam Williamson first reported this problem at https://bugzilla.redhat.com/show_bug.cgi?id=2164667 with the following trace of the crashing thread 1 involving dri2_create_drawable
Thread 1 (Thread 0x7f3ef8a1ee40 (LWP 905)):
#0 0x0000000000000000 in ?? ()
No symbol table info available.
#1 0x00007f3eeaab44c3 in dri2_create_drawable (dri2_dpy=dri2_dpy@entry=0x56095bfae740, config=config@entry=0x56095bf0d850, dri2_surf=dri2_surf@entry=0x56095c3b6210, loaderPrivate=loaderPrivate@entry=0x56095c3b38c0) at ../src/egl/drivers/dri2/egl_dri2.c:1573
createNewDrawable = <optimized out>
#2 0x00007f3eeaab95b1 in dri2_drm_create_window_surface (disp=0x56095bfadbf0, conf=<optimized out>, native_surface=0x56095c3b38c0, attrib_list=0x0) at ../src/egl/drivers/dri2/platform_drm.c:180
dri2_dpy = 0x56095bfae740
dri2_conf = <optimized out>
dri2_surf = 0x56095c3b6210
surface = 0x56095c3b38c0
surf = 0x56095c3b38c0
config = 0x56095bf0d850
#3 0x00007f3eeaab1129 in dri2_create_window_surface (disp=0x56095bfadbf0, conf=0x56095bfb0310, native_window=0x56095c3b38c0, attrib_list=0x0) at ../src/egl/drivers/dri2/egl_dri2.c:1745
dri2_dpy = <optimized out>
ret = <optimized out>
#4 0x00007f3eeaaa266b in _eglCreateWindowSurfaceCommon (disp=0x56095bfadbf0, config=<optimized out>, native_window=0x56095c3b38c0, attrib_list=0x0) at ../src/egl/main/eglapi.c:1082
__rs = {0x0}
__rsp = <optimized out>
conf = 0x56095bfb0310
surf = <optimized out>
ret = <optimized out>
__func__ = "_eglCreateWindowSurfaceCommon"
#5 0x00007f3eff9b2430 in KWin::GbmSurface::createSurface (backend=0x56095bf882f0, size=..., format=875713112, flags=5, config=0x56095bfb0310) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_gbm_surface.cpp:134
surface = 0x56095c3b38c0
eglSurface = <optimized out>
#6 0x00007f3effabccb4 in KWin::EglGbmLayerSurface::createGbmSurface (forceLinear=false, modifiers=..., format=875713112, size=..., this=0x56095bf6daa8) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_egl_layer_surface.cpp:325
config = <optimized out>
ret = std::variant<std::shared_ptr<KWin::GbmSurface>, KWin::GbmSurface::Error> [no contained value]
surface = <optimized out>
allowModifiers = <optimized out>
gbmFlags = <optimized out>
modifiersEnvSet = <optimized out>
modifiersEnv = <optimized out>
allowModifiers = <optimized out>
config = <optimized out>
gbmFlags = <optimized out>
ret = <optimized out>
surface = <optimized out>
ret = <optimized out>
surface = <optimized out>
#7 KWin::EglGbmLayerSurface::createSurface (importMode=KWin::EglGbmLayerSurface::MultiGpuImportMode::Dmabuf, modifiers=..., format=875713112, size=..., this=0x56095bf6daa8) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_egl_layer_surface.cpp:281
ret = {gbmSurface = std::shared_ptr<KWin::GbmSurface> (empty) = {get() = 0x0}, importSwapchain = std::shared_ptr<KWin::DumbSwapchain> (empty) = {get() = 0x0}, importMode = KWin::EglGbmLayerSurface::MultiGpuImportMode::Dmabuf, currentBuffer = std::shared_ptr<KWin::GbmBuffer> (empty) = {get() = 0x0}, currentFramebuffer = std::shared_ptr<KWin::DrmFramebuffer> (empty) = {get() = 0x0}, forceLinear = false}
ret = <optimized out>
#8 KWin::EglGbmLayerSurface::createSurface(QSize const&, QMap<unsigned int, QVector<unsigned long> > const&) const::{lambda(QVector<KWin::GbmFormat> const&, KWin::EglGbmLayerSurface::MultiGpuImportMode)#1}::operator()(QVector<KWin::GbmFormat> const&, KWin::EglGbmLayerSurface::MultiGpuImportMode) const [clone .isra.0] (__closure=__closure@entry=0x7ffcd5b33180, importMode=importMode@entry=KWin::EglGbmLayerSurface::MultiGpuImportMode::Dmabuf, gbmFormats=...) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_egl_layer_surface.cpp:248
surface = std::optional<KWin::EglGbmLayerSurface::Surface> = {[contained value] = {gbmSurface = std::shared_ptr<KWin::GbmSurface> (use count 551797064, weak count -1052120368) = {get() = 0x7f3efdf88160 <QArrayData::shared_null>}, importSwapchain = std::shared_ptr<KWin::DumbSwapchain> (use count -34045600, weak count 32573) = {get() = 0x7ffcd5b330e0}, importMode = (KWin::EglGbmLayerSurface::MultiGpuImportMode::DumbBuffer | unknown: 0xfffffffe), currentBuffer = std::shared_ptr<KWin::GbmBuffer> (use count 1547395312, weak count 22024) = {get() = 0x7ffcd5b33170}, currentFramebuffer = std::shared_ptr<KWin::DrmFramebuffer> (expired, weak count 0) = {get() = 0x7f3eff9a3008 <QVector<KWin::GbmFormat>::realloc(int, QFlags<QArrayData::AllocationOption>)+40>}, forceLinear = 8}}
format = @0x56095c3b6108: {drmFormat = 875713112, bpp = 24, alphaSize = 0}
__for_range = <optimized out>
__for_begin = 0x56095c3b6108
__for_end = <optimized out>
formats = @0x7ffcd5b332a8: {d = 0x56095be6de00}
size = @0x7ffcd5b332b0: {wd = 1280, ht = 800}
this = 0x56095bf6daa8
#9 0x00007f3eff9a724b in KWin::EglGbmLayerSurface::createSurface (formats=..., size=..., this=0x56095bf6daa8) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_egl_layer_surface.cpp:256
surface = std::optional<KWin::EglGbmLayerSurface::Surface> = {[contained value] = {gbmSurface = <error reading variable: Cannot access memory at address 0x7f0100000008>, importSwapchain = <error reading variable: Cannot access memory at address 0x10>, importMode = (unknown: 0xd5b33400), currentBuffer = std::shared_ptr<KWin::GbmBuffer> (use count -6580135, weak count 32573) = {get() = 0x7ffcd5b333f8}, currentFramebuffer = std::shared_ptr<KWin::DrmFramebuffer> (use count 1547383072, weak count 22024) = {get() = 0x7f3efdd32246 <QCryptographicHash::result() const+3542>}, forceLinear = true}}
preferredFormats = {d = 0x56095c3b60f0}
fallbackFormats = {d = 0x7f3efdf88160 <QArrayData::shared_null>}
sort = <optimized out>
testFormats = {__this = 0x56095bf6daa8, __size = @0x7ffcd5b332b0, __formats = @0x7ffcd5b332a8}
preferredFormats = <optimized out>
fallbackFormats = <optimized out>
sort = <optimized out>
testFormats = <optimized out>
it = <optimized out>
format = <optimized out>
surface = <optimized out>
surface = <optimized out>
surface = <optimized out>
surface = <optimized out>
#10 KWin::EglGbmLayerSurface::checkSurface (this=this@entry=0x56095bf6daa8, size=..., formats=...) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_egl_layer_surface.cpp:204
newSurface = std::optional<KWin::EglGbmLayerSurface::Surface> = {[contained value] = {gbmSurface = <error reading variable: Cannot access memory at address 0xb03b3e57d90427ff>, importSwapchain = <error reading variable: Cannot access memory at address 0xe6673214bbb7285d>, importMode = (unknown: 0x56697274), currentBuffer = <error reading variable: Cannot access memory at address 0x6c2d312d72747569>, currentFramebuffer = <error reading variable: Cannot access memory at address 0x3a80000069746f7a>, forceLinear = false}}
#11 0x00007f3eff9a8ec1 in KWin::EglGbmLayerSurface::renderTestBuffer (formats=..., bufferSize=..., this=0x56095bf6daa8) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_egl_layer_surface.cpp:188
No locals.
#12 KWin::EglGbmLayer::checkTestBuffer (this=0x56095bf6da70) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_egl_layer.cpp:68
No locals.
#13 0x00007f3eff9b575a in KWin::DrmPipeline::legacyModeset (this=this@entry=0x56095c3b23a0) at /usr/include/c++/13/bits/shared_ptr_base.h:1665
connId = 34
buffer = std::shared_ptr<KWin::DrmFramebuffer> (use count 1547437184, weak count 22024) = {get() = 0x56095c3c0540}
#14 0x00007f3eff9b93b1 in KWin::DrmPipeline::applyPendingChangesLegacy (this=0x56095c3b23a0) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_pipeline_legacy.cpp:116
err = <optimized out>
vrr = <optimized out>
contentType = <optimized out>
#15 0x00007f3eff9b9859 in KWin::DrmPipeline::commitPipelinesLegacy (mode=KWin::DrmPipeline::CommitMode::TestAllowModeset, pipelines=...) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_pipeline_legacy.cpp:70
pipeline = @0x56095c3c0538: 0x56095c3b23a0
__for_range = @0x56095be81090: {d = 0x56095c3c0520}
__for_begin = 0x56095c3c0538
__for_end = 0x56095c3c0540
err = KWin::DrmPipeline::Error::None
err = <optimized out>
pipeline = <optimized out>
__for_range = <optimized out>
__for_begin = <optimized out>
__for_end = <optimized out>
pipeline = <optimized out>
__for_range = <optimized out>
__for_begin = <optimized out>
__for_end = <optimized out>
pipeline = <optimized out>
__for_range = <optimized out>
__for_begin = <optimized out>
__for_end = <optimized out>
#16 KWin::DrmPipeline::commitPipelines (pipelines=..., mode=KWin::DrmPipeline::CommitMode::TestAllowModeset, unusedObjects=...) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_pipeline.cpp:93
No locals.
#17 0x00007f3eff9ad9de in KWin::DrmGpu::testPipelines (this=0x56095be80ff0) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_gpu.cpp:463
inactivePipelines = {d = 0x7f3efdf88160 <QArrayData::shared_null>}
test = <optimized out>
inactivePipelines = <optimized out>
test = <optimized out>
pipeline = <optimized out>
__for_range = <optimized out>
__for_begin = <optimized out>
__for_end = <optimized out>
pipeline = <optimized out>
__for_range = <optimized out>
__for_begin = <optimized out>
__for_end = <optimized out>
#18 KWin::DrmGpu::checkCrtcAssignment (this=this@entry=0x56095be80ff0, connectors=..., crtcs=...) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_gpu.cpp:368
connector = <optimized out>
pipeline = <optimized out>
currentCrtc = <optimized out>
#19 0x00007f3eff9adf08 in KWin::DrmGpu::checkCrtcAssignment (this=this@entry=0x56095be80ff0, connectors=..., crtcs=...) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_gpu.cpp:403
err = <optimized out>
crtcsLeft = {d = 0x56095c3b60a0}
crtc = @0x56095c3b53a8: 0x56095bea2370
__for_range = @0x7ffcd5b335d0: {d = 0x56095c3b5390}
__for_begin = 0x56095c3b53a8
__for_end = 0x56095c3b53b0
connector = <optimized out>
pipeline = <optimized out>
currentCrtc = 0x0
#20 0x00007f3eff9b0531 in KWin::DrmGpu::testPendingConfiguration (this=0x56095be80ff0) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_gpu.cpp:440
connectors = {d = 0x56095c3b3980}
crtcs = {d = 0x56095c3b5390}
err = <optimized out>
#21 0x00007f3eff99cc5c in KWin::DrmGpu::updateOutputs (this=<optimized out>) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_gpu.cpp:305
resources = <optimized out>
addedOutputs = {d = 0x56095c3c0430}
err = <optimized out>
lessees = <optimized out>
existing = {d = 0x56095c3c0570}
resources = <optimized out>
lessees = <optimized out>
existing = <optimized out>
addedOutputs = <optimized out>
err = <optimized out>
qt_category_enabled = <optimized out>
output = <optimized out>
__for_range = <optimized out>
__for_begin = <optimized out>
__for_end = <optimized out>
leaseActive = <optimized out>
i = <optimized out>
i = <optimized out>
currentConnector = <optimized out>
it = <optimized out>
conn = <optimized out>
it = <optimized out>
conn = <optimized out>
output = <optimized out>
stillExists = <optimized out>
pipeline = <optimized out>
output = <optimized out>
qt_category_enabled = <optimized out>
crtc = <optimized out>
__for_range = <optimized out>
__for_begin = <optimized out>
__for_end = <optimized out>
plane = <optimized out>
__for_range = <optimized out>
__for_begin = <optimized out>
__for_end = <optimized out>
pipeline = <optimized out>
__for_range = <optimized out>
__for_begin = <optimized out>
__for_end = <optimized out>
pipeline = <optimized out>
__for_range = <optimized out>
__for_begin = <optimized out>
__for_end = <optimized out>
output = <optimized out>
__for_range = <optimized out>
__for_begin = <optimized out>
__for_end = <optimized out>
it = <optimized out>
qt_category_enabled = <optimized out>
pipeline = <optimized out>
__for_range = <optimized out>
__for_begin = <optimized out>
__for_end = <optimized out>
output = <optimized out>
__for_range = <optimized out>
__for_begin = <optimized out>
__for_end = <optimized out>
#22 KWin::DrmBackend::updateOutputs (this=0x56095be8b570) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/backends/drm/drm_backend.cpp:325
it = std::unique_ptr<KWin::DrmGpu> = {get() = 0x56095be80ff0}
#23 0x00007f3efdee7ef1 in QtPrivate::QSlotObjectBase::call (a=0x7ffcd5b33bb0, r=<optimized out>, this=0x56095bfa83d0) at ../../include/QtCore/../../src/corelib/kernel/qobjectdefs_impl.h:398
No locals.
#24 doActivate<false> (sender=0x56095bf85b80, signal_index=6, argv=0x7ffcd5b33bb0) at kernel/qobject.cpp:3923
obj = <optimized out>
receiver = <optimized out>
td = <optimized out>
receiverInSameThread = <optimized out>
senderData = {previous = 0x0, receiver = 0x56095be8b570, sender = 0x56095bf85b80, signal = 6}
c = 0x56095bfa8630
connections = {d = 0x56095bfa6a90}
list = <optimized out>
inSenderThread = true
highestConnectionId = 4
signalVector = 0x56095bfa7760
currentThreadId = 0x7f3ef8a1ee40
sp = <optimized out>
signal_spy_set = 0x0
empty_argv = {0x0}
senderDeleted = false
#25 0x00007f3eff7f458f in KWin::Compositor::setupStart (this=0x56095bf85b80) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/composite.cpp:335
availableCompositors = {d = 0x56095be7d450}
candidateCompositors = {d = 0x56095bfa43a0}
#26 0x00007f3eff7f4cf5 in KWin::Compositor::setupStart (this=this@entry=0x56095bf85b80) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/composite.cpp:338
availableCompositors = <optimized out>
candidateCompositors = <optimized out>
userConfigIt = <optimized out>
qt_category_enabled = <optimized out>
type = <optimized out>
__for_range = <optimized out>
__for_begin = <optimized out>
__for_end = <optimized out>
stop = <optimized out>
qt_category_enabled = <optimized out>
qt_category_enabled = <optimized out>
qt_category_enabled = <optimized out>
con = <optimized out>
qt_category_enabled = <optimized out>
qt_category_enabled = <optimized out>
#27 0x00007f3eff7f6008 in KWin::WaylandCompositor::start (this=0x56095bf85b80) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/composite.cpp:799
No locals.
#28 0x00007f3efdedefdb in QObject::event (this=0x56095bf85b80, e=0x56095bfa6070) at kernel/qobject.cpp:1347
mce = 0x56095bfa6070
sender = {previous = 0x0, receiver = 0x56095bf85b80, sender = 0x0, signal = -1}
#29 0x00007f3efd5aece5 in QApplicationPrivate::notify_helper (this=<optimized out>, receiver=0x56095bf85b80, e=0x56095bfa6070) at kernel/qapplication.cpp:3640
consumed = false
filtered = false
#30 0x00007f3efdeb35e8 in QCoreApplication::notifyInternal2 (receiver=0x56095bf85b80, event=0x56095bfa6070) at kernel/qcoreapplication.cpp:1064
selfRequired = true
result = false
cbdata = {0x56095bf85b80, 0x56095bfa6070, 0x7ffcd5b33dcf}
d = <optimized out>
threadData = 0x56095be70bc0
scopeLevelCounter = {threadData = 0x56095be70bc0}
#31 0x00007f3efdeb6a95 in QCoreApplicationPrivate::sendPostedEvents (receiver=receiver@entry=0x0, event_type=event_type@entry=0, data=data@entry=0x56095be70bc0) at kernel/qcoreapplication.cpp:1821
e = 0x56095bfa6070
pe = <optimized out>
r = 0x56095bf85b80
relocker = <optimized out>
event_deleter = {d = 0x56095bfa6070}
locker = {_M_device = 0x56095be70bf0, _M_owns = false}
startOffset = 0
i = @0x56095be70be4: 7
cleanup = {receiver = 0x0, event_type = 0, data = 0x56095be70bc0, exceptionCaught = true}
#32 0x00007f3efdf03311 in QEventDispatcherUNIX::processEvents (this=0x56095be73940, flags=...) at kernel/qeventdispatcher_unix.cpp:468
d = 0x56095be758c0
threadData = 0x56095be70bc0
include_timers = <optimized out>
include_notifiers = <optimized out>
wait_for_events = <optimized out>
canWait = <optimized out>
tm = <optimized out>
wait_tm = {tv_sec = 140723893780512, tv_nsec = 5}
nevents = <optimized out>
#33 0x000056095ae16041 in QUnixEventDispatcherQPA::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
No symbol table info available.
#34 0x00007f3efdeb1fbb in QEventLoop::exec (this=this@entry=0x7ffcd5b34020, flags=..., flags@entry=...) at ../../include/QtCore/../../src/corelib/global/qflags.h:69
d = 0x56095bfa6000
threadData = <optimized out>
locker = {val = 94598196397240}
ref = {d = 0x56095bfa6000, locker = @0x7ffcd5b33fa8, exceptionCaught = true}
app = 0x7ffcd5b342c0
#35 0x00007f3efdeba23b in QCoreApplication::exec () at ../../include/QtCore/../../src/corelib/global/qflags.h:121
threadData = 0x56095be70bc0
eventLoop = {<QObject> = {_vptr.QObject = 0x7f3efe166b48 <vtable for QEventLoop+16>, static staticMetaObject = {d = {superdata = {direct = 0x0}, stringdata = 0x7f3efe06c7a0 <qt_meta_stringdata_QObject>, data = 0x7f3efe06c680 <qt_meta_data_QObject>, static_metacall = 0x7f3efdee5290 <QObject::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, d_ptr = {d = 0x56095bfa6000}, static staticQtMetaObject = {d = {superdata = {direct = 0x0}, stringdata = 0x7f3efe06f740 <qt_meta_stringdata_Qt>, data = 0x7f3efe06c8c0 <qt_meta_data_Qt>, static_metacall = 0x0, relatedMetaObjects = 0x0, extradata = 0x0}}}, static staticMetaObject = {d = {superdata = {direct = 0x7f3efe15e3c0 <QObject::staticMetaObject>}, stringdata = 0x7f3efe066580 <qt_meta_stringdata_QEventLoop>, data = 0x7f3efe066520 <qt_meta_data_QEventLoop>, static_metacall = 0x7f3efdeb1bc0 <QEventLoop::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}}
returnCode = <optimized out>
#36 0x00007f3efe35f5bd in QGuiApplication::exec () at kernel/qguiapplication.cpp:1863
No locals.
#37 0x00007f3efd5aec59 in QApplication::exec () at kernel/qapplication.cpp:2832
No locals.
#38 0x000056095ad32c24 in main (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/kwin-5.26.90-1.fc38.x86_64/src/main_wayland.cpp:628
environment = {d = {d = 0x56095be6fb10}}
a = {<KWin::Application> = {<QApplication> = {<QGuiApplication> = {<QCoreApplication> = {<QObject> = {_vptr.QObject = 0x56095ae697a0 <vtable for KWin::ApplicationWayland+16>, static staticMetaObject = {d = {superdata = {direct = 0x0}, stringdata = 0x7f3efe06c7a0 <qt_meta_stringdata_QObject>, data = 0x7f3efe06c680 <qt_meta_data_QObject>, static_metacall = 0x7f3efdee5290 <QObject::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, d_ptr = {d = 0x56095be70a50}, static staticQtMetaObject = {d = {superdata = {direct = 0x0}, stringdata = 0x7f3efe06f740 <qt_meta_stringdata_Qt>, data = 0x7f3efe06c8c0 <qt_meta_data_Qt>, static_metacall = 0x0, relatedMetaObjects = 0x0, extradata = 0x0}}}, static staticMetaObject = {d = {superdata = {direct = 0x7f3efe15e3c0 <QObject::staticMetaObject>}, stringdata = 0x7f3efe066c60 <qt_meta_stringdata_QCoreApplication>, data = 0x7f3efe066b40 <qt_meta_data_QCoreApplication>, static_metacall = 0x7f3efdeb4ef0 <QCoreApplication::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, static self = 0x7ffcd5b342c0}, static staticMetaObject = {d = {superdata = {direct = 0x7f3efe166ce0 <QCoreApplication::staticMetaObject>}, stringdata = 0x7f3efe7315c0 <qt_meta_stringdata_QGuiApplication>, data = 0x7f3efe731340 <qt_meta_data_QGuiApplication>, static_metacall = 0x7f3efe360670 <QGuiApplication::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}}, static staticMetaObject = {d = {superdata = {direct = 0x7f3efe816b20 <QGuiApplication::staticMetaObject>}, stringdata = 0x7f3efd9868c0 <qt_meta_stringdata_QApplication>, data = 0x7f3efd986740 <qt_meta_data_QApplication>, static_metacall = 0x7f3efd5b2a20 <QApplication::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}}, static staticMetaObject = {d = {superdata = {direct = 0x7f3efdace4a0 <QApplication::staticMetaObject>}, stringdata = 0x7f3effadb580 <_ZL36qt_meta_stringdata_KWin__Application.lto_priv.0>, data = 0x7f3effad54c0 <_ZL30qt_meta_data_KWin__Application.lto_priv.0>, static_metacall = 0x7f3eff7b8f40 <KWin::Application::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, m_eventFilters = {<QListSpecialMethods<QPointer<KWin::X11EventFilterContainer> >> = {<No data fields>}, {p = {static shared_null = {ref = {atomic = {_q_value = std::atomic<int> = { -1 }}}, alloc = 0, begin = 0, end = 0, array = {0x0}}, d = 0x7f3efdf88c40 <QListData::shared_null>}, d = 0x7f3efdf88c40 <QListData::shared_null>}}, m_genericEventFilters = {<QListSpecialMethods<QPointer<KWin::X11EventFilterContainer> >> = {<No data fields>}, {p = {static shared_null = {ref = {atomic = {_q_value = std::atomic<int> = { -1 }}}, alloc = 0, begin = 0, end = 0, array = {0x0}}, d = 0x7f3efdf88c40 <QListData::shared_null>}, d = 0x7f3efdf88c40 <QListData::shared_null>}}, m_eventFilter = std::unique_ptr<KWin::XcbEventFilter> = {get() = 0x56095be7e8e0}, m_followLocale1 = true, m_configLock = false, m_config = {d = 0x56095be7a100}, m_kxkbConfig = {d = 0x56095be8ad70}, m_operationMode = KWin::Application::OperationModeWaylandOnly, m_x11Time = 0, m_rootWindow = 0, m_connection = 0x0, m_useKActivities = true, m_session = std::unique_ptr<KWin::Session> = {get() = 0x56095be87520}, m_outputBackend = std::unique_ptr<KWin::OutputBackend> = {get() = 0x56095be8b570}, m_terminating = false, m_xwaylandScale = 1, m_processEnvironment = {d = {d = 0x56095be6fb10}}, m_pluginManager = std::unique_ptr<KWin::PluginManager> = {get() = 0x0}, m_inputMethod = std::unique_ptr<KWin::InputMethod> = {get() = 0x56095bf85da0}, m_colorManager = std::unique_ptr<KWin::ColorManager> = {get() = 0x0}, m_tabletModeManager = std::unique_ptr<KWin::TabletModeManager> = {get() = 0x56095bfaaf10}, m_screenLockerWatcher = std::unique_ptr<KWin::ScreenLockerWatcher> = {get() = 0x56095be8b400}}, static staticMetaObject = {d = {superdata = {direct = 0x7f3effbee660 <KWin::Application::staticMetaObject>}, stringdata = 0x56095ae1f0a0 <qt_meta_stringdata_KWin__ApplicationWayland>, data = 0x56095ae1d740 <qt_meta_data_KWin__ApplicationWayland>, static_metacall = 0x56095ad34800 <KWin::ApplicationWayland::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, m_startXWayland = false, m_applicationsToStart = {<QList<QString>> = {<QListSpecialMethods<QString>> = {<No data fields>}, {p = {d = 0x7f3efdf88c40 <QListData::shared_null>}, d = 0x7f3efdf88c40 <QListData::shared_null>}}, <No data fields>}, m_inputMethodServerToStart = {d = 0x56095be7dc60}, m_sessionArgument = {d = 0x7f3efdf88160 <QArrayData::shared_null>}, m_xwayland = std::unique_ptr<KWin::Xwl::Xwayland> = {get() = 0x0}, m_xwaylandListenFds = {d = 0x7f3efdf88160 <QArrayData::shared_null>}, m_xwaylandDisplay = {d = 0x7f3efdf88160 <QArrayData::shared_null>}, m_xwaylandXauthority = {d = 0x7f3efdf88160 <QArrayData::shared_null>}, m_settingsWatcher = {value = 0x0, d = 0x0}}
xwaylandOption = {d = {d = 0x56095be72290}}
waylandSocketOption = {d = {d = 0x56095be81b20}}
x11DisplayOption = {d = {d = 0x56095be81b60}}
waylandDisplayOption = {d = {d = 0x56095be81ba0}}
virtualFbOption = {d = {d = 0x56095be81be0}}
widthOption = {d = {d = 0x56095be81c50}}
heightOption = {d = {d = 0x56095be81cf0}}
scaleOption = {d = {d = 0x56095be81db0}}
outputCountOption = {d = {d = 0x56095be81fa0}}
waylandSocketFdOption = {d = {d = 0x56095be82060}}
xwaylandListenFdOption = {d = {d = 0x56095be820d0}}
xwaylandDisplayOption = {d = {d = 0x56095be82140}}
xwaylandXAuthorityOption = {d = {d = 0x56095be82180}}
replaceOption = {d = {d = 0x56095be822d0}}
drmOption = {d = {d = 0x56095be82310}}
locale1Option = {d = {d = 0x56095be82470}}
parser = {d = 0x56095be7d280}
inputMethodOption = {d = {d = 0x56095be83250}}
screenLockerOption = {d = {d = 0x56095be83420}}
noScreenLockerOption = {d = {d = 0x56095be834c0}}
noGlobalShortcutsOption = {d = {d = 0x56095be835c0}}
noActivitiesOption = {d = {d = 0x56095be836d0}}
exitWithSessionOption = {d = {d = 0x56095be83890}}
backendType = <optimized out>
pluginName = {d = 0x7f3efdf88160 <QArrayData::shared_null>}
initialWindowSize = {wd = 1024, ht = 768}
outputCount = <optimized out>
outputScale = <optimized out>
ok = true
width = <optimized out>
height = <optimized out>
scale = <optimized out>
count = <optimized out>
server = <optimized out>
flags = <optimized out>
socketName = {d = 0x7f3efdf88160 <QArrayData::shared_null>}
BackendType::Kms = BackendType::Kms
BackendType::X11 = BackendType::X11
BackendType::Wayland = BackendType::Wayland
BackendType::Virtual = BackendType::Virtual
The trace had errors accessing memory in frame 9 in KWin::EglGbmLayerSurface::createSurface
surface = std::optional<KWin::EglGbmLayerSurface::Surface> = {[contained value] = {gbmSurface = <error reading variable: Cannot access memory at address 0x7f0100000008>, importSwapchain = <error reading variable: Cannot access memory at address 0x10>,
Frame 10 had similar errors in KWin::EglGbmLayerSurface::checkSurface
newSurface = std::optional<KWin::EglGbmLayerSurface::Surface> = {[contained value] = {gbmSurface = <error reading variable: Cannot access memory at address 0xb03b3e57d90427ff>, importSwapchain = <error reading variable: Cannot access memory at address 0xe6673214bbb7285d>, importMode = (unknown: 0x56697274), currentBuffer = <error reading variable: Cannot access memory at address 0x6c2d312d72747569>, currentFramebuffer = <error reading variable: Cannot access memory at address 0x3a80000069746f7a>, forceLinear = false}}
Those errors might indicate memory corruption in the Wayland surface kwin was creating or using which could've led to the crash higher in the trace. I'm attaching the full trace of all threads of the kwin_wayland crash using llvmpipe from mesa 23.0-rc3 by Adam Williamson from https://bugzilla.redhat.com/show_bug.cgi?id=2164667#c10
When I booted Fedora-KDE-Live-x86_64-Rawhide-20230202.n.0.iso in a GNOME Boxes QEMU/KVM VM with 3D acceleration disabled using the llvmpipe driver after the black screen I ran startx & from another VT . Plasma on X ran normally. So the problem might be specific to Plasma on Wayland. I disabled automatic login from sddm in System Settings and logged out. kwin_wayland as the sddm Wayland compositor crashed with the same type of trace after logging out. The black screen problem with the flashing text cursor at the top left happened on logout.
Plasma started normally without these crashes with Fedora-KDE-Live-x86_64-Rawhide-20230202.n.0.iso in a GNOME Boxes QEMU/KVM VM with 3D acceleration enabled using the virgl mesa driver and virtio_gpu kernel driver and on bare metal using the radeonsi mesa driver and amdgpu and driver with amd_iommu=off on the kernel command line to work around the black screen problem involving amdgpu and AMD IOMMUs with 6.2 kernels I reported at https://bugzilla.redhat.com/show_bug.cgi?id=2156691 The kwin_wayland crash might be specific to the use of the llvmpipe driver.
A mesa patch at !20955 (closed) didn't fix the problem according to Adam at https://bugzilla.redhat.com/show_bug.cgi?id=2164667#c26
Regression
This is a regression which started with the 23.0 branch and was first seen with 23.0-rc3 by Adam as mentioned. mesa-22.3.3-3.fc38 and earlier wasn't affected.
Log files as attachment
- Output of
dmesg
- Backtrace kdebt.txt
- Gpu hang details
Any extra information would be greatly appreciated
STEPS TO REPRODUCE
- Boot a Fedora 37 KDE Plasma installation updated to 2023-2-3 with updates-testing enabled
- Log in to Plasma on Wayland
- Download Fedora-KDE-Live-x86_64-Rawhide-20230202.n.0.iso from https://koji.fedoraproject.org/koji/buildinfo?buildID=2145429 mesa-23.0.0~rc4-1.fc38 was untagged from Rawhide due to this problem so later images might have mesa-22.3.3-3.fc38 and so would not be affected https://pagure.io/releng/issue/11247
- Install GNOME Boxes if it isn't already with sudo dnf install gnome-boxes
- Start GNOME Boxes
- boot the Fedora Rawhide live image Fedora-KDE-Live-x86_64-Rawhide-20230202.n.0.iso in a GNOME Boxes QEMU/KVM VM with 3D acceleration disabled using the llvmpipe driver, EFI enabled, and 3 GB RAM
I've seen frequent journal warnings that the dri2 screen wasn't created in recent Rawhide KDE Plasma GNOME Boxes QEMU/KVM VMs with 3D acceleration disabled using llvmpipe like the following in my report on plasmashell crashes at https://bugs.kde.org/show_bug.cgi?id=464258 plasmashell[2722]: libEGL warning: egl: failed to create dri2 screen
The dri2 screen not being created properly might be related to this problem crashes with mesa-23.0.0~rc3-2.fc38 and later given the similarities in the functions and variables like dri2_create_drawable and dri2_dpy->dri2->createNewDrawable. I didn't see the libEGL warning: egl: failed to create dri2 screen in the journal with Fedora-KDE-Live-x86_64-Rawhide-20230202.n.0.iso in a GNOME Boxes QEMU/KVM VM with 3D acceleration disabled using the llvmpipe driver after the black screen from another VT. Those warnings happened with many KDE programs including kwin_wayland_wrapper in Rawhide KDE Plasma VMs from the last few weeks at least, but I only saw them when the llvmpipe driver was used and not with virgl and virtio_gpu or radeonsi and amdgpu. Those other KDE programs might not have been running long enough for the dri2 screen warnings to appear with Fedora-KDE-Live-x86_64-Rawhide-20230202.n.0.iso before kwin_wayland crashed.