Bug 423014 - kwin_x11 black screen with Depth 30 and compositing (intel and amdgpu)
Summary: kwin_x11 black screen with Depth 30 and compositing (intel and amdgpu)
Alias: None
Product: kwin
Classification: Plasma
Component: compositing (show other bugs)
Version: 5.19.2
Platform: Fedora RPMs Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
: 417455 (view as bug list)
Depends on:
Reported: 2020-06-15 14:00 UTC by Bernie Innocenti
Modified: 2022-02-03 23:05 UTC (History)
8 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.24
vlad.zahorodnii: Intel+


Note You need to log in before you can comment on or make changes to this bug.
Description Bernie Innocenti 2020-06-15 14:00:21 UTC

When kwin_x11 starts on an Xorg screen with a 30bpp visual, the screen is totally black except for the cursor. The window manager is working normally, and it's still possible to toggle compositing on and off with alt-shift-F12.

1. Get a laptop with Intel gpu (I used a i7-10710U, which has CML GT2)
2. Set X11 to 30bpp by dropping this config snippet to /etc/X11/xorg.conf.d/10-depth.conf:

Section "Screen"
        Identifier "default"
        DefaultDepth 30

3. Login!


black screen


A Plasma Desktop in its deep color magnificence.

KDE Plasma Version: 5.18.5 (also tried with kwinft built from git master)
KDE Frameworks Version: 5.70.0
Qt Version: 5.14.2
mesa: 20.1.1
libdrm: 2.4.100
Comment 1 Bernie Innocenti 2020-06-15 14:03:07 UTC
Also important

1. Toggling compositing off fixes this issue
2. 30bpp + compositing works fine on another machine with an AMD gpu (but also different distro and different versions of everything).
Comment 2 Nate Graham 2020-06-23 15:37:28 UTC
I can confirm this issue with my hardware (Lenovo ThinkPad X1 Yoga gen 4, 10 bit screen, Intel GPU)
Comment 3 Bernie Innocenti 2020-06-26 12:37:00 UTC
This fixes the black screen for me on Intel Comet Lake GT2:

 echo "export KWIN_OPENGL_INTERFACE=egl" >~/.config/plasma-workspace/env/use_egl.sh
Comment 4 Bernie Innocenti 2020-06-26 12:38:52 UTC
I double checked, and I consistently get the black screen with XGL.
amdgpu also needs EGL for 30bpp.

Are there any blockers to switch the default to EGL?
Comment 5 Nate Graham 2020-07-17 02:25:36 UTC
*** Bug 417455 has been marked as a duplicate of this bug. ***
Comment 6 David Kredba 2020-08-16 05:54:02 UTC
I am affected by the same.
Gentoo ~amd64, amdgpu.
Compositor is allowed to start with KDE.

KDE Plasma Version: 5.19.4
KDE Frameworks Version: 5.73.0
Qt Version: 5.15.0
mesa: 20.2.0_rc2
libdrm: 2.4.102
Comment 7 Caliburn 2021-11-12 10:07:53 UTC
I have NOT tried loading KDE since July 2021 with 30bpp but can +1 this bug for that time. Also have not tried using EGL therefore cannot confirm. Apologies for the delay on the report.

Sapphire Radeon RX 570 w/ amdgpu and 30bpp resulted in a black KDE desktop with mouse pointer. System ran Arch Linux with all components up-to-date as of July 2021.
Comment 8 Jan Binder 2021-12-11 14:44:50 UTC
I can confirm this bug report and the EGL workaround with the following setup:

Dell UP3218K
AMD Radeon RX 6900 XT

Debian Sid
KDE Frameworks: 5.88.0
KDE Plasma: 5.23.4
Qt: 5.15.2
Mesa: 21.2.6
libdrm: 2.4.108
Comment 9 Bug Janitor Service 2022-01-29 18:45:08 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/1955
Comment 10 Vlad Zahorodnii 2022-01-31 17:22:01 UTC
Git commit e6fb6ff5d3b3c60b0f50a00ed8b7e351e3aaf9a1 by Vlad Zahorodnii, on behalf of Xaver Hugl.
Committed on 31/01/2022 at 16:23.
Pushed by vladz into branch 'master'.

backends/x11/standalone: only use sRGB configurations with depth 24

Credit goes to Mario Kleiner, who bisected this issue.

M  +2    -12   src/backends/x11/standalone/glxbackend.cpp

Comment 11 Zamundaaa 2022-01-31 18:12:39 UTC
Git commit 8732958ce117979e7763d4c6e656189b7e18702c by Xaver Hugl.
Committed on 31/01/2022 at 18:12.
Pushed by zamundaaa into branch 'Plasma/5.24'.

backends/x11/standalone: only use sRGB configurations with depth 24

Credit goes to Mario Kleiner, who bisected this issue.

(cherry picked from commit e6fb6ff5d3b3c60b0f50a00ed8b7e351e3aaf9a1)

M  +2    -12   src/backends/x11/standalone/glxbackend.cpp