[Intel-gfx] [PATCH 04/24] drm/i915: calculate same watermarks on Haswell as on Ivy Bridge

Jesse Barnes jbarnes at virtuousgeek.org
Tue May 1 01:54:39 CEST 2012


On Thu, 26 Apr 2012 15:51:44 -0300
Eugeni Dodonov <eugeni.dodonov at intel.com> wrote:

> v2: check for num_pipe instead, as suggested by Jesse
> 
> CC: Jesse Barnes <jbarnes at virtuousgeek.org>
> Signed-off-by: Eugeni Dodonov <eugeni.dodonov at intel.com>
> ---
>  drivers/gpu/drm/i915/intel_pm.c |    3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c
> index 0552058..4e0af68 100644
> --- a/drivers/gpu/drm/i915/intel_pm.c
> +++ b/drivers/gpu/drm/i915/intel_pm.c
> @@ -1694,8 +1694,7 @@ static void sandybridge_update_wm(struct drm_device *dev)
>  		enabled |= 2;
>  	}
>  
> -	/* IVB has 3 pipes */
> -	if (IS_IVYBRIDGE(dev) &&
> +	if ((dev_priv->num_pipe == 2) &&
>  	    g4x_compute_wm0(dev, 2,
>  			    &sandybridge_display_wm_info, latency,
>  			    &sandybridge_cursor_wm_info, latency,

As noted on IRC, a cleanup (one of many for the WM code) would be to
use a loop for calculating the per-pipe watermarks.

But that can be done on top.

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

-- 
Jesse Barnes, Intel Open Source Technology Center



More information about the Intel-gfx mailing list