summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/crocus/crocus_state.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/drivers/crocus/crocus_state.c')
-rw-r--r--src/gallium/drivers/crocus/crocus_state.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/gallium/drivers/crocus/crocus_state.c b/src/gallium/drivers/crocus/crocus_state.c
index 1df647d81c4..9dbe0a49e2d 100644
--- a/src/gallium/drivers/crocus/crocus_state.c
+++ b/src/gallium/drivers/crocus/crocus_state.c
@@ -6789,6 +6789,22 @@ crocus_upload_dirty_render_state(struct crocus_context *ice,
emit_push_constant_packets(ice, batch, MESA_SHADER_GEOMETRY, &push_bos);
#endif
+#if GFX_VERx10 == 70
+ /**
+ * From Graphics BSpec: 3D-Media-GPGPU Engine > 3D Pipeline Stages >
+ * Geometry > Geometry Shader > State:
+ *
+ * "Note: Because of corruption in IVB:GT2, software needs to flush the
+ * whole fixed function pipeline when the GS enable changes value in
+ * the 3DSTATE_GS."
+ *
+ * The hardware architects have clarified that in this context "flush the
+ * whole fixed function pipeline" means to emit a PIPE_CONTROL with the "CS
+ * Stall" bit set.
+ */
+ if (batch->screen->devinfo.gt == 2 && ice->state.gs_enabled != active)
+ gen7_emit_cs_stall_flush(batch);
+#endif
#if GFX_VER >= 6
crocus_emit_cmd(batch, GENX(3DSTATE_GS), gs)
#else
@@ -6934,6 +6950,7 @@ crocus_upload_dirty_render_state(struct crocus_context *ice,
gs.MaximumVPIndex = ice->state.num_viewports - 1;
#endif
}
+ ice->state.gs_enabled = active;
}
#if GFX_VER >= 7