diff options
author | Ville Syrjälä <ville.syrjala@linux.intel.com> | 2015-05-19 13:32:56 -0400 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2015-05-22 02:08:06 -0400 |
commit | 4d487cff19975d65234902e4abed8724a7b5b94b (patch) | |
tree | f78af5b290ef614705e454e10a130416c5b53d0b | |
parent | 7ad0dbab20678709ca268afa54189cf49b058f15 (diff) |
drm/i915: Move WaProgramL3SqcReg1Default:bdw to init_clock_gating()
GEN8_L3SQCREG1 isn't saved in the context (verified by going through
a context dump), and so we shouldn't be using the ring w/a code to
initialize it. Also Bspec explicitly talks about MMIO and writing it
with the CPU.
Additionally there's another w/a WaTempDisableDOPClkGating:bdw which
tells us to disable DOP clock gating around the GEN8_L3SQCREG1 write
to make sure everyone notices the change. So let's do that as well.
Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
-rw-r--r-- | drivers/gpu/drm/i915/intel_pm.c | 10 | ||||
-rw-r--r-- | drivers/gpu/drm/i915/intel_ringbuffer.c | 3 |
2 files changed, 10 insertions, 3 deletions
diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c index cfc748086088..85ba52bacfea 100644 --- a/drivers/gpu/drm/i915/intel_pm.c +++ b/drivers/gpu/drm/i915/intel_pm.c | |||
@@ -6174,6 +6174,7 @@ static void broadwell_init_clock_gating(struct drm_device *dev) | |||
6174 | { | 6174 | { |
6175 | struct drm_i915_private *dev_priv = dev->dev_private; | 6175 | struct drm_i915_private *dev_priv = dev->dev_private; |
6176 | enum pipe pipe; | 6176 | enum pipe pipe; |
6177 | uint32_t misccpctl; | ||
6177 | 6178 | ||
6178 | ilk_init_lp_watermarks(dev); | 6179 | ilk_init_lp_watermarks(dev); |
6179 | 6180 | ||
@@ -6204,6 +6205,15 @@ static void broadwell_init_clock_gating(struct drm_device *dev) | |||
6204 | I915_WRITE(GEN8_UCGCTL6, I915_READ(GEN8_UCGCTL6) | | 6205 | I915_WRITE(GEN8_UCGCTL6, I915_READ(GEN8_UCGCTL6) | |
6205 | GEN8_SDEUNIT_CLOCK_GATE_DISABLE); | 6206 | GEN8_SDEUNIT_CLOCK_GATE_DISABLE); |
6206 | 6207 | ||
6208 | /* | ||
6209 | * WaProgramL3SqcReg1Default:bdw | ||
6210 | * WaTempDisableDOPClkGating:bdw | ||
6211 | */ | ||
6212 | misccpctl = I915_READ(GEN7_MISCCPCTL); | ||
6213 | I915_WRITE(GEN7_MISCCPCTL, misccpctl & ~GEN7_DOP_CLOCK_GATE_ENABLE); | ||
6214 | I915_WRITE(GEN8_L3SQCREG1, BDW_WA_L3SQCREG1_DEFAULT); | ||
6215 | I915_WRITE(GEN7_MISCCPCTL, misccpctl); | ||
6216 | |||
6207 | lpt_init_clock_gating(dev); | 6217 | lpt_init_clock_gating(dev); |
6208 | } | 6218 | } |
6209 | 6219 | ||
diff --git a/drivers/gpu/drm/i915/intel_ringbuffer.c b/drivers/gpu/drm/i915/intel_ringbuffer.c index 052265ae8de1..d934f857394d 100644 --- a/drivers/gpu/drm/i915/intel_ringbuffer.c +++ b/drivers/gpu/drm/i915/intel_ringbuffer.c | |||
@@ -853,9 +853,6 @@ static int bdw_init_workarounds(struct intel_engine_cs *ring) | |||
853 | GEN6_WIZ_HASHING_MASK, | 853 | GEN6_WIZ_HASHING_MASK, |
854 | GEN6_WIZ_HASHING_16x4); | 854 | GEN6_WIZ_HASHING_16x4); |
855 | 855 | ||
856 | /* WaProgramL3SqcReg1Default:bdw */ | ||
857 | WA_WRITE(GEN8_L3SQCREG1, BDW_WA_L3SQCREG1_DEFAULT); | ||
858 | |||
859 | return 0; | 856 | return 0; |
860 | } | 857 | } |
861 | 858 | ||