diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2016-07-18 10:04:51 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2016-07-18 10:25:56 +0100 |
commit | 3d8f55c3e0b4545a6385a44094a70e68e071a49c (patch) | |
tree | 56cc855e24a0e62502871df5602a225565b3d945 /lib/igt_vgem.c | |
parent | ee5d5c47c44183f3ab7d6493c0e7c41556e34e73 (diff) |
igt/vgem_slow: Test for the expected -ETIMEDOUT upon fence timeout
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'lib/igt_vgem.c')
-rw-r--r-- | lib/igt_vgem.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/lib/igt_vgem.c b/lib/igt_vgem.c index 66557913..81c5a3b7 100644 --- a/lib/igt_vgem.c +++ b/lib/igt_vgem.c @@ -155,7 +155,7 @@ uint32_t vgem_fence_attach(int fd, struct vgem_bo *bo, unsigned flags) return arg.out_fence; } -static int __vgem_fence_signal(int fd, struct local_vgem_fence_signal *arg) +static int ioctl_vgem_fence_signal(int fd, struct local_vgem_fence_signal *arg) { int err = 0; if (igt_ioctl(fd, LOCAL_IOCTL_VGEM_FENCE_SIGNAL, arg)) @@ -164,11 +164,17 @@ static int __vgem_fence_signal(int fd, struct local_vgem_fence_signal *arg) return err; } -void vgem_fence_signal(int fd, uint32_t fence) +int __vgem_fence_signal(int fd, uint32_t fence) { struct local_vgem_fence_signal arg; memset(&arg, 0, sizeof(arg)); arg.fence = fence; - igt_assert_eq(__vgem_fence_signal(fd, &arg), 0); + + return ioctl_vgem_fence_signal(fd, &arg); +} + +void vgem_fence_signal(int fd, uint32_t fence) +{ + igt_assert_eq(__vgem_fence_signal(fd, fence), 0); } |