From 7e0853c9c717f8e1ce6ed7f0d2fa6bd973bd0f6a Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Wed, 27 Jan 2016 14:17:53 +0000 Subject: [PATCH] igt/gem_exec_nop: Use common array of rings Signed-off-by: Chris Wilson --- tests/gem_exec_nop.c | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/tests/gem_exec_nop.c b/tests/gem_exec_nop.c index f8a4e8d7..81c13775 100644 --- a/tests/gem_exec_nop.c +++ b/tests/gem_exec_nop.c @@ -82,6 +82,7 @@ static void loop(int fd, uint32_t handle, unsigned ring_id, const char *ring_nam igt_main { + const struct intel_execution_engine *e; uint32_t handle = 0; igt_fixture { @@ -90,17 +91,9 @@ igt_main gem_write(device, handle, 0, batch, sizeof(batch)); } - igt_subtest("render") - loop(device, handle, I915_EXEC_RENDER, "render"); - - igt_subtest("bsd") - loop(device, handle, I915_EXEC_BSD, "bsd"); - - igt_subtest("blt") - loop(device, handle, I915_EXEC_BLT, "blt"); - - igt_subtest("vebox") - loop(device, handle, LOCAL_I915_EXEC_VEBOX, "vebox"); + for (e = intel_execution_engines; e->name; e++) + igt_subtest_f("%s", e->name) + loop(device, handle, e->exec_id | e->flags, e->name); igt_fixture { gem_close(device, handle);