mirror of
https://github.com/hyprwm/wlroots-hyprland.git
synced 2024-11-22 12:55:58 +01:00
backend/drm: fix FPE when disabling output
Fixes: 65836ce357
("backend/drm: log modesetting commits")
Closes: https://gitlab.freedesktop.org/wlroots/wlroots/-/issues/3534
This commit is contained in:
parent
5b34fe5513
commit
a40ba16a64
1 changed files with 7 additions and 3 deletions
|
@ -582,9 +582,13 @@ bool drm_connector_commit_state(struct wlr_drm_connector *conn,
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pending.modeset) {
|
if (pending.modeset) {
|
||||||
wlr_drm_conn_log(conn, WLR_INFO, "Modesetting with %dx%d @ %.3f Hz",
|
if (pending.active) {
|
||||||
pending.mode.hdisplay, pending.mode.vdisplay,
|
wlr_drm_conn_log(conn, WLR_INFO, "Modesetting with %dx%d @ %.3f Hz",
|
||||||
(float)calculate_refresh_rate(&pending.mode) / 1000);
|
pending.mode.hdisplay, pending.mode.vdisplay,
|
||||||
|
(float)calculate_refresh_rate(&pending.mode) / 1000);
|
||||||
|
} else {
|
||||||
|
wlr_drm_conn_log(conn, WLR_INFO, "Turning off");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!drm_crtc_commit(conn, &pending, flags, false)) {
|
if (!drm_crtc_commit(conn, &pending, flags, false)) {
|
||||||
|
|
Loading…
Reference in a new issue