[igt-dev] [PATCH i-g-t 36/79] tests/i915/gem_exec_params: Convert to intel_ctx_t
Jason Ekstrand
jason at jlekstrand.net
Thu Jun 17 19:12:43 UTC 2021
Signed-off-by: Jason Ekstrand <jason at jlekstrand.net>
Reviewed-by: Zbigniew Kempczyński <zbigniew.kempczynski at intel.com>
---
tests/i915/gem_exec_params.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/tests/i915/gem_exec_params.c b/tests/i915/gem_exec_params.c
index 6ab1ab110..729d38a43 100644
--- a/tests/i915/gem_exec_params.c
+++ b/tests/i915/gem_exec_params.c
@@ -299,8 +299,10 @@ static void test_larger_than_life_batch(int fd)
{
const struct intel_execution_engine2 *e;
uint64_t size = 1ULL << 32; /* batch_len is __u32 as per the ABI */
+ 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),
@@ -316,7 +318,7 @@ static void test_larger_than_life_batch(int fd)
igt_require(size < gem_aperture_size(fd));
intel_require_memory(2, size, CHECK_RAM); /* batch + shadow */
- __for_each_physical_engine(fd, e) {
+ for_each_ctx_engine(fd, ctx, e) {
/* Keep the batch_len implicit [0] */
execbuf.flags = e->flags;
--
2.31.1
More information about the igt-dev
mailing list