diff mbox

[i-g-t,2/8] tests/gem_ctx_switch: Tune down for BAT ~1s.

Message ID 1464349838-9959-2-git-send-email-marius.c.vlad@intel.com (mailing list archive)
State New, archived
Headers show

Commit Message

Marius Vlad May 27, 2016, 11:50 a.m. UTC
Signed-off-by: Marius Vlad <marius.c.vlad@intel.com>
---
 tests/gem_ctx_switch.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

Chris Wilson May 27, 2016, noon UTC | #1
On Fri, May 27, 2016 at 02:50:32PM +0300, Marius Vlad wrote:
> Signed-off-by: Marius Vlad <marius.c.vlad@intel.com>

Nak. Please suggest how to improve reliablity first.
-Chris
diff mbox

Patch

diff --git a/tests/gem_ctx_switch.c b/tests/gem_ctx_switch.c
index 7b27336..066a5fc 100644
--- a/tests/gem_ctx_switch.c
+++ b/tests/gem_ctx_switch.c
@@ -73,6 +73,7 @@  static void single(int fd, uint32_t handle,
 	struct drm_i915_gem_exec_object2 obj;
 	struct drm_i915_gem_relocation_entry reloc;
 	uint32_t contexts[64];
+	uint32_t timeout = 1;
 	int n;
 
 	gem_require_ring(fd, e->exec_id | e->flags);
@@ -125,7 +126,7 @@  static void single(int fd, uint32_t handle,
 				count += 1024;
 			}
 			clock_gettime(CLOCK_MONOTONIC, &now);
-		} while (elapsed(&start, &now) < 20.);
+		} while (elapsed(&start, &now) < timeout);
 		gem_sync(fd, handle);
 		clock_gettime(CLOCK_MONOTONIC, &now);