kms/crtc: Complain and bail if DRM mode info isn't valid
Otherwise meta_calculate_drm_mode_refresh_rate returns 0.0, which
results in non-sense refresh_interval_us.
https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3982 fixed that
happening before. This is intended to catch if it ever happens again.
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3980>
(cherry picked from commit 3cf3d5d1c6
)
This commit is contained in:
parent
7c5bb5b8b2
commit
d291a07261
1 changed files with 2 additions and 0 deletions
|
@ -700,6 +700,8 @@ meta_kms_crtc_update_shortterm_max_dispatch_duration (MetaKmsCrtc *crtc,
|
||||||
{
|
{
|
||||||
int64_t refresh_interval_us;
|
int64_t refresh_interval_us;
|
||||||
|
|
||||||
|
g_return_if_fail (crtc->current_state.is_drm_mode_valid);
|
||||||
|
|
||||||
/* meta_kms_crtc_determine_deadline doesn't use deadline evasion with VRR */
|
/* meta_kms_crtc_determine_deadline doesn't use deadline evasion with VRR */
|
||||||
if (crtc->current_state.vrr.enabled)
|
if (crtc->current_state.vrr.enabled)
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in a new issue