]> git.baikalelectronics.ru Git - kernel.git/commitdiff
drm/i915/icl: Enable media sampler powergate
authorMika Kuoppala <mika.kuoppala@linux.intel.com>
Wed, 10 Apr 2019 10:59:19 +0000 (13:59 +0300)
committerChris Wilson <chris@chris-wilson.co.uk>
Thu, 11 Apr 2019 07:40:05 +0000 (08:40 +0100)
Enable media sampler powergate as recommended.

v2: use REG_BIT (Chris)

Cc: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Acked-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Link: https://patchwork.freedesktop.org/patch/msgid/20190410105923.18546-3-mika.kuoppala@linux.intel.com
drivers/gpu/drm/i915/i915_reg.h
drivers/gpu/drm/i915/intel_pm.c

index 9c206e803ab30dd53a6cafd538776890c0013da0..3c243025ea3e2c83a12f14316586171b7eda93a8 100644 (file)
@@ -8687,8 +8687,9 @@ enum {
 #define GEN9_MEDIA_PG_IDLE_HYSTERESIS          _MMIO(0xA0C4)
 #define GEN9_RENDER_PG_IDLE_HYSTERESIS         _MMIO(0xA0C8)
 #define GEN9_PG_ENABLE                         _MMIO(0xA210)
-#define GEN9_RENDER_PG_ENABLE                  (1 << 0)
-#define GEN9_MEDIA_PG_ENABLE                   (1 << 1)
+#define GEN9_RENDER_PG_ENABLE                  REG_BIT(0)
+#define GEN9_MEDIA_PG_ENABLE                   REG_BIT(1)
+#define GEN11_MEDIA_SAMPLER_PG_ENABLE          REG_BIT(2)
 #define GEN8_PUSHBUS_CONTROL                   _MMIO(0xA248)
 #define GEN8_PUSHBUS_ENABLE                    _MMIO(0xA250)
 #define GEN8_PUSHBUS_SHIFT                     _MMIO(0xA25C)
index b7946a73cea39d199ccf0e8519e97a8c3c8103a8..2f0204c2be16196b5b4465a2edbb608d8bc300fe 100644 (file)
@@ -7185,7 +7185,9 @@ static void gen11_enable_rc6(struct drm_i915_private *dev_priv)
 
        /* 3b: Enable Coarse Power Gating only when RC6 is enabled. */
        I915_WRITE(GEN9_PG_ENABLE,
-                  GEN9_RENDER_PG_ENABLE | GEN9_MEDIA_PG_ENABLE);
+                  GEN9_RENDER_PG_ENABLE |
+                  GEN9_MEDIA_PG_ENABLE |
+                  GEN11_MEDIA_SAMPLER_PG_ENABLE);
 
        intel_uncore_forcewake_put(&dev_priv->uncore, FORCEWAKE_ALL);
 }