drm/i915/skl: Implement WaEnableLbsSlaRetryTimerDecrement
authorDamien Lespiau <damien.lespiau@intel.com>
Mon, 9 Feb 2015 19:33:13 +0000 (19:33 +0000)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Fri, 13 Feb 2015 22:28:38 +0000 (23:28 +0100)
This W/A is put in a gen9 specific function because it may well be
needed on other gen9 platforms.

Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
Reviewed-by: Nick Hoath <nicholas.hoath@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/i915_reg.h
drivers/gpu/drm/i915/intel_pm.c

index 0b522d3f529db7aaf810f0c87b20679ea0551906..1dc91de7d2e646c01b7a7e094d8b0d4d4600f946 100644 (file)
@@ -5285,6 +5285,9 @@ enum skl_disp_power_wells {
 #define HSW_SCRATCH1                           0xb038
 #define  HSW_SCRATCH1_L3_DATA_ATOMICS_DISABLE  (1<<27)
 
+#define BDW_SCRATCH1                                   0xb11c
+#define  GEN9_LBS_SLA_RETRY_TIMER_DECREMENT_ENABLE     (1<<2)
+
 /* PCH */
 
 /* south display engine interrupt: IBX */
index 325f640c16c45a6f7dca8dd5532e582f8f4505be..f68d12cb02466b5ea643a5f1ecc4a3a65904f28d 100644 (file)
 #define INTEL_RC6p_ENABLE                      (1<<1)
 #define INTEL_RC6pp_ENABLE                     (1<<2)
 
+static void gen9_init_clock_gating(struct drm_device *dev)
+{
+       struct drm_i915_private *dev_priv = dev->dev_private;
+
+       /* WaEnableLbsSlaRetryTimerDecrement:skl */
+       I915_WRITE(BDW_SCRATCH1, I915_READ(BDW_SCRATCH1) |
+                  GEN9_LBS_SLA_RETRY_TIMER_DECREMENT_ENABLE);
+}
+
 static void skl_init_clock_gating(struct drm_device *dev)
 {
        struct drm_i915_private *dev_priv = dev->dev_private;
 
+       gen9_init_clock_gating(dev);
+
        if (INTEL_REVID(dev) == SKL_REVID_A0) {
                /*
                 * WaDisableSDEUnitClockGating:skl