aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaarten Lankhorst2016-12-08 14:45:27 +0100
committerDaniel Vetter2016-12-19 16:45:05 +0100
commita3fbb53f45fd208ec65e8a80a07f5d4ea11b0f69 (patch)
tree826de3effb2232650c5c021499f3b0e67bc0a16b
parentbdc571464c49740ce56c56e108d60f825336eb89 (diff)
drm/atomic: Wait for vblank whenever a plane is added to state.
There's 2 reasons for doing a vblank wait: - To fulfill uabi expectations, but the legacy ioctls are ill-defined enough that we really only need this when we do send out an event. - To make sure we don't tear down mappings before the scanout engine stops accessing it. The later is problematic with the current code since e.g. rotation might need a different mapping than normal orientation. And rotation is a plane property, and not on the fb. Hence we need to remove this optimization. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> [danvet: Completely new commit message.] Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1481204729-9058-5-git-send-email-maarten.lankhorst@linux.intel.com
-rw-r--r--drivers/gpu/drm/drm_atomic_helper.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/gpu/drm/drm_atomic_helper.c b/drivers/gpu/drm/drm_atomic_helper.c
index d1d678d63b84..f5b2a688eb0d 100644
--- a/drivers/gpu/drm/drm_atomic_helper.c
+++ b/drivers/gpu/drm/drm_atomic_helper.c
@@ -1129,11 +1129,7 @@ drm_atomic_helper_wait_for_vblanks(struct drm_device *dev,
for_each_crtc_in_state(old_state, crtc, old_crtc_state, i) {
struct drm_crtc_state *new_crtc_state = crtc->state;
- if (!new_crtc_state->active)
- continue;
-
- if (!drm_atomic_helper_framebuffer_changed(dev,
- old_state, crtc))
+ if (!new_crtc_state->active || !new_crtc_state->planes_changed)
continue;
ret = drm_crtc_vblank_get(crtc);