drm/i915: Enable watermarks for BDW
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Tue, 7 Jan 2014 14:14:09 +0000 (16:14 +0200)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Tue, 7 Jan 2014 21:21:01 +0000 (22:21 +0100)
We forgot to intialize the watermark vfuncs for BDW, and hence the
watermarks were never updated.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/intel_pm.c

index 78503157daf214d6bb6f305965324f50a639caf6..835f86386b953578d3cfb9b5742dd65414e5d96e 100644 (file)
@@ -5627,6 +5627,17 @@ void intel_init_pm(struct drm_device *dev)
                        }
                        dev_priv->display.init_clock_gating = haswell_init_clock_gating;
                } else if (INTEL_INFO(dev)->gen == 8) {
+                       if (dev_priv->wm.pri_latency[0] &&
+                           dev_priv->wm.spr_latency[0] &&
+                           dev_priv->wm.cur_latency[0]) {
+                               dev_priv->display.update_wm = ilk_update_wm;
+                               dev_priv->display.update_sprite_wm =
+                                       ilk_update_sprite_wm;
+                       } else {
+                               DRM_DEBUG_KMS("Failed to read display plane latency. "
+                                             "Disable CxSR\n");
+                               dev_priv->display.update_wm = NULL;
+                       }
                        dev_priv->display.init_clock_gating = gen8_init_clock_gating;
                } else
                        dev_priv->display.update_wm = NULL;