[PATCH] drm/i915: Always clear INHERIT flag from crtc_state->mode
Sean Paul
sean at poorly.run
Mon Oct 15 20:32:05 UTC 2018
From: Sean Paul <seanpaul at chromium.org>
After fastboot/smoothboot completes, we need to fully compute the
state, since a bunch of it is zeroed out. Everything works great if the
first commit from userspace is a modeset, the new mode has no private
flags and we force a modeset (which does the aforementioned
computations).
Unfortunately, for non-modeset commits the private_flags in
new_state->mode.private_flags still contains the INHERIT flag. As such,
the state is not computed and we attempt to divide-by-zero in
skl_ddb_get_pipe_allocation_limits().
Cc: stable at vger.kernel.org
Cc: Daniel Vetter <daniel.vetter at ffwll.ch>
Cc: Maarten Lankhorst <maarten.lankhorst at linux.intel.com>
Cc: Ville Syrjälä <ville.syrjala at linux.intel.com>
Signed-off-by: Sean Paul <seanpaul at chromium.org>
---
drivers/gpu/drm/i915/intel_atomic.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/gpu/drm/i915/intel_atomic.c b/drivers/gpu/drm/i915/intel_atomic.c
index b04952bacf77..1c9a9fee4fb9 100644
--- a/drivers/gpu/drm/i915/intel_atomic.c
+++ b/drivers/gpu/drm/i915/intel_atomic.c
@@ -184,6 +184,7 @@ intel_crtc_duplicate_state(struct drm_crtc *crtc)
crtc_state->fifo_changed = false;
crtc_state->wm.need_postvbl_update = false;
crtc_state->fb_bits = 0;
+ crtc_state->base.mode.private_flags &= ~I915_MODE_FLAG_INHERITED;
return &crtc_state->base;
}
--
Sean Paul, Software Engineer, Google / Chromium OS
More information about the Intel-gfx-trybot
mailing list