Bug 490623

Summary: [Wayland] DisplayPort monitor doesn't wake up if the PC wakes up from suspend first
Product: [Plasma] plasmashell Reporter: valdikss
Component: Power management & brightnessAssignee: Plasma Bugs List <plasma-bugs>
Status: CONFIRMED ---    
Severity: normal CC: jpetso, kdedev, natalie_clarius, nate
Priority: NOR Keywords: wayland-only
Version: 6.2.4   
Target Milestone: 1.0   
Platform: Other   
OS: Linux   
See Also: https://bugs.kde.org/show_bug.cgi?id=493974
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description valdikss 2024-07-21 21:38:50 UTC
SUMMARY

When the monitor is powered off and the PC is suspended, turning the PC on first, then the monitor, results in no picture on the display, which most of the time could not be fixed by any regular means: powering off/on the monitor or replugging the cable to another USB-C port does not work.

This happens only in Wayland session, on both Fedora 39 (Plasma 5.27.11) and Neon 2024 07 18 (Plasma 6.1.2). No such issues with HDMI connection.

STEPS TO REPRODUCE
1. Run KDE Plasma 5 or 6 with DisplayPort monitor
2. Suspend the PC, turn the monitor off
3. Wake up the PC, turn the monitor on (in this order)

OBSERVED RESULT
No signal on the display

EXPECTED RESULT
The monitor displays lock screen

SOFTWARE/OS VERSIONS
Operating System: Fedora Linux 39 (also tested on Neon 2024 07 18)
KDE Plasma Version: 5.27.11 (also tested on Neon's 6.1.2)
KDE Frameworks Version: 5.115.0
Qt Version: 5.15.13
Kernel Version: 6.9.9-100.fc39.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 16 × 13th Gen Intel® Core™ i5-1340P
Memory: 28,9 GiB of RAM
Graphics Processor: Mesa Intel® Graphics
Manufacturer: Intel(R) Client Systems
Product Name: NUC13ANKi5
System Version: N11211-203

ADDITIONAL INFORMATION

The issue happens only in Wayland session, only with KDE. No issues with KDE@X11, or Gnome@Wayland.
I have DELL P2415Q 4K monitor connected to NUC13ANKi5 via USB-C → DisplayPort cable. No issues with HDMI connection.
`kscreen-doctor -o` over SSH shows no displays when this happens.
100% reproducibility.
Comment 1 valdikss 2024-10-02 04:04:58 UTC
Still the issue as of KDE Neon neon-unstable-20240930-0323.iso
Comment 2 Nate Graham 2024-10-02 16:03:32 UTC
I'm not able to reproduce this issue with current git master on my setup (laptop docked with DP monitor) because I run into another bug: at step 2, when I put my laptop to sleep, both it and its DP-connected external screen immediately wake up again. I don't have a desktop system I can use to test your exact use case.

I've opened Bug 493974 about this. Possibly one or both are actually KWin issues, but for now let's keep them in Powerdevil for initial triage.
Comment 3 valdikss 2024-10-02 16:16:30 UTC
>when I put my laptop

First of all I'd like to stress that most probably this bug is visible only with a single monitor, which gets disconnected. With 2 monitors connected to the PC I don't see it (one DP, one HDMI). That's why you probably won't see it on the laptop, which has internal screen.

Also when this issue happens, I switch to TTY (blindly), if I connect HDMI monitor, the DP monitor wakes up and works as expected. But as soon as I disconnect HDMI monitor, DP monitor also stops working.

>when I put my laptop to sleep, both it and its DP-connected external screen immediately wake up again

I don't have this issue, but if I leave the PC suspended with the monitor not powered off using the button on the monitor, it wakes up every 3-5 minutes with the blank screen and goes to sleep shortly afterwards This may be related, may be not. The PC itself does not wake up (but it's s0ix, not s3).
Comment 4 TraceyC 2024-10-30 15:54:11 UTC
I'm having similar issues. They started with Plasma 6.1.5 and continue with 6.2.2. If this is completely unrelated, let me know and I'll open a separate report. 

Hardware setup:
Laptop connected via USB-C dock to 2 external monitors (DP & HDMI)
All 3 displays were working OK at system boot.
Sleep was invoked with a shortcut, laptop was disconnected from the dock.
Laptop was woken from sleep. I could hear system sounds, but the built-in screen received no display. 
After plugging the laptop into the dock, the external monitors had a display but not the built in screen. (Display Configuration showed the built-in screen enabled.)
I was not able to get to TTY, the laptop display remains black (no power).
The only way to get a display on the laptop screen again is to reboot no matter what else I do

I tried these workarounds but nothing changed:
- Disabling and re-enabling the laptop screen in Display Configuration
- Reseating the dock cable
- Reseating the HDMI cable from the dock (which has resolved similar issues in the past)
- Changing display priorities

Even with no external displays active, with only the laptop screen active, the laptop screen has no display. 

Also, after disabling the second external monitor, the first external monitor then had no display. The timer to accept the new config timed out but all displays remained blank. I was left with no active displays. I had to connect the second monitor (HDMI) with a different HDMI cable plugged into its other port. Then both external monitors had a display. I still was unable to get to TTY.

Operating System: Solus 4.6
KDE Plasma Version: 6.2.2
KDE Frameworks Version: 6.7.0
Qt Version: 6.7.3
Kernel Version: 6.11.5-307.current (64-bit)
Graphics Platform: Wayland
Processors: 16 × 11th Gen Intel® Core™ i7-11800H @ 2.30GHz
Memory: 62.5 GiB of RAM
Graphics Processor: Mesa Intel® UHD Graphics
Manufacturer: Dell Inc.
Product Name: XPS 17 9710
Comment 5 TraceyC 2024-10-30 17:17:40 UTC
I'm having similar issues. They started with Plasma 6.1.5 and continue with 6.2.2. If this is completely unrelated, let me know and I'll open a separate report. 

Hardware setup:
Laptop connected via USB-C dock to 2 external monitors (DP & HDMI)
All 3 displays were working OK at system boot.
Sleep was invoked with a shortcut, laptop was disconnected from the dock.
Laptop was woken from sleep. I could hear system sounds, but the built-in screen received no display. 
After plugging the laptop into the dock, the external monitors had a display but not the built in screen. (Display Configuration showed the built-in screen enabled.)
I was not able to get to TTY, the laptop display remains black (no power).
The only way to get a display on the laptop screen again is to reboot no matter what else I do

I tried these workarounds but nothing changed:
- Disabling and re-enabling the laptop screen in Display Configuration
- Reseating the dock cable
- Reseating the HDMI cable from the dock (which has resolved similar issues in the past)
- Changing display priorities

Even with no external displays active, with only the laptop screen active, the laptop screen has no display. 

Operating System: Solus 4.6
KDE Plasma Version: 6.2.2
KDE Frameworks Version: 6.7.0
Qt Version: 6.7.3
Kernel Version: 6.11.5-307.current (64-bit)
Graphics Platform: Wayland
Processors: 16 × 11th Gen Intel® Core™ i7-11800H @ 2.30GHz
Memory: 62.5 GiB of RAM
Graphics Processor: Mesa Intel® UHD Graphics
Manufacturer: Dell Inc.
Product Name: XPS 17 9710
Comment 6 TraceyC 2024-10-30 17:20:01 UTC
Does the monitor from the original report have adaptive sync? I have additional problems on one external monitor if that's enabled.

In Display Configuration on your desktop, in the settings for that monitor, do you see "Adaptive sync"?
If so, can you reproduce the original issue if that is set to disabled?
Comment 7 valdikss 2024-10-30 20:27:43 UTC
(In reply to TraceyC from comment #6)
> Does the monitor from the original report have adaptive sync? I have
> additional problems on one external monitor if that's enabled.

It does not.
Comment 8 valdikss 2025-01-12 21:07:31 UTC
I temporarily "fixed" it by allowing suspend on the lock screen with an external hotkey daemon (Plasma lockscreen does not react on power button).