summaryrefslogtreecommitdiff
path: root/tests/prime_vgem.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/prime_vgem.c')
-rw-r--r--tests/prime_vgem.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/tests/prime_vgem.c b/tests/prime_vgem.c
index e78e074a..5f8a4dd5 100644
--- a/tests/prime_vgem.c
+++ b/tests/prime_vgem.c
@@ -629,7 +629,7 @@ static void flip_to_vgem(int i915, int vgem,
const char *name)
{
const struct timespec tv = { 1, 0 };
- struct pollfd pfd;
+ struct pollfd pfd = { i915, POLLIN };
struct drm_event_vblank vbl;
uint32_t fence;
@@ -641,8 +641,6 @@ static void flip_to_vgem(int i915, int vgem,
kill(getppid(), SIGHUP);
/* Check we don't flip before the fence is ready */
- pfd.fd = i915;
- pfd.events = POLLIN;
for (int n = 0; n < 5; n++) {
igt_assert_f(poll(&pfd, 1, 0) == 0,
"flip to %s completed whilst busy\n",