From eabe87de4652126480e2211d9c088a8eabea2c8a Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Tue, 10 Oct 2017 18:13:41 +0100 Subject: igt/syncobj_wait: Close the sw_sync timeline after the test Closing the sw_sync timeline now signals any remaining fences upon it; but test_wait_interrupted requires the fence to be busy for the __syncobj_wait() not to immediately return with -ETIME (and so be interrupted instead). Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=103187 References: ea4d5a270b57 ("dma-buf/sw_sync: force signal all unsignaled fences on dying timeline") Signed-off-by: Chris Wilson Cc: Jason Ekstrand Cc: Dave Airlie Reviewed-by: Jason Ekstrand --- tests/syncobj_wait.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests/syncobj_wait.c') diff --git a/tests/syncobj_wait.c b/tests/syncobj_wait.c index 78ed1fc5..5fd37808 100644 --- a/tests/syncobj_wait.c +++ b/tests/syncobj_wait.c @@ -726,13 +726,13 @@ test_wait_interrupted(int fd, uint32_t test_flags) } timeline = syncobj_attach_sw_sync(fd, syncobj); - close(timeline); wait.timeout_nsec = short_timeout(); igt_while_interruptible(true) igt_assert_eq(__syncobj_wait(fd, &wait), -ETIME); syncobj_destroy(fd, syncobj); + close(timeline); } static bool -- cgit v1.2.3