Commit 69d0b96c authored by Daniel Vetter's avatar Daniel Vetter Committed by Eric Anholt

drm/i915: fixup pageflip ringbuffer commands for i8xx

Add a new path for 2nd gen chips that uses the commands for i81x
chips (where public docs do exist) augmented with the plane bits
from i915. It seems to work and doesn't result in a black screen
like before.
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Cc: stable@kernel.org
[anholt: resolved against conflict]
Reviewed-by: default avatarJesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: default avatarEric Anholt <eric@anholt.net>
parent 0be555b6
...@@ -5119,12 +5119,18 @@ static int intel_crtc_page_flip(struct drm_crtc *crtc, ...@@ -5119,12 +5119,18 @@ static int intel_crtc_page_flip(struct drm_crtc *crtc,
OUT_RING(offset | obj_priv->tiling_mode); OUT_RING(offset | obj_priv->tiling_mode);
pipesrc = I915_READ(pipesrc_reg); pipesrc = I915_READ(pipesrc_reg);
OUT_RING(pipesrc & 0x0fff0fff); OUT_RING(pipesrc & 0x0fff0fff);
} else { } else if (IS_GEN3(dev)) {
OUT_RING(MI_DISPLAY_FLIP_I915 | OUT_RING(MI_DISPLAY_FLIP_I915 |
MI_DISPLAY_FLIP_PLANE(intel_crtc->plane)); MI_DISPLAY_FLIP_PLANE(intel_crtc->plane));
OUT_RING(fb->pitch); OUT_RING(fb->pitch);
OUT_RING(offset); OUT_RING(offset);
OUT_RING(MI_NOOP); OUT_RING(MI_NOOP);
} else {
OUT_RING(MI_DISPLAY_FLIP |
MI_DISPLAY_FLIP_PLANE(intel_crtc->plane));
OUT_RING(fb->pitch);
OUT_RING(offset);
OUT_RING(MI_NOOP);
} }
ADVANCE_LP_RING(); ADVANCE_LP_RING();
......
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