[Intel-gfx] [PATCH 1/2] drm/i915: fixup pageflip ringbuffer commands for i8xx

Jesse Barnes jbarnes at virtuousgeek.org
Wed Aug 4 21:48:25 CEST 2010


On Wed,  4 Aug 2010 21:22:09 +0200
Daniel Vetter <daniel.vetter at ffwll.ch> wrote:

> 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: Daniel Vetter <daniel.vetter at ffwll.ch>
> Cc: stable at kernel.org
> ---
>  drivers/gpu/drm/i915/intel_display.c |    8 +++++++-
>  1 files changed, 7 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index 8359c50..8135ee0 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -4933,12 +4933,18 @@ static int intel_crtc_page_flip(struct drm_crtc *crtc,
>  		OUT_RING(obj_priv->gtt_offset | obj_priv->tiling_mode);
>  		pipesrc = I915_READ(pipesrc_reg); 
>  		OUT_RING(pipesrc & 0x0fff0fff);
> -	} else {
> +	} else if (IS_GEN3(dev)) {
>  		OUT_RING(MI_DISPLAY_FLIP_I915 |
>  			 MI_DISPLAY_FLIP_PLANE(intel_crtc->plane));
>  		OUT_RING(fb->pitch);
>  		OUT_RING(obj_priv->gtt_offset);
>  		OUT_RING(MI_NOOP);
> +	} else {
> +		OUT_RING(MI_DISPLAY_FLIP |
> +			 MI_DISPLAY_FLIP_PLANE(intel_crtc->plane));
> +		OUT_RING(fb->pitch);
> +		OUT_RING(obj_priv->gtt_offset);
> +		OUT_RING(MI_NOOP);
>  	}
>  	ADVANCE_LP_RING();

Yep, looks fine.

Reviewed-by: Jesse Barnes <jbarnes at virtuousgeek.org>

-- 
Jesse Barnes, Intel Open Source Technology Center



More information about the Intel-gfx mailing list