[igt-dev] [PATCH i-g-t] tests/gem_exec_params: Fix context within which batch is executed
Zbigniew Kempczyński
zbigniew.kempczynski at intel.com
Wed Aug 25 07:51:49 UTC 2021
With new intel_ctx_t we're responsible to set execbuf rsvd1 (context) id
field. As same field exists for exec object there's risk to mechanically
set improper field and compiler won't complain.
Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski at intel.com>
Cc: Ashutosh Dixit <ashutosh.dixit at intel.com>
Cc: Jason Ekstrand <jason at jlekstrand.net>
---
tests/i915/gem_exec_params.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/i915/gem_exec_params.c b/tests/i915/gem_exec_params.c
index ba79791a1..d247b8a61 100644
--- a/tests/i915/gem_exec_params.c
+++ b/tests/i915/gem_exec_params.c
@@ -334,11 +334,11 @@ static void test_larger_than_life_batch(int fd)
const intel_ctx_t *ctx = intel_ctx_create_all_physical(fd);
struct drm_i915_gem_exec_object2 exec = {
.handle = batch_create_size(fd, size),
- .rsvd1 = ctx->id,
};
struct drm_i915_gem_execbuffer2 execbuf = {
.buffers_ptr = to_user_pointer(&exec),
.buffer_count = 1,
+ .rsvd1 = ctx->id,
};
/*
--
2.26.0
More information about the igt-dev
mailing list