Control: tags -1 + moreinfo On Thu, 31 Aug 2023 at 13:45:04 +0200, Marc Glisse wrote: > It looks like my stack trace is useless because I forgot to set > MUTTER_SYNC=1 :-( > > It seems likely that this is the same bug as > https://gitlab.gnome.org/GNOME/mutter/-/issues/2857 (sadly not fixed yet).
Would you be able to reproduce this with MUTTER_SYNC=1 in the environment (setting it in ~/.config/environment.d/mutter-sync.conf should apparently work) to confirm that it's the same crash as mutter#2857 upstream? https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/6778#note_1782883 seems like the characteristic backtrace: a BadMatch in response to DPMSForceLevel(). You say this happens when playing a video with mpv: perhaps this could be because mpv disables power saving / screen blanking while it's playing the video? If you install the x11-xserver-utils package and run "xset -dpms", does that trigger the same crash? There is a merge request upstream which *might* fix this. If you are able to rebuild the mutter source package with patches applied, please try applying the attached file "bug1050512-without-xsync.patch" and see whether you can reproduce the crash. If that works, please report back. If not, please revert that change, apply "bug1050512-with-xsync.patch", rebuild and try again. If you're not able to rebuild the mutter source package, I'll try to prepare packages that you can try, but there's a heatwave here at the moment, so I'm trying not to heat my house more by compiling lots of packages right now! Thanks, smcv
From: =?UTF-8?q?Jonas=20=C3=85dahl?= <jad...@gmail.com> Date: Mon, 7 Aug 2023 22:42:18 +0200 Subject: monitor-manager/xrandr: Trap DPMS changes Apparently DPMSForceLevel() can fail to force a valid level sometimes. Bug: https://gitlab.gnome.org/GNOME/mutter/-/issues/2857 Bug: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/6883 Forwarded: https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3160 Bug-Debian: https://bugs.debian.org/1050512 --- src/backends/x11/meta-monitor-manager-xrandr.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/backends/x11/meta-monitor-manager-xrandr.c b/src/backends/x11/meta-monitor-manager-xrandr.c index f288c7af239..1a23709c8a2 100644 --- a/src/backends/x11/meta-monitor-manager-xrandr.c +++ b/src/backends/x11/meta-monitor-manager-xrandr.c @@ -180,8 +180,10 @@ meta_monitor_manager_xrandr_set_power_save_mode (MetaMonitorManager *manager, return; } + meta_clutter_x11_trap_x_errors (); DPMSForceLevel (manager_xrandr->xdisplay, state); DPMSSetTimeouts (manager_xrandr->xdisplay, 0, 0, 0); + meta_clutter_x11_untrap_x_errors (); } static xcb_randr_rotation_t -- GitLab
>From 7d911855b480ce19941f27df3d2d8c270ceb6ba5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20=C3=85dahl?= <jad...@gmail.com> Date: Mon, 7 Aug 2023 22:42:18 +0200 Subject: [PATCH] monitor-manager/xrandr: Trap DPMS changes Apparently DPMSForceLevel() can fail to force a valid level sometimes. Bug: https://gitlab.gnome.org/GNOME/mutter/-/issues/2857 Bug: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/6883 Origin: https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3160 [smcv: call XSync() before untrap, as suggested by Sebastian Keller] Bug-Debian: https://bugs.debian.org/1050512 --- src/backends/x11/meta-monitor-manager-xrandr.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/backends/x11/meta-monitor-manager-xrandr.c b/src/backends/x11/meta-monitor-manager-xrandr.c index beb9fb80d2..0785dad36f 100644 --- a/src/backends/x11/meta-monitor-manager-xrandr.c +++ b/src/backends/x11/meta-monitor-manager-xrandr.c @@ -180,8 +180,11 @@ meta_monitor_manager_xrandr_set_power_save_mode (MetaMonitorManager *manager, return; } + meta_clutter_x11_trap_x_errors (); DPMSForceLevel (manager_xrandr->xdisplay, state); DPMSSetTimeouts (manager_xrandr->xdisplay, 0, 0, 0); + XSync (manager_xrandr->xdisplay, False); + meta_clutter_x11_untrap_x_errors (); } static xcb_randr_rotation_t -- 2.40.1