Bug 466623 - Unable to display screen if computer starts without HDMI cable connected (or without HDMI signal)
Summary: Unable to display screen if computer starts without HDMI cable connected (or ...
Status: RESOLVED UPSTREAM
Alias: None
Product: kwin
Classification: Plasma
Component: wayland-generic (other bugs)
Version First Reported In: 5.27.2
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-02-28 21:29 UTC by Chema
Modified: 2024-12-16 15:07 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
Log when black screen (109.38 KB, text/plain)
2023-02-28 21:29 UTC, Chema
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Chema 2023-02-28 21:29:38 UTC
Created attachment 156839 [details]
Log when black screen

SUMMARY
***
If the computer is booted without HDMI signal (disconnecting the HDMI cable or having another computer active on a KVM switch), then when connecting the computer's HDMI cable or turning on the computer on the KVM switch, the screen looks completely black and it is not possible to recover the signal. Pressing Ctrl + F2 activates the HDMI signal and you can access another console and from there start X11 with KDE, but it is completely impossible to recover the screen in the first session (Ctrl + F1).
***

STEPS TO REPRODUCE
Test 1: with KVM switch (IMPORTANT: without it having EDID emulation)

1. With computer 1 active on the KVM switch, turn on computer 2 that has Linux.
2. Wait a few minutes for the system to load completely and the KDE login screen to appear.
3. Switch control on the KVM switch to the Linux computer.
4. The screen is completely black and there is no way to recover the HDMI signal in that session.

Test 2: no KVM switch

1. Disconnect the HDMI cable from the computer.
2. Boot the computer with Linux.
3. Wait a few minutes for the system to load completely and the KDE login screen to appear.
4. Connect the HDMI cable to the computer.
5. The screen is completely black and there is no way to recover the HDMI signal in that session.

Attached log in case you can see something.

SOFTWARE/OS VERSIONS
Operating System: Manjaro Linux 
KDE Plasma Version: 5.27.2
KDE Frameworks Version: 5.103.0
Qt Version: 5.15.8
Kernel Version: 6.2.1-x64v3-xanmod1 (64-bit)

Graphics Platform: X11 --> It indicates the session that I managed to start from another console, but I don't know the KDE login screen if it is on X11 or Wayland, which is what was displayed when the screen fails, showing black after connecting the HDMI cable.

Processors: 8 × AMD Ryzen 5 3550H with Radeon Vega Mobile Gfx
Memory: 29,3 GiB of RAM
Graphics Processor: AMD Radeon Vega 8 Graphics
Manufacturer: BESSTAR TECH LIMITED
Product Name: UM350

Tested that this error does not occur with GNOME.
Comment 1 Nate Graham 2023-03-01 22:25:21 UTC
Reminds me of Bug 466623, which was traced to be a duplicate of Bug 452614 due to the monitors having identical EDID hash values, but that doesn't seem relevant here since there's only one screen.

One question: is this a regression in Plasma 5.27, or did it always happen in prior Plasma versions, or are you unable to test because Plasma 5.27 is the first version you've tried it with?

Actually now that I think about it, if the screen doesn't turn on while the SDDM login screen is active, then there actually isn't any KDE code running yet (KWin isn't running yet and SDDM isn't a KDE project) so this is either an SDDM bug or a Qt bug. So I'll be very confused if you say that this worked in Plasma 5.26 or earlier. :)
Comment 2 Chema 2023-03-02 02:21:57 UTC
As far as I can remember, since I started using KDE a couple of years ago, I don't really remember what version it was back then, I think it was 5.25 but I'm not sure, this problem has always happened, so I don't think be a regression error (at least, since I've been using it, obviously I can't know the previous versions).

All I can say is that if I try other desktops, like GNOME or Xfce, this problem doesn't happen with them, it only happens with KDE.

I don't know if it only happens to me, but from the beginning I think that KDE has a serious problem with the detection of HDMI on my computer:

- If I boot the computer and it does not receive an HDMI signal while the system boots and the KDE login screen loads, there is no way for that session to recover the HDMI signal, the screen stays completely black.

- If with the computer turned on I change the KVM switch to another computer, even if KDE only loses the HDMI signal for a couple of seconds, when returning to KDE the Powerdevil has crashed.

- If I have a bi-directional EDID emulator connected to the HDMI output and I switch to another computer on the KVM switch and then come back to KDE, the session hangs with a black screen and there is no way to recover that session.

I don't think it's a KDE-only problem, I think more of a QT problem, since Xfce and Gnome (based in GTK) don't have any of these problems, while Mate and Cinnamon do some (but not all) of them.
Comment 3 Chema 2023-03-02 02:56:41 UTC
Sorry, I forgot that Mate and Cinnamon are also based on GTK... So, I don't know the reason for the problem, all I know is that with GNOME (with Wayland), Xfce and Budgie it doesn't give any problem.

As I said before, I think it's all about the detection of the HDMI.

I've had to switch back to KDE with X11 to mitigate some of these issues.
Comment 4 Nate Graham 2023-03-02 15:11:34 UTC
Ok cool, so it's always happened and you're just now reporting it; it's not a regression in Plasma 5.27.
Comment 5 Chema 2023-03-02 15:54:57 UTC
Until a few months ago, when I would suspend the computer with a bi-directional EDID emulator plugged into the HDMI output and wake it up, the screen would go black, but I could switch to another session by pressing Ctrl + F2, which would activate the HDMI, and then I could return to the previous open session by pressing Ctrl + F1 and everything worked fine.

The thing is, since kernel 6.2 was released, the situation has gotten worse. When you do this, the session you had open is completely locked with a black screen and it is completely impossible to return to it.
Comment 6 postix 2024-12-15 15:17:56 UTC
Reminds me of https://github.com/sddm/sddm/issues/2009
Is this the same?
Comment 7 Zamundaaa 2024-12-16 15:07:59 UTC
Can confirm, and yeah it only happens in SDDM