Summary: | kwin_wayland DRM backend crashes on simpledrm again | ||
---|---|---|---|
Product: | [Plasma] kwin | Reporter: | bluescreenavenger |
Component: | platform-drm | Assignee: | KWin default assignee <kwin-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | crash | CC: | nate, xaver.hugl |
Priority: | NOR | ||
Version: | master | ||
Target Milestone: | --- | ||
Platform: | Compiled Sources | ||
OS: | Linux | ||
Latest Commit: | https://invent.kde.org/plasma/kwin/commit/f02a6fd128d83b5e20131d1551c31d47b1332db4 | Version Fixed In: |
Description
bluescreenavenger
2022-05-02 22:04:31 UTC
I mean to say kwin_wayland crashes on simpledrm. I am not sure what commit caused it, but I think a build from a week or two ago worked https://invent.kde.org/plasma/kwin/-/merge_requests/2325 should address the crash you're seeing, though I'm not 100% certain it fixes it, as I'm not sure how KWin would get into that state in the first place... Git commit 46bbe4ff0cf68b13874b641eca87a9d360fcbfb7 by Xaver Hugl. Committed on 03/05/2022 at 08:14. Pushed by zamundaaa into branch 'master'. backends/drm: don't rely on test commits producing a buffer When DrmPipeline::commitPipelines returns false without creating a test buffer, we'd crash. M +2 -1 src/backends/drm/drm_pipeline.cpp https://invent.kde.org/plasma/kwin/commit/46bbe4ff0cf68b13874b641eca87a9d360fcbfb7 That fixes the crash, but now it hangs about with a blank screen and it prints some kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Failed to create a gbm surface! kwin_wayland_drm: Checking test buffer failed for (0) kwin_wayland_drm: Failed to find a working setup for new outputs! kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented Does it work with the environment variable KWIN_DRM_USE_MODIFIERS=0 set? I suspect that simpledrm supports modifiers, but your gbm implementation does not That works. This is the info for simpledrm https://drmdb.emersion.fr/snapshots/bbc4de19efa5 dang, why would my gbm be missing modifier support? That comes from Mesa, correct? Maybe something is wrong in the way I built Mesa... the renderer is llvmpipe. I'll explore some Mesa environment variables Sorry about generating more so many comments at once, more investigating with Mesa, one of the only GBM variables is the backend, which the only one I have is the default gbm_dri, no NVIDIA is involved here I tried setting GALLIUM_DRIVER to softpipe instead of llvmpipe, the other GBM_ALWAYS_SOFTWARE=1, I tried that, that doesn't work as well Sorry, I am spamming this, but I figured out how to get more information, by setting QT_LOGGING_RULES="*=true" I hope this info is helpful somewhat kwin_scene_opengl: Egl Initialize succeeded kwin_scene_opengl: EGL version: 1 . 4 kwin_scene_opengl: Created EGL context with attributes: Version requested: true Version: 3.1 Robust: false Reset on video memory purge: false Forward compatible: false Core profile: false Compatibility profile: false High priority: false kwin_scene_opengl: Created EGL context with attributes: Version requested: true Version: 3.1 Robust: false Reset on video memory purge: false Forward compatible: false Core profile: false Compatibility profile: false High priority: false OpenGL vendor string: Mesa/X.org OpenGL renderer string: llvmpipe (LLVM 11.0.1, 256 bits) OpenGL version string: 4.5 (Core Profile) Mesa 21.3.7 (git-d5ec846bc8) OpenGL shading language version string: 4.50 Driver: LLVMpipe GPU class: Unknown OpenGL version: 4.5 GLSL version: 4.50 Mesa version: 21.3.7 Linux kernel version: 5.14.21 Requires strict binding: no GLSL shaders: yes Texture NPOT support: yes Virtual Machine: no kwin_scene_opengl: Filter multi-plane format 961959257 kwin_scene_opengl: Filter multi-plane format 825316697 kwin_scene_opengl: Filter multi-plane format 842093913 kwin_scene_opengl: Filter multi-plane format 909202777 kwin_scene_opengl: Filter multi-plane format 875713881 kwin_scene_opengl: Filter multi-plane format 961893977 kwin_scene_opengl: Filter multi-plane format 825316953 kwin_scene_opengl: Filter multi-plane format 842094169 kwin_scene_opengl: Filter multi-plane format 909203033 kwin_scene_opengl: Filter multi-plane format 875714137 kwin_scene_opengl: Filter multi-plane format 842094158 kwin_scene_opengl: Filter multi-plane format 909203022 kwin_scene_opengl: EGL driver advertises 29 supported dmabuf formats with modifiers kwin_core: OpenGL compositing has been successfully initialized kwin_wayland_drm: Could not find edid for connector DrmConnector(id=31, gpu=KWin::DrmGpu(0x55aa80c52370), name="Unknown-1-unknown", connection="Connected", countMode=1) kwin_wayland_drm: Connector 31 has properties "CRTC_ID"=34, "non-desktop"=0, "DPMS"=0, "EDID"=0, "overscan" not found, "vrr_capable" not found, "underscan" not found, "underscan vborder" not found, "underscan hborder" not found, "Broadcast RGB" not found, "max bpc" not found, "link-status"="Good" kwin_wayland_drm: New output on GPU /dev/dri/card0: Unknown-1-unknown kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Failed to create a gbm surface! kwin_wayland_drm: Checking test buffer failed for (0) kwin_wayland_drm: Flags: none kwin_wayland_drm: Drm objects: kwin_wayland_drm: "connector" 31 kwin_wayland_drm: "CRTC_ID": 34 kwin_wayland_drm: "non-desktop": 0 kwin_wayland_drm: "DPMS": 0 kwin_wayland_drm: "EDID": 0 kwin_wayland_drm: "link-status": 0 kwin_wayland_drm: "crtc" 34 kwin_wayland_drm: "MODE_ID": 41 kwin_wayland_drm: "ACTIVE": 1 kwin_wayland_drm: "VRR_ENABLED": 0 kwin_wayland_drm: "plane" 32 kwin_wayland_drm: "type": 1 kwin_wayland_drm: "SRC_X": 0 kwin_wayland_drm: "SRC_Y": 0 kwin_wayland_drm: "SRC_W": 640 kwin_wayland_drm: "SRC_H": 480 kwin_wayland_drm: "CRTC_X": 0 kwin_wayland_drm: "CRTC_Y": 0 kwin_wayland_drm: "CRTC_W": 640 kwin_wayland_drm: "CRTC_H": 480 kwin_wayland_drm: "FB_ID": 36 kwin_wayland_drm: "CRTC_ID": 34 kwin_wayland_drm: "IN_FORMATS": 33 kwin_wayland_drm: Failed to find a working setup for new outputs! kwin_wayland_drm: adding placeholder output kwin_wayland_drm: Reading output configuration for KWin::DrmOutput(0x55aa8121adc0, name="Unknown-1", geometry=QRect(0,0 640x480), scale=1) kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Could not create gbm surface! Function not implemented kwin_wayland_drm: Failed to create a gbm surface! kwin_wayland_drm: Checking test buffer failed for (0) kwin_wayland_drm: Flags: none kwin_wayland_drm: Drm objects: kwin_wayland_drm: "connector" 31 kwin_wayland_drm: "CRTC_ID": 34 kwin_wayland_drm: "non-desktop": 0 kwin_wayland_drm: "DPMS": 0 kwin_wayland_drm: "EDID": 0 kwin_wayland_drm: "link-status": 0 kwin_wayland_drm: "crtc" 34 kwin_wayland_drm: "MODE_ID": 41 kwin_wayland_drm: "ACTIVE": 1 kwin_wayland_drm: "VRR_ENABLED": 0 kwin_wayland_drm: "plane" 32 kwin_wayland_drm: "type": 1 kwin_wayland_drm: "SRC_X": 0 kwin_wayland_drm: "SRC_Y": 0 kwin_wayland_drm: "SRC_W": 640 kwin_wayland_drm: "SRC_H": 480 kwin_wayland_drm: "CRTC_X": 0 kwin_wayland_drm: "CRTC_Y": 0 kwin_wayland_drm: "CRTC_W": 640 kwin_wayland_drm: "CRTC_H": 480 kwin_wayland_drm: "FB_ID": 36 kwin_wayland_drm: "CRTC_ID": 34 kwin_wayland_drm: "IN_FORMATS": 33 https://invent.kde.org/plasma/kwin/-/merge_requests/2335 should fix the problem Cool, that seems to fix it Git commit f02a6fd128d83b5e20131d1551c31d47b1332db4 by Xaver Hugl. Committed on 10/05/2022 at 17:42. Pushed by zamundaaa into branch 'master'. backends/drm: add fallback for missing gbm modifier support It can happen that a gbm implementation does not support modifiers, while the drm driver does. To prevent that from breaking KWin, fall back to creating a gbm surface without modifiers when creating one with modifiers fails. M +23 -25 src/backends/drm/egl_gbm_layer_surface.cpp M +40 -35 src/backends/drm/gbm_surface.cpp M +10 -3 src/backends/drm/gbm_surface.h M +16 -11 src/backends/drm/virtual_egl_gbm_layer.cpp https://invent.kde.org/plasma/kwin/commit/f02a6fd128d83b5e20131d1551c31d47b1332db4 Thanks! it works! |