Commit 62852622 authored by Maarten Lankhorst's avatar Maarten Lankhorst Committed by Daniel Vetter

drm/i915: Only run commit when crtc is active, v2.

The crtc->active guards are no longer needed now that all state
updates are outside the commit.

Changes since v1:
- Only check crtc->state->active before calling commit_planes_on_crtc.
Signed-off-by: default avatarMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: default avatarVille Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
parent f029ee82
...@@ -13153,6 +13153,7 @@ static int intel_atomic_commit(struct drm_device *dev, ...@@ -13153,6 +13153,7 @@ static int intel_atomic_commit(struct drm_device *dev,
if (!modeset) if (!modeset)
intel_pre_plane_update(intel_crtc); intel_pre_plane_update(intel_crtc);
if (crtc->state->active)
drm_atomic_helper_commit_planes_on_crtc(crtc_state); drm_atomic_helper_commit_planes_on_crtc(crtc_state);
if (put_domains) if (put_domains)
...@@ -13471,9 +13472,6 @@ intel_commit_primary_plane(struct drm_plane *plane, ...@@ -13471,9 +13472,6 @@ intel_commit_primary_plane(struct drm_plane *plane,
crtc = crtc ? crtc : plane->crtc; crtc = crtc ? crtc : plane->crtc;
if (!crtc->state->active)
return;
dev_priv->display.update_primary_plane(crtc, fb, dev_priv->display.update_primary_plane(crtc, fb,
state->src.x1 >> 16, state->src.x1 >> 16,
state->src.y1 >> 16); state->src.y1 >> 16);
...@@ -13502,7 +13500,6 @@ static void intel_begin_crtc_commit(struct drm_crtc *crtc, ...@@ -13502,7 +13500,6 @@ static void intel_begin_crtc_commit(struct drm_crtc *crtc,
intel_update_watermarks(crtc); intel_update_watermarks(crtc);
/* Perform vblank evasion around commit operation */ /* Perform vblank evasion around commit operation */
if (crtc->state->active)
intel_pipe_update_start(intel_crtc); intel_pipe_update_start(intel_crtc);
if (modeset) if (modeset)
...@@ -13519,7 +13516,6 @@ static void intel_finish_crtc_commit(struct drm_crtc *crtc, ...@@ -13519,7 +13516,6 @@ static void intel_finish_crtc_commit(struct drm_crtc *crtc,
{ {
struct intel_crtc *intel_crtc = to_intel_crtc(crtc); struct intel_crtc *intel_crtc = to_intel_crtc(crtc);
if (crtc->state->active)
intel_pipe_update_end(intel_crtc); intel_pipe_update_end(intel_crtc);
} }
...@@ -13703,7 +13699,6 @@ intel_commit_cursor_plane(struct drm_plane *plane, ...@@ -13703,7 +13699,6 @@ intel_commit_cursor_plane(struct drm_plane *plane,
intel_crtc->cursor_bo = obj; intel_crtc->cursor_bo = obj;
update: update:
if (crtc->state->active)
intel_crtc_update_cursor(crtc, state->visible); intel_crtc_update_cursor(crtc, state->visible);
} }
......
...@@ -938,9 +938,6 @@ intel_commit_sprite_plane(struct drm_plane *plane, ...@@ -938,9 +938,6 @@ intel_commit_sprite_plane(struct drm_plane *plane,
crtc = crtc ? crtc : plane->crtc; crtc = crtc ? crtc : plane->crtc;
if (!crtc->state->active)
return;
if (state->visible) { if (state->visible) {
intel_plane->update_plane(plane, crtc, fb, intel_plane->update_plane(plane, crtc, fb,
state->dst.x1, state->dst.y1, state->dst.x1, state->dst.y1,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment