drm/i915/gen9: Add WaDisableSkipCaching
authorMika Kuoppala <mika.kuoppala@linux.intel.com>
Tue, 7 Jun 2016 14:19:08 +0000 (17:19 +0300)
committerMika Kuoppala <mika.kuoppala@intel.com>
Wed, 8 Jun 2016 13:25:03 +0000 (16:25 +0300)
Make sure that we never enable skip caching on gen9 by
accident.

References: HSD#2134698
Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1465309159-30531-17-git-send-email-mika.kuoppala@intel.com
drivers/gpu/drm/i915/intel_mocs.c

index b765c75f3fcda5b1016ba9b484dada0b5f7a0866..8f96c40e415c7239e976caf47d751ee3232e5090 100644 (file)
@@ -156,6 +156,16 @@ static bool get_mocs_settings(struct drm_i915_private *dev_priv,
                          "Platform that should have a MOCS table does not.\n");
        }
 
+       /* WaDisableSkipCaching:skl,bxt,kbl */
+       if (IS_GEN9(dev_priv)) {
+               int i;
+
+               for (i = 0; i < table->size; i++)
+                       if (WARN_ON(table->table[i].l3cc_value &
+                                   (L3_ESC(1) || L3_SCC(0x7))))
+                               return false;
+       }
+
        return result;
 }