You are not logged in.

#1 2025-03-23 12:33:31

Loffah
Member
Registered: 2025-03-23
Posts: 3

[Wayland/NVIDIA] System Freeze When Playing Video in Browser

Summary

On a high-end system with NVIDIA GPU and KDE Wayland, watching video (YouTube, etc.) in any browser (Brave, Firefox) eventually causes a full system freeze lasting 5–10 seconds. This is reproducible, survives safe mode, and happens across different browsers. It does not affect MPV, which plays all media fine.
After a reboot, the problem is gone temporarily (sometimes for ~24 hours), then reappears.
I've done extensive debugging and believe this may be related to Wayland + NVIDIA + compositor buffer sync, but I’m looking for help confirming the exact layer and a proper fix or mitigation.

System Details
OS: Arch Linux x86_64
Kernel: 6.7.9-arch1-1
Desktop: KDE Plasma 6 (Wayland)
GPU: NVIDIA 4080 Super
Drivers: nvidia 570.129.04-2
Compositor: kwin_wayland
Nvidia packages
local/egl-gbm 1.1.2-1
    The GBM EGL external platform library
local/egl-wayland 4:1.1.18-1
    EGLStream-based Wayland external platform
local/egl-x11 1.0.0-1
    NVIDIA XLib and XCB EGL Platform Library
local/lib32-nvidia-utils 570.124.04-1
    NVIDIA drivers utilities (32-bit)
local/libvdpau 1.5-3
    Nvidia VDPAU library
local/libxnvctrl 570.124.04-1
    NVIDIA NV-CONTROL X extension
local/nvidia-open 570.124.04-4
    NVIDIA open kernel modules
local/nvidia-settings 570.124.04-1
    Tool for configuring the NVIDIA graphics driver
local/nvidia-utils 570.124.04-1
    NVIDIA drivers utilities
What I've Confirmed
  • Browsers freeze, even in safe mode (--safe-mode in Firefox, --disable-gpu in Brave)

  • MPV never freezes, even with 4K video (hardware decoding enabled)

  • Hardware acceleration is ON

  • Rebooting resolves the issue for a day or so

  • kwin_wayland restart by performing these actions does not temporarily fix the issue(like a reboot would):

    kwin_wayland --replace &
    killall -9 kwin_wayland && kwin_wayland &
  • System doesn’t crash — input freezes, screen freezes, then it resumes

  • Strace captured GPU process in a browser during a freeze

Diagnostic Outputs

strace on Brave GPU process (Flatpak Brave):

futex(..., FUTEX_WAIT_BITSET_PRIVATE|FUTEX_CLOCK_REALTIME, ...) = -1 ETIMEDOUT
ppoll([...]) = 0 (Timeout)
epoll_wait(...) = 0

GPU process stuck waiting on futex + ppoll — appears to be blocked on compositor or DRM sync.

Was gonna upload full strace logs here but I'm concerned about sensitive information being in there somehow (lol)

dmesg Relevant Lines:

[    6.093978] nvidia: loading out-of-tree module taints kernel.
[    6.234231] NVRM: loading NVIDIA UNIX Open Kernel Module for x86_64  570.124.04
[57765.783923] ata7.00: supports DRM functions and may not be fully accessible

journalctl -b
https://pastebin.com/D25P3Gyz
No clear crash, but frequent Flatpak/DBus poll events, then silent gaps during freeze.

nvidia-smi Output During Issue
Seems normal to me:

| kwin_wayland | ~350MiB |
| plasmashell  | ~170MiB |
| brave        | ~300MiB (various subprocesses) |
Things I've Tried
  • Reinstalling browser/video-related packages 
    No effect

  • MOZ_DISABLE_RDD_SANDBOX, MOZ_WEBRENDER=0 
    No change

  • Firefox/Brave safe mode 
    Still freezes

  • kwin_wayland --replace 
    Does not resolve issue

  • reinstalled nvidia drivers 
    Does not resolve issue

  • Switched to MPV (no freeze) 
    Works perfectly

  • strace GPU process during freeze 
    Captured waiting state

  • Reboot 
    Temporarily resolves problem

Hypothesis

This is possibly from what I've gathered so far:

  • A deadlock in the NVIDIA GBM/DRM sync path under Wayland

  • Buffer release/fence stall between the browser GPU process and compositor

  • Or a compositor-level (KWin) bug not correctly flushing/stalling frame presentation

TODO list:
  • Test Hyprland (hyprland-nvidia-git) — to rule out KWin

  • Install linux-lts to test kernel behavior

  • Native (non-Flatpak) Brave or Chromium

  • X11 session

I would greatly appreciate some help!

I feel like I'm running out of things to try and would love some input on steps I should take forward to resolve this issue.

Offline

#2 2025-03-24 17:26:14

archnoob(maybe)
Member
Registered: 2025-03-24
Posts: 1

Re: [Wayland/NVIDIA] System Freeze When Playing Video in Browser

Well I go with native firefox and didn't got any problem since I started using Arch. (It has been 2 months) And your kernel seems a bit old.

Last edited by archnoob(maybe) (2025-03-24 17:27:08)

Offline

#3 2025-03-24 19:24:02

afader
Member
Registered: 2013-09-12
Posts: 180

Re: [Wayland/NVIDIA] System Freeze When Playing Video in Browser

Try libva-nvidia-driver-git

Offline

#4 2025-03-24 21:03:42

seth
Member
Registered: 2012-09-03
Posts: 62,017

Re: [Wayland/NVIDIA] System Freeze When Playing Video in Browser

It does not affect MPV, which plays all media fine.

https://bbs.archlinux.org/viewtopic.php?id=304400
This seems to hinge on kwin_wayland - for whatever reason.

Offline

#5 Yesterday 12:25:13

Loffah
Member
Registered: 2025-03-23
Posts: 3

Re: [Wayland/NVIDIA] System Freeze When Playing Video in Browser

I got tired of not being able to resolve the issue so I changed from wayland plasma to hyprland and haven't had any issues in the past 2 days. Not sure what to do with this thread as the problem technically wasn't resolved.

Offline

#6 Yesterday 15:55:12

seth
Member
Registered: 2012-09-03
Posts: 62,017

Re: [Wayland/NVIDIA] System Freeze When Playing Video in Browser

Apparently it's powerdevil related, https://bbs.archlinux.org/viewtopic.php … 8#p2233448

Offline

#7 Yesterday 19:15:27

Loffah
Member
Registered: 2025-03-23
Posts: 3

Re: [Wayland/NVIDIA] System Freeze When Playing Video in Browser

seth wrote:

Apparently it's powerdevil related, https://bbs.archlinux.org/viewtopic.php … 8#p2233448

Ah neat! Only observation from that thread  that is different from mine is that I could consistently trigger the freeze every time I opened a video in my browser after having the computer on for 24 hours.
I never checked if VLC worked unfortunately but I sorta just assumed that it did.

Offline

Board footer

Powered by FluxBB