From 05690ad570a4501f0d0263ec05399660bd163117 Mon Sep 17 00:00:00 2001 From: Tvrtko Ursulin Date: Fri, 22 Dec 2017 13:13:47 +0000 Subject: lib/dummyload: Support returning output fence Support creating spin batches which return an output fence using new __igt_spin_batch_new_fence / igt_spin_batch_new_fence API. This will be used fromthe perf_pmu@interrupts test to ensure user interrupt generation from a batch with controlled duration. v2: Support out fence with multiple engines as well. (Chris Wilson) Signed-off-by: Tvrtko Ursulin Cc: Chris Wilson Reviewed-by: Chris Wilson (v1) Reviewed-by: Chris Wilson --- lib/igt_dummyload.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'lib/igt_dummyload.h') diff --git a/lib/igt_dummyload.h b/lib/igt_dummyload.h index 215425f7..ffa7e351 100644 --- a/lib/igt_dummyload.h +++ b/lib/igt_dummyload.h @@ -35,6 +35,7 @@ typedef struct igt_spin { timer_t timer; struct igt_list link; uint32_t *batch; + int out_fence; } igt_spin_t; igt_spin_t *__igt_spin_batch_new(int fd, @@ -45,6 +46,15 @@ igt_spin_t *igt_spin_batch_new(int fd, uint32_t ctx, unsigned engine, uint32_t dep); + +igt_spin_t *__igt_spin_batch_new_fence(int fd, + uint32_t ctx, + unsigned engine); + +igt_spin_t *igt_spin_batch_new_fence(int fd, + uint32_t ctx, + unsigned engine); + void igt_spin_batch_set_timeout(igt_spin_t *spin, int64_t ns); void igt_spin_batch_end(igt_spin_t *spin); void igt_spin_batch_free(int fd, igt_spin_t *spin); -- cgit v1.2.3