620.70.06: NULL deref in ConnectorImpl::ensureMstNodesPoweredUp (via ConnectorImpl2x::notifyAttachBegin) on first modeset after s2idle resume — kwin_wayland killed, black screen
NVIDIA Driver Version
620.70.06 (open kernel modules)
Operating System and Version
Arch Linux (CachyOS kernel)
Kernel Release
7.3.4-1-cachyos
Hardware
- GPU: GeForce RTX 5060 Ti (GB206, 10de:2d04), VBIOS 98.06.4E.40.38
- iGPU also present: AMD Renoir (amdgpu); display connected only to the NVIDIA card
- Board: B450M (BIOS 5.17, 12/13/2024)
- Display: LG UltraGear over DisplayPort, single monitor, direct connection (no hub/dock/MST)
Software
- KDE Plasma 6.8.3, kwin_wayland 6.8.3 (Wayland session)
nvidia_drm.modeset=1,nvidia_drm.fbdev=1- nvidia-suspend/resume/hibernate systemd services: disabled
PreserveVideoMemoryAllocations: 2,DynamicPowerManagement: 3
Describe the bug
The system suspended (s2idle) after an idle period. On wake, the kernel resumed normally (disks, network and audio came back), but ~2 seconds after PM: suspend exit, the first atomic commit from kwin_wayland oopsed inside nvidia_modeset. kwin_wayland was killed with IRQs disabled, the display stayed black, and only a hard reset got the machine back. The rest of the system stayed alive; it kept logging network traffic for several minutes.
Earlier in the same boot (about 3 h before the suspend), this warning appeared once:
WARNING: nvidia-drm/nvidia-drm-crtc.h:371 at __nv_drm_handle_flip_event (nv_flip == NULL).
Analysis
The faulting instruction is at ensureMstNodesPoweredUp+0x53:
48 8b 03 mov rax, [rbx] ; rbx = Device* from target->enumDevices()
48 8b 40 18 mov rax, [rax+0x18] ; <-- faults: vtable pointer is NULL (CR2 = 0x18)
48 3d ... cmp rax, <fn> ; devirtualization check for dev->isVideoSink()
So the Device* returned by target->enumDevices() points to an object whose vtable pointer is 0. That looks like a stale or freed DeviceImpl still linked in the Group after resume. The monitor was probably re-detected or removed during resume while the group membership wasn't updated. The connector-state guard at the top of the function (connectorActive / isDiscoveryDetectComplete) did not catch it.
Note that notifyAttachBegin iterates the same list right after ensureMstNodesPoweredUp() returns. So adding a linkUseMultistream() guard (this is an SST link) would only move the crash, not fix the lifetime problem.
I checked the 620.73.04 tag: ensureMstNodesPoweredUp and the group/device lifetime code in src/common/displayport are unchanged, so this is likely still present. This may be related to #1454 (NULL deref on modeset after DP re-plug).
To Reproduce
- Wayland session (KWin) on RTX 50-series, single DP monitor.
- Let the system auto-suspend (s2idle) for ~1 h.
- Wake it. The crash happens on the first modeset after resume.
This has happened once so far, so it is not reliably reproducible.
Kernel log (oops)
PM: suspend exit
BUG: kernel NULL pointer dereference, address: 0000000000000018
#PF: supervisor read access in kernel mode
#PF: error_code(0x0000) - not-present page
Oops: Oops: 0000 [#1] SMP NOPTI
CPU: 2 UID: 1000 PID: 906 Comm: kwin_wayland Tainted: G W O 7.3.4-1-cachyos #1 PREEMPT(full)
RIP: 0010:_ZN11DisplayPort13ConnectorImpl23ensureMstNodesPoweredUpEPNS_5GroupE.part.0+0x53/0x2e0 [nvidia_modeset]
Code: ... 48 89 c3 0f 1f 00 48 8b 03 <48> 8b 40 18 48 3d d0 61 b6 c1 0f 85 1d 02 00 00 ...
RAX: 0000000000000000 RBX: ffff8b6b211fc008
Call Trace:
_ZN11DisplayPort15ConnectorImpl2x17notifyAttachBeginEPNS_5GroupERKNS_15DpModesetParamsE+0x263/0xe00 [nvidia_modeset]
_ZN11DisplayPort13ConnectorImpl12dpPreModesetERKNS_18DpPreModesetParamsE+0x87/0x150 [nvidia_modeset]
nvDPPreSetMode+0x144/0x250 [nvidia_modeset]
KickoffModesetUpdateState+0xe8/0x220 [nvidia_modeset]
nvSetDispModeEvo+0x3e98/0x4c00 [nvidia_modeset]
nvKmsIoctl+0xdc/0x1b0 [nvidia_modeset]
nvkms_ioctl_from_kapi_try_pmlock+0x4b/0x80 [nvidia_modeset]
ApplyModeSetConfig+0xd98/0xfb0 [nvidia_modeset]
nv_drm_atomic_commit+0x584/0xab0 [nvidia_drm]
drm_atomic_commit+0xc3/0xf0
drm_mode_atomic_ioctl.cold+0x348/0x5d8
drm_ioctl+0x305/0x4d0
do_syscall_64+0x8f/0x380
entry_SYSCALL_64_after_hwframe+0x76/0x7e
note: kwin_wayland[906] exited with irqs disabled
Bug Incidence
Once
nvidia-bug-report.log.gz
(to attach: generated after the next occurrence)
Same oops on 620.73.04, confirming it is still present. Different trigger here: DPMS wake (no suspend), with a monitor that drops off DP while in standby.
System
- RTX 5070 Ti (GB203, 10de:2c05), VBIOS 98.03.58.40.B6, Gigabyte B550 GAMING X V2
- open kernel modules 620.73.04, kernel 7.3.5-2-cachyos, CachyOS
- KDE Plasma / KWin 6.8.3, Wayland;
nvidia_drm.modeset=1 fbdev=1,PreserveVideoMemoryAllocations: 2,DynamicPowerManagement: 3 - Two monitors, both direct DP (SST, no hub/MST):
- DP-2: Samsung Odyssey G61SD, 2560x1440 @ 240 Hz, HDR, VRR
- DP-3: MSI MAG274QRF, 2560x1440 @ 165 Hz. It disconnects from DP in standby; with its input auto-scan enabled it also raises a hotplug uevent every ~5 s while the displays are off.
Sequence (screens locked and DPMS off at 23:18, woken at 23:23:11)
23:23:11 DP-3 reconnects (monitor's USB hub re-enumerates at the same moment)
23:23:15 [nvidia-drm] Flip event timeout on head 0
23:23:18 [nvidia-drm] Flip event timeout on head 1
23:23:18 nv_flip == NULL / WARNING: nvidia-drm/nvidia-drm-crtc.h:371 at __nv_drm_handle_flip_event (x2)
23:23:23 Oops in kwin_wayland's atomic commit
Both displays stayed black and a hard reset was needed. The same flip timeout + WARN (as in #1361) shows up on most DPMS wakes on this machine without the oops; wake then takes ~40 s.
Oops
The fault differs from the one in the original report: here it is an indirect call through a NULL pointer (RIP: 0x0, instruction fetch) returning into ensureMstNodesPoweredUp+0x285, not the vtable load at +0x53. That fits the same stale or freed Device object theory, with the vtable still present but a slot cleared.
BUG: kernel NULL pointer dereference, address: 0000000000000000
#PF: supervisor instruction fetch in kernel mode
#PF: error_code(0x0010) - not-present page
Oops: Oops: 0010 [#1] SMP NOPTI
CPU: 11 UID: 1000 PID: 1591 Comm: kwin_wayland Tainted: G W O 7.3.5-2-cachyos #1 PREEMPT(full)
Hardware name: Gigabyte Technology Co., Ltd. B550 GAMING X V2/B550 GAMING X V2, BIOS FG 10/29/2025
RIP: 0010:0x0
Code: Unable to access opcode bytes at 0xffffffffffffffd6.
RSP: 0018:ffffcff80389eea8 EFLAGS: 00010207
RAX: 0000000000000000 RBX: ffff8eaba1dbf808 RCX: 0000000000000002
RDX: ffff8ea83a85a048 RSI: ffff8ea80af06808 RDI: ffff8eaba1dbf808
Call Trace:
_ZN11DisplayPort13ConnectorImpl23ensureMstNodesPoweredUpEPNS_5GroupE.part.0+0x285/0x2e0 [nvidia_modeset]
_ZN11DisplayPort15ConnectorImpl2x17notifyAttachBeginEPNS_5GroupERKNS_15DpModesetParamsE+0x263/0xe00 [nvidia_modeset]
_ZN11DisplayPort13ConnectorImpl12dpPreModesetERKNS_18DpPreModesetParamsE+0x87/0x150 [nvidia_modeset]
nvDPPreSetMode+0x144/0x250 [nvidia_modeset]
KickoffModesetUpdateState+0xe8/0x220 [nvidia_modeset]
nvSetDispModeEvo+0x3e98/0x4c00 [nvidia_modeset]
nvKmsIoctl+0xdc/0x1b0 [nvidia_modeset]
nvkms_ioctl_from_kapi_try_pmlock+0x4b/0x80 [nvidia_modeset]
ApplyModeSetConfig+0xd98/0xfb0 [nvidia_modeset]
nv_drm_atomic_commit+0x584/0xab0 [nvidia_drm]
drm_atomic_commit+0xc3/0xf0
drm_mode_atomic_ioctl.cold+0x348/0x5d8
drm_ioctl+0x305/0x4d0
Happened once in about six DPMS wakes over one evening. The slow wakes with flip timeouts also occurred on 620.70.06.
This comment was written with Claude (an AI assistant). The logs, timings and tests are from my machine.
Same oops here on a different GPU and monitor. It hits intermittently on resume from suspend.
System
- GPU: RTX 5070 Ti (VBIOS 98.03.58.00.94)
- Driver: 620.70.06 open kernel modules
- Kernel: 7.3.5-1-cachyos
- Board: ASUS TUF GAMING B650E-E WIFI (BIOS 3602)
- Desktop: KDE Plasma 6.8.3, kwin_wayland
- Monitor: AOC CU34G4 (3440x1440 @ 180 Hz), one monitor on a direct DP cable, no MST hub or dock. Seen on both DP-3 and DP-1.
- Suspend config:
NVreg_UseKernelSuspendNotifiers=1,NVreg_PreserveVideoMemoryAllocations=2, nvidia-suspend/resume/hibernate services disabled
Occurrences
- 2026-11-19 and 2026-11-22: resume from S3 (deep), then kwin_wayland modesets and nvidia_modeset oopses in
ensureMstNodesPoweredUp. The display stays black. The kernel stays up (power key presses are still logged), so a hard power-off is needed. - Not every resume fails. Several resumes in between completed normally.
- Separately, non-fatal
Flip event timeout on head 0/nv_flip == NULLWARNs show up after some resumes, on a normal boot, and once when the monitor dropped off DP while the lock screen was up. The display recovered each time.
It's notable that this code path runs at all, since this is a single SST monitor with no MST in the chain. That fits the earlier comment about the missing linkUseMultistream() guard.
Oops (2026-11-22)
PM: suspend exit
BUG: kernel NULL pointer dereference, address: 0000000000000018
#PF: supervisor read access in kernel mode
#PF: error_code(0x0000) - not-present page
Oops: Oops: 0000 [#1] SMP NOPTI
CPU: 9 UID: 1000 PID: 1378 Comm: kwin_wayland Tainted: G O 7.3.5-1-cachyos #1 PREEMPT(full)
Hardware name: ASUS System Product Name/TUF GAMING B650E-E WIFI, BIOS 3602 11/13/2025
RIP: 0010:_ZN11DisplayPort13ConnectorImpl23ensureMstNodesPoweredUpEPNS_5GroupE.part.0+0x53/0x2e0 [nvidia_modeset]
Call Trace:
<TASK>
_ZN11DisplayPort15ConnectorImpl2x17notifyAttachBeginEPNS_5GroupERKNS_15DpModesetParamsE+0x263/0xe00 [nvidia_modeset]
_ZN11DisplayPort13ConnectorImpl12dpPreModesetERKNS_18DpPreModesetParamsE+0x87/0x150 [nvidia_modeset]
nvDPPreSetMode+0x144/0x250 [nvidia_modeset]
KickoffModesetUpdateState+0xe8/0x220 [nvidia_modeset]
nvSetDispModeEvo+0x3e98/0x4c00 [nvidia_modeset]
nvKmsIoctl+0xdc/0x1b0 [nvidia_modeset]
nvkms_ioctl_from_kapi_try_pmlock+0x4b/0x80 [nvidia_modeset]
ApplyModeSetConfig+0xd98/0xfb0 [nvidia_modeset]
nv_drm_atomic_commit+0x584/0xab0 [nvidia_drm]
drm_atomic_commit+0xc3/0xf0
drm_mode_atomic_ioctl.cold+0x34c/0x5d2
drm_ioctl+0x2fb/0x4d0
do_syscall_64+0x93/0x3a0
Same oops on 620.73.04. Different trigger path here: S3 deep resume left the session with no outputs, then the NULL deref hit ~19 minutes later when idle auto-suspend tried to sleep again.
System
- RTX 5060 (GB206), VBIOS 98.06.21.40.7A, ASUS ROG MAXIMUS X HERO (BIOS 2701)
- open kernel modules 620.73.04, kernel 6.18.65, NixOS
- KDE Plasma / KWin Wayland;
nvidia_drm.modeset=1,PreserveVideoMemoryAllocationson,UseKernelSuspendNotifiers=1 - Single monitor, direct DP (SST, no hub/MST): LG UltraGear on
DP-3 - Suspend config:
SuspendState=mem,MemorySleepMode=deep(ACPI S3)
Sequence
Nov 28 19:11:47 suspend entry (deep) overnight
Nov 29 16:56:31 Waking up from system sleep state S3
Nov 29 16:56:33 System returned from sleep operation 'suspend'
Nov 29 16:56:34 kwin_wayland: drmGetDeviceFromDevId failed! (repeated)
Nov 29 16:56:34 plasmashell/kwin: There are no outputs - creating placeholder screen
Nov 29 16:59:34 still "There are no outputs" (~3 min later)
Nov 29 17:15:18 idle auto-suspend starts another deep suspend
Nov 29 17:15:19 BUG: kernel NULL pointer dereference in ensureMstNodesPoweredUp
Nov 29 17:15:19 note: systemd-logind[1268] exited with irqs disabled
Nov 29 17:18:11 systemd-logind.service: Watchdog timeout (limit 3min)!
Only a hard power-off recovered the machine.
Unlike the OP, the first wake did not oops immediately — it left a broken DP/output state — and the crash happened on the next modeset path during a subsequent suspend (fbcon_blank → drm_fb_helper → nv_drm_atomic_commit → ConnectorImpl2x::notifyAttachBegin).
Oops
BUG: kernel NULL pointer dereference, address: 0000000000000000
#PF: supervisor instruction fetch in kernel mode
#PF: error_code(0x0010) - not-present page
PGD 0 P4D 0
Oops: Oops: 0010 [#1] SMP NOPTI
CPU: 8 UID: 0 PID: 1268 Comm: systemd-logind Tainted: G OE 6.18.65 #1-NixOS PREEMPT(lazy)
Tainted: [O]=OOT_MODULE, [E]=UNSIGNED_MODULE
Hardware name: ASUS System Product Name/ROG MAXIMUS X HERO (WI-FI AC), BIOS 2701 07/13/2021
RIP: 0010:0x0
Code: Unable to access opcode bytes at 0xffffffffffffffd6.
RSP: 0018:ffffce3d01136d68 EFLAGS: 00010203
RAX: 0000000000000000 RBX: ffff8b7f5c5e3008 RCX: 0000000000000002
RDX: 0000000000000000 RSI: 0000000000000000 RDI: ffff8b7f5c5e3008
RBP: ffffce3d01136d90 R08: 000000000000001e R09: 0000000000000aa0
R10: 0000000000000000 R11: 0000000000000000 R12: ffffce3d09b27008
R13: ffffce3d01136eac R14: ffff8b7f6203ea08 R15: ffff8b7f6203ea08
FS: 0000760d601a58c0(0000) GS:ffff8b8ad2035000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffffffffffffd6 CR3: 00000001414da002 CR4: 00000000003726f0
Call Trace:
<TASK>
_ZN11DisplayPort13ConnectorImpl23ensureMstNodesPoweredUpEPNS_5GroupE.part.0+0x298/0x2f0 [nvidia_modeset]
? dpPrintf+0x54/0xf0 [nvidia_modeset]
_ZN11DisplayPort15ConnectorImpl2x17notifyAttachBeginEPNS_5GroupERKNS_15DpModesetParamsE+0x27b/0xeb0 [nvidia_modeset]
? _ZN11DisplayPort9GroupImpl6insertEPNS_6DeviceE+0x19a/0x1c0 [nvidia_modeset]
_ZN11DisplayPort13ConnectorImpl12dpPreModesetERKNS_18DpPreModesetParamsE+0x8d/0x180 [nvidia_modeset]
nvDPPreSetMode+0x14b/0x270 [nvidia_modeset]
KickoffModesetUpdateState+0x88/0x2e0 [nvidia_modeset]
KickoffProposedModeSetHwState+0x108d/0x10b0 [nvidia_modeset]
nvSetDispModeEvo+0x3307/0x4580 [nvidia_modeset]
nvKmsIoctl+0x123/0x300 [nvidia_modeset]
nvkms_ioctl_from_kapi_try_pmlock+0x60/0xa0 [nvidia_modeset]
ApplyModeSetConfig+0x637/0xea0 [nvidia_modeset]
nv_drm_atomic_apply_modeset_config+0x5af/0x900 [nvidia_drm]
nv_drm_atomic_commit+0xaf/0x3d0 [nvidia_drm]
drm_atomic_commit+0xb1/0xe0
drm_client_modeset_commit_atomic+0x25f/0x2d0
drm_client_modeset_commit_locked+0x5a/0x170
__drm_fb_helper_restore_fbdev_mode_unlocked.part.0+0x30/0xa0
drm_fb_helper_set_par+0x55/0x70
drm_fb_helper_hotplug_event+0xd9/0x100
__drm_fb_helper_restore_fbdev_mode_unlocked.part.0+0x8b/0xa0
drm_fb_helper_set_par+0x55/0x70
fb_set_var+0x2cf/0x5c0
fbcon_blank+0x164/0x320
do_unblank_screen+0xcb/0x1c0
complete_change_console+0x54/0x120
vt_ioctl+0xead/0x14c0
tty_ioctl+0xe4/0xae0
__x64_sys_ioctl+0xb9/0x100
do_syscall_64+0xd6/0x7f0
entry_SYSCALL_64_after_hwframe+0x77/0x7f
</TASK>
CR2: 0000000000000000
---[ end trace 0000000000000000 ]---
note: systemd-logind[1268] exited with irqs disabled