From d348654a75726e555d360119bab77b213d3e7366 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tapani=20P=C3=A4lli?= Date: Fri, 27 Mar 2026 13:49:19 +0200 Subject: [PATCH] iris: use mi_set_autostrip_state for autostrip control MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Tapani Pälli Reviewed-by: Lionel Landwerlin Part-of: --- src/gallium/drivers/iris/iris_state.c | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/src/gallium/drivers/iris/iris_state.c b/src/gallium/drivers/iris/iris_state.c index b81d9798ec5..a2f99e68c0d 100644 --- a/src/gallium/drivers/iris/iris_state.c +++ b/src/gallium/drivers/iris/iris_state.c @@ -6821,12 +6821,27 @@ emit_wa_18020335297_dummy_draw(struct iris_batch *batch) } } +#if INTEL_WA_14024997852_GFX_VER +static void +setup_ff_mode_autostrip(struct iris_context *ice, + struct iris_batch *batch, + bool enable) +{ + struct mi_builder b; + mi_builder_init(&b, batch->screen->devinfo, batch); + mi_builder_set_mocs(&b, isl_mocs(&batch->screen->isl_dev, 0, false)); + mi_builder_set_write_check(&b, true); + + mi_set_autostrip_state(&b, enable); +} +#endif + static void setup_autostrip_state(struct iris_context *ice, struct iris_batch *batch, bool enable) { -#if GFX_VERx10 >= 200 +#if INTEL_WA_14024997852_GFX_VER if (ice->state.autostrip_state != enable) { iris_emit_pipe_control_flush(batch, "Wa_14024997852", @@ -6839,11 +6854,8 @@ setup_autostrip_state(struct iris_context *ice, vfl.PartialAutostripDisableMask = true; } /* TE and Mesh. */ - iris_emit_reg(batch, GENX(FF_MODE), ff) { - ff.TEAutostripDisable = !enable; - ff.MeshShaderAutostripDisable = !enable; - ff.MeshShaderPartialAutostripDisable = !enable; - } + setup_ff_mode_autostrip(ice, batch, enable); + ice->state.autostrip_state = enable; } #endif