drm/i915: Make sure LP1+ watermarks levels are preserved when going from 1 to 2 pipes
authorVille Syrjälä <[email protected]>
Fri, 1 Apr 2016 18:53:18 +0000 (21:53 +0300)
committerVille Syrjälä <[email protected]>
Tue, 12 Apr 2016 16:01:59 +0000 (19:01 +0300)
Once again ILK is unhappy if we clear out the LP1+ watermark levels
outright, and instead we must disable the levels we don't want while
still leaving the actual programmed watermark levels intact.

Fixes underruns on the already enabled pipe when programming watermarks
while enabling the second pipe.

Cc: Daniel Vetter <[email protected]>
Cc: Matt Roper <[email protected]>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=93787
Signed-off-by: Ville Syrjälä <[email protected]>
Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
Reviewed-by: Patrik Jakobsson <[email protected]>
drivers/gpu/drm/i915/intel_pm.c

index 43b24a1f5ee612fe2f8d8fd6a2da1500444accda..f6782765e145a7ffa3d90f0506d3b12078578008 100644 (file)
@@ -2483,7 +2483,7 @@ static void ilk_wm_merge(struct drm_device *dev,
        /* ILK/SNB/IVB: LP1+ watermarks only w/ single pipe */
        if ((INTEL_INFO(dev)->gen <= 6 || IS_IVYBRIDGE(dev)) &&
            config->num_pipes_active > 1)
-               return;
+               last_enabled_level = 0;
 
        /* ILK: FBC WM must be disabled always */
        merged->fbc_wm_enabled = INTEL_INFO(dev)->gen >= 6;