summaryrefslogtreecommitdiff
path: root/tests/gem_fenced_exec_thrash.c
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2013-09-12 14:21:56 +0200
committerDaniel Vetter <daniel.vetter@ffwll.ch>2013-09-17 00:13:47 +0200
commit14e12b80085db3ab9d9035ce962b5679fe862570 (patch)
tree48da9732c0f766297bac54464cb2cf45bf91baba /tests/gem_fenced_exec_thrash.c
parentdeba86806670e28bfd8110ef5b6e05ab818b1935 (diff)
tests/*: scrap get_num_fences
Just use gem_available_fences directly. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'tests/gem_fenced_exec_thrash.c')
-rw-r--r--tests/gem_fenced_exec_thrash.c15
1 files changed, 2 insertions, 13 deletions
diff --git a/tests/gem_fenced_exec_thrash.c b/tests/gem_fenced_exec_thrash.c
index 58b2545b..125b77c8 100644
--- a/tests/gem_fenced_exec_thrash.c
+++ b/tests/gem_fenced_exec_thrash.c
@@ -84,18 +84,6 @@ batch_create (int fd)
return batch_handle;
}
-static int get_num_fences(int fd)
-{
- int val;
-
- val = gem_available_fences(fd);
-
- printf ("total %d fences\n", val);
- igt_assert(val > 4);
-
- return val;
-}
-
static void fill_reloc(struct drm_i915_gem_relocation_entry *reloc, uint32_t handle)
{
reloc->offset = 2 * sizeof(uint32_t);
@@ -165,7 +153,8 @@ main(int argc, char **argv)
igt_skip_on_simulation();
fd = drm_open_any();
- num_fences = get_num_fences(fd);
+ num_fences = gem_available_fences(fd);
+ igt_assert(num_fences > 4);
devid = intel_get_drm_devid(fd);
igt_assert(num_fences <= MAX_FENCES);