drm/i915: Implement WaProgramMiArbOnOffAroundMiSetContext:bdw
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Mon, 31 Mar 2014 15:17:18 +0000 (18:17 +0300)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Wed, 2 Apr 2014 07:11:22 +0000 (09:11 +0200)
BSpec seems to tell us we need the MI_ARB_ON_OFF w/a around
MI_SET_CONTEXT on gen8.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Ben Widawsky <ben@bwidawsk.net>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/i915_gem_context.c

index 6043062ffce73477231fc053113b9eb8bce12607..edbad2787d65fbeb22e4e1e1fa72f976a499c8ed 100644 (file)
@@ -606,8 +606,8 @@ mi_set_context(struct intel_ring_buffer *ring,
        if (ret)
                return ret;
 
-       /* WaProgramMiArbOnOffAroundMiSetContext:ivb,vlv,hsw */
-       if (IS_GEN7(ring->dev))
+       /* WaProgramMiArbOnOffAroundMiSetContext:ivb,vlv,hsw,bdw */
+       if (INTEL_INFO(ring->dev)->gen >= 7)
                intel_ring_emit(ring, MI_ARB_ON_OFF | MI_ARB_DISABLE);
        else
                intel_ring_emit(ring, MI_NOOP);
@@ -625,7 +625,7 @@ mi_set_context(struct intel_ring_buffer *ring,
         */
        intel_ring_emit(ring, MI_NOOP);
 
-       if (IS_GEN7(ring->dev))
+       if (INTEL_INFO(ring->dev)->gen >= 7)
                intel_ring_emit(ring, MI_ARB_ON_OFF | MI_ARB_ENABLE);
        else
                intel_ring_emit(ring, MI_NOOP);