drm/i915/bxt: Add WaSetClckGatingDisableMedia
authorArun Siluvery <arun.siluvery@linux.intel.com>
Tue, 8 Sep 2015 09:31:49 +0000 (10:31 +0100)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Mon, 14 Sep 2015 09:12:28 +0000 (11:12 +0200)
Signed-off-by: Arun Siluvery <arun.siluvery@linux.intel.com>
Reviewed-by: Sagar Arun Kamble <sagar.a.kamble@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 65b5682b19ac1e7f22714bc78975fd81313710a1..495ac17b04c7c78be961b06942b78ebb8dc2e851 100644 (file)
@@ -6897,6 +6897,7 @@ enum skl_disp_power_wells {
 #define   GEN7_DOP_CLOCK_GATE_ENABLE           (1<<0)
 #define   GEN8_DOP_CLOCK_GATE_CFCLK_ENABLE     (1<<2)
 #define   GEN8_DOP_CLOCK_GATE_GUC_ENABLE       (1<<4)
+#define   GEN8_DOP_CLOCK_GATE_MEDIA_ENABLE     (1<<6)
 
 #define GEN8_GARBCNTL                   0xB004
 #define   GEN9_GAPS_TSV_CREDIT_DISABLE  (1<<7)
index 64bc77ef6b2ed4c6db8e3a4d32693a3b76852326..920872acf4db2474709e587b597f9e9d9a8baefb 100644 (file)
@@ -134,6 +134,12 @@ static void bxt_init_clock_gating(struct drm_device *dev)
                 */
                I915_WRITE(TILECTL, I915_READ(TILECTL) | TILECTL_TLBPF);
        }
+
+       /* WaSetClckGatingDisableMedia:bxt */
+       if (INTEL_REVID(dev) == BXT_REVID_A0) {
+               I915_WRITE(GEN7_MISCCPCTL, (I915_READ(GEN7_MISCCPCTL) &
+                                           ~GEN8_DOP_CLOCK_GATE_MEDIA_ENABLE));
+       }
 }
 
 static void i915_pineview_get_mem_freq(struct drm_device *dev)