iris/batch: Add exec_flags field

Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12692>
This commit is contained in:
Jordan Justen
2021-08-31 13:22:24 -07:00
parent dd89c6ca65
commit 3643450dc0
2 changed files with 3 additions and 1 deletions

View File

@@ -242,6 +242,7 @@ iris_init_non_engine_contexts(struct iris_context *ice, int priority)
for (int i = 0; i < IRIS_BATCH_COUNT; i++) { for (int i = 0; i < IRIS_BATCH_COUNT; i++) {
struct iris_batch *batch = &ice->batches[i]; struct iris_batch *batch = &ice->batches[i];
batch->hw_ctx_id = iris_create_hw_context(screen->bufmgr); batch->hw_ctx_id = iris_create_hw_context(screen->bufmgr);
batch->exec_flags = I915_EXEC_RENDER;
assert(batch->hw_ctx_id); assert(batch->hw_ctx_id);
iris_hw_context_set_priority(screen->bufmgr, batch->hw_ctx_id, priority); iris_hw_context_set_priority(screen->bufmgr, batch->hw_ctx_id, priority);
} }
@@ -842,7 +843,7 @@ submit_batch(struct iris_batch *batch)
.batch_start_offset = 0, .batch_start_offset = 0,
/* This must be QWord aligned. */ /* This must be QWord aligned. */
.batch_len = ALIGN(batch->primary_batch_size, 8), .batch_len = ALIGN(batch->primary_batch_size, 8),
.flags = I915_EXEC_RENDER | .flags = batch->exec_flags |
I915_EXEC_NO_RELOC | I915_EXEC_NO_RELOC |
I915_EXEC_BATCH_FIRST | I915_EXEC_BATCH_FIRST |
I915_EXEC_HANDLE_LUT, I915_EXEC_HANDLE_LUT,

View File

@@ -80,6 +80,7 @@ struct iris_batch {
uint64_t last_surface_base_address; uint64_t last_surface_base_address;
uint32_t hw_ctx_id; uint32_t hw_ctx_id;
uint32_t exec_flags;
/** A list of all BOs referenced by this batch */ /** A list of all BOs referenced by this batch */
struct iris_bo **exec_bos; struct iris_bo **exec_bos;