Bug 514471

Summary: KWin Wayland fails to recover display after monitor shutoff
Product: [Plasma] kwin Reporter: George <geowtrev>
Component: wayland-genericAssignee: KWin default assignee <kwin-bugs-null>
Status: NEEDSINFO WAITINGFORINFO    
Severity: normal CC: xaver.hugl
Priority: NOR    
Version First Reported In: 6.5.4   
Target Milestone: ---   
Platform: EndeavourOS   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: drm info dump
monitor when unable to wake
bad drm
good drm
kscreen-doctor -o (bad recover)
kscreen-doctor -o (good state)

Description George 2026-01-11 22:00:40 UTC
SUMMARY
When using KWin on Wayland with an NVIDIA GPU and an OLED monitor connected via DisplayPort, waking my display from shutoff (not sleep or suspend) via USB input (mouse/keyboard) fails. My monitor reports excessive refresh rates (kHz range) and impossible resolutions (10K+). The same hardware configuration seems to work correctly in X11.

My only workaround now is to always "wake" my monitor by power button, regardless of system state. This seems to work consistently.

STEPS TO REPRODUCE
1. Configure screen energy saving to turn off display after 1 minute
2. Wait for monitor to enter DPMS standby
3. Attempt to wake via mouse movement or keyboard input

OBSERVED RESULT
Monitor fails to wake, cites impossible refresh rates and resolutions. Display only recovers if monitor is manually powered on before USB input.

EXPECTED RESULT
Display wakes normally

SOFTWARE/OS VERSIONS
Operating System: EndeavourOS
KDE Plasma Version: 6.5.4
KDE Frameworks Version: 6.21.0
Qt Version: 6.10.1
Kernel Version: 6.18.3-arch1-1 (64-bit)
NVIDIA Driver: 590.48.01
Graphics: Wayland

ADDITIONAL INFORMATION
Boot: systemd-boot + dracut
Processors: Intel i9-14900K (32 cores)
Memory: 64 GB DDR5
dGPU: NVIDIA GeForce RTX 4070 (display connected here via DisplayPort)
iGPU: Intel® Graphics (integrated UHD 770 present)
Monitor: HP Omen Transcend 32" OLED (3840x2160@119.88Hz)

FIXES ATTEMPTED
- Kernel parameters tested:
  - `NVreg_PreserveVideoMemoryAllocations=1` with nvidia-suspend/resume/hibernate services enabled
  - `nvidia_drm.modeset=1 nvidia_drm.fbdev=1`
  - `video=DP-2:1920x1080@60` and `video=DP-2:3840x2160@120`
  - `usbcore.autosuspend=-1` (originally thought my USB hub could be part of the problem, even disconnected my data cable at one point but to no avail)
  - `nvidia.NVreg_RegistryDwords="RMDisableHdmiTimePacking=0x1;RMEnableHDAudioAboveDP=0x0"` (made it worse, no wake at all)
- `KWIN_DRM_DEVICES` set to NVIDIA-only or NVIDIA-first
- Custom EDID configuration
- udev hotplug rule (no hotplug events fire)
- Disable iGPU entirely (made it worse, no wake at all)
Comment 1 Zamundaaa 2026-01-12 17:41:54 UTC
Can you include the exact error message from the monitor? In this case, a picture would be okay.

Also, please attach the output of drm_info from when the screen isn't working. You can get it from ssh.
Comment 2 George 2026-01-12 23:12:41 UTC
Created attachment 188457 [details]
drm info dump
Comment 3 George 2026-01-12 23:14:26 UTC
Created attachment 188458 [details]
monitor when unable to wake
Comment 4 Zamundaaa 2026-01-12 23:22:29 UTC
drm_info shows the output is set to 3840x2160@120, so the problem is on a lower level.
You can report it at https://forums.developer.nvidia.com/c/gpu-graphics/linux if you're using the proprietary kernel modules, or https://github.com/NVIDIA/open-gpu-kernel-modules/issues if you're using nvidia-open
Comment 5 George 2026-01-12 23:25:34 UTC
(In reply to Zamundaaa from comment #4)
> drm_info shows the output is set to 3840x2160@120, so the problem is on a
> lower level.
> You can report it at
> https://forums.developer.nvidia.com/c/gpu-graphics/linux if you're using the
> proprietary kernel modules, or
> https://github.com/NVIDIA/open-gpu-kernel-modules/issues if you're using
> nvidia-open

Apologies, I uploaded the wrong drm dump. Let me get the right one quick. 😅
Comment 6 George 2026-01-12 23:54:25 UTC
OK, I generated a "good" drm output and a "bad" one (generated right after a failed monitor wake). Hopefully this is useful. I can't really tell what I'm looking at.

Worth calling out too is I could access TTY without issue even with the monitor "off." That kinda caught me by surprise.

IDK if this is useful but I had Claude analyze both files and it said the main difference is this:

> Connector 135 (DP-2) shows status=1 (connected) with all 42 modes present in both states
> However, CRTC 0 mode differs:
> Working: 3840x2160@120Hz (clock: 1186810)
> Failed: 3840x2160@60Hz (clock: 533250)
Comment 7 George 2026-01-12 23:55:07 UTC
Created attachment 188460 [details]
bad drm
Comment 8 George 2026-01-12 23:55:20 UTC
Created attachment 188461 [details]
good drm
Comment 9 Zamundaaa 2026-01-13 20:26:11 UTC
If you manually select the 60Hz mode, does that fail in the same way?
Comment 10 Zamundaaa 2026-01-13 20:27:51 UTC
Also, please attach the output of kscreen-doctor -o once from when the screen is ok, and once from when it's (unintentionally!) in the broken state.
You can run it from ssh with
> WAYLAND_DISPLAY=wayland-0 kscreen-doctor -o
Comment 11 George 2026-01-14 00:30:39 UTC
Created attachment 188491 [details]
kscreen-doctor -o (bad recover)
Comment 12 George 2026-01-14 00:30:57 UTC
Created attachment 188492 [details]
kscreen-doctor -o (good state)
Comment 13 George 2026-01-14 00:31:59 UTC
(In reply to Zamundaaa from comment #10)
> Also, please attach the output of kscreen-doctor -o once from when the
> screen is ok, and once from when it's (unintentionally!) in the broken state.
> You can run it from ssh with
> > WAYLAND_DISPLAY=wayland-0 kscreen-doctor -o

Attached those outputs. I did this with 60hz configured.

I didn't run this with SSH. I accessed TTY (which again for some reason works even during failed resume) to run the commands. LMK if it would be better to run via SSH!
Comment 14 Zamundaaa 2026-01-14 00:54:16 UTC
Okay, so I take it manually setting the display to 60Hz does also cause the problem?
But I need the output from when it wrongly gets set to 60Hz, not from when you configure it to 60Hz. I want to find out on what level the wrong mode gets chosen.

About the output though, when you ran the command from the tty, it crashed. It looks like your distro might be patching Qt to default to xcb or something? Try with
> QT_QPA_PLATFORM=wayland WAYLAND_DISPLAY=wayland-0 kscreen-doctor -o
instead, that should hopefully make it work.
Getting it from the tty is fine for this one, only with drm_info using ssh is important, as the tty will change the drm state.
Comment 15 George 2026-01-14 01:07:50 UTC
(In reply to Zamundaaa from comment #14)
> Okay, so I take it manually setting the display to 60Hz does also cause the
> problem?

Yep

(In reply to Zamundaaa from comment #14)
> But I need the output from when it wrongly gets set to 60Hz, not from when
> you configure it to 60Hz. I want to find out on what level the wrong mode
> gets chosen.

Ah good point, I will try that next.

(In reply to Zamundaaa from comment #14)
> About the output though, when you ran the command from the tty, it crashed.
> It looks like your distro might be patching Qt to default to xcb or
> something? Try with
> > QT_QPA_PLATFORM=wayland WAYLAND_DISPLAY=wayland-0 kscreen-doctor -o
> instead, that should hopefully make it work.
> Getting it from the tty is fine for this one, only with drm_info using ssh
> is important, as the tty will change the drm state.

OK, I will try both of these, if I'm understanding right:
- Using SSH: drm_info
- From TTY: QT_QPA_PLATFORM=wayland WAYLAND_DISPLAY=wayland-0 kscreen-doctor -o

Thank you so much for helping me through this, i know it's a slog :)
Comment 16 George 2026-01-14 01:09:31 UTC
Oops, misspoke before in response to:

> But I need the output from when it wrongly gets set to 60Hz, not from when
> you configure it to 60Hz. I want to find out on what level the wrong mode
> gets chosen.

I should say: This is good to know. :)
Comment 17 Zamundaaa 2026-01-14 16:59:10 UTC
(In reply to George from comment #15)
> OK, I will try both of these, if I'm understanding right:
> - Using SSH: drm_info
> - From TTY: QT_QPA_PLATFORM=wayland WAYLAND_DISPLAY=wayland-0 kscreen-doctor -o
yeah.