iris: set depth stall enabled when depth flush enabled on gen12
authorTapani Pälli <tapani.palli@intel.com>
Tue, 14 Jan 2020 08:02:05 +0000 (10:02 +0200)
committerTapani Pälli <tapani.palli@intel.com>
Thu, 16 Jan 2020 12:05:54 +0000 (14:05 +0200)
This implements HW workaround #1409600907 for iris driver.

Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3378>

src/gallium/drivers/iris/iris_state.c

index 7ead920cadf30863f629e17ffa31c105812a4aa3..b1340e1e3da2df019383eded17811fa0ea41a8e5 100644 (file)
@@ -7161,6 +7161,15 @@ iris_emit_raw_pipe_control(struct iris_batch *batch,
          flags |= PIPE_CONTROL_STALL_AT_SCOREBOARD;
    }
 
+   if (GEN_GEN >= 12 && (flags & PIPE_CONTROL_DEPTH_CACHE_FLUSH)) {
+      /* GEN:BUG:1409600907:
+       *
+       * "PIPE_CONTROL with Depth Stall Enable bit must be set
+       * with any PIPE_CONTROL with Depth Flush Enable bit set.
+       */
+      flags |= PIPE_CONTROL_DEPTH_STALL;
+   }
+
    /* Emit --------------------------------------------------------------- */
 
    if (INTEL_DEBUG & DEBUG_PIPE_CONTROL) {