summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/intel_display.c
diff options
context:
space:
mode:
authorMaarten Lankhorst2016-11-08 13:55:34 +0100
committerMaarten Lankhorst2016-11-15 11:23:11 +0100
commit512b552798bfa3c4e665c34b9618d05c71b753ad (patch)
treeb2156569552882253a4cca17eb635638150e2d73 /drivers/gpu/drm/i915/intel_display.c
parentdrm/i915/gen9+: Program watermarks as a separate step during evasion, v3. (diff)
downloadkernel-qcow2-linux-512b552798bfa3c4e665c34b9618d05c71b753ad.tar.gz
kernel-qcow2-linux-512b552798bfa3c4e665c34b9618d05c71b753ad.tar.xz
kernel-qcow2-linux-512b552798bfa3c4e665c34b9618d05c71b753ad.zip
drm/i915/gen9+: Preserve old allocation from crtc_state.
This is the last bit required for making nonblocking modesets work correctly. The state in intel_crtc->hw_ddb is updated in the nonblocking part of a nonblocking commit. This means that even attempting a commit before a nonblocking modeset completes will fail, because intel_crtc->hw_ddb still has stale values. The stale values are 0 if the crtc is being enabled resulting in a failure during atomic check, but it may also result in double use of ddb allocations. Fix this by explicitly copying the ddb allocation from the old state. This has to be done explicitly, because a modeset that doesn't change active pipes, or a modeset converted to a fastset will will clear the current state. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1478609742-13603-4-git-send-email-maarten.lankhorst@linux.intel.com [mlankhorst: Reword commit message.] Reviewed-by: Matt Roper <matthew.d.roper@intel.com>
Diffstat (limited to 'drivers/gpu/drm/i915/intel_display.c')
-rw-r--r--drivers/gpu/drm/i915/intel_display.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index a5f75e19af80..62fe8a5c9365 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -14337,7 +14337,7 @@ static void skl_update_crtcs(struct drm_atomic_state *state,
* new ddb allocation to take effect.
*/
if (!skl_ddb_entry_equal(&cstate->wm.skl.ddb,
- &intel_crtc->hw_ddb) &&
+ &to_intel_crtc_state(old_crtc_state)->wm.skl.ddb) &&
!crtc->state->active_changed &&
intel_state->wm_results.dirty_pipes != updated)
vbl_wait = true;