Mesa (main): iris: clear bos_written when resetting a batch

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Fri Oct 22 09:51:29 UTC 2021


Module: Mesa
Branch: main
Commit: 1465ec8cf35c3e62635bba31682a0e2673e40100
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=1465ec8cf35c3e62635bba31682a0e2673e40100

Author: Tapani Pälli <tapani.palli at intel.com>
Date:   Thu Oct 21 11:02:34 2021 +0300

iris: clear bos_written when resetting a batch

This fixes dEQP-EGL.functional.sharing.gles2.multithread.* tests that
are hitting: "iris: Failed to submit batchbuffer: Invalid argument"
error.

v2: clear on reset rather than clear 'on-the-fly' (Kenneth Graunke)

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5537
Fixes: e4c3d3efc7a ("iris: Defer construction of the validation (exec_object2) list")
Signed-off-by: Tapani Pälli <tapani.palli at intel.com>
Reviewed-by: Kenneth Graunke <kenneth at whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13464>

---

 src/gallium/drivers/iris/iris_batch.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/gallium/drivers/iris/iris_batch.c b/src/gallium/drivers/iris/iris_batch.c
index afd152f3eaf..f9a1eed0def 100644
--- a/src/gallium/drivers/iris/iris_batch.c
+++ b/src/gallium/drivers/iris/iris_batch.c
@@ -412,6 +412,9 @@ iris_batch_reset(struct iris_batch *batch)
    create_batch(batch);
    assert(batch->bo->index == 0);
 
+   memset(batch->bos_written, 0,
+          sizeof(BITSET_WORD) * BITSET_WORDS(batch->exec_array_size));
+
    struct iris_syncobj *syncobj = iris_create_syncobj(bufmgr);
    iris_batch_add_syncobj(batch, syncobj, I915_EXEC_FENCE_SIGNAL);
    iris_syncobj_reference(bufmgr, &syncobj, NULL);



More information about the mesa-commit mailing list