From: Imre Deak Date: Tue, 3 May 2016 12:54:19 +0000 (+0300) Subject: drm/i915/bdw: Add missing delay during L3 SQC credit programming X-Git-Tag: MMI-PSA29.97-13-9~7427^2~45^2~121 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=48e5d68d28f00c0cadac5a830980ff3222781abb;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git drm/i915/bdw: Add missing delay during L3 SQC credit programming BSpec requires us to wait ~100 clocks before re-enabling clock gating, so make sure we do this. CC: stable@vger.kernel.org CC: Ville Syrjälä Signed-off-by: Imre Deak Reviewed-by: Ville Syrjälä Link: http://patchwork.freedesktop.org/patch/msgid/1462280061-1457-2-git-send-email-imre.deak@intel.com --- diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c index 2422ac38ce5d..227cd2d395a9 100644 --- a/drivers/gpu/drm/i915/intel_pm.c +++ b/drivers/gpu/drm/i915/intel_pm.c @@ -6738,6 +6738,12 @@ static void broadwell_init_clock_gating(struct drm_device *dev) misccpctl = I915_READ(GEN7_MISCCPCTL); I915_WRITE(GEN7_MISCCPCTL, misccpctl & ~GEN7_DOP_CLOCK_GATE_ENABLE); I915_WRITE(GEN8_L3SQCREG1, BDW_WA_L3SQCREG1_DEFAULT); + /* + * Wait at least 100 clocks before re-enabling clock gating. See + * the definition of L3SQCREG1 in BSpec. + */ + POSTING_READ(GEN8_L3SQCREG1); + udelay(1); I915_WRITE(GEN7_MISCCPCTL, misccpctl); /*