Commit 83faf22c authored by Marc-André Lureau's avatar Marc-André Lureau Committed by Dave Airlie
Browse files

tests: reset last fence before using it


Signed-off-by: default avatarMarc-André Lureau <marcandre.lureau@gmail.com>
Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
parent aa340240
......@@ -430,6 +430,7 @@ START_TEST(virgl_test_render_simple)
virgl_renderer_submit_cmd(ctx.cbuf->buf, ctx.ctx_id, ctx.cbuf->cdw);
/* create a fence */
testvirgl_reset_fence();
ret = virgl_renderer_create_fence(1, ctx.ctx_id);
ck_assert_int_eq(ret, 0);
......@@ -686,6 +687,7 @@ START_TEST(virgl_test_render_geom_simple)
virgl_renderer_submit_cmd(ctx.cbuf->buf, ctx.ctx_id, ctx.cbuf->cdw);
/* create a fence */
testvirgl_reset_fence();
ret = virgl_renderer_create_fence(1, ctx.ctx_id);
ck_assert_int_eq(ret, 0);
......@@ -930,6 +932,7 @@ START_TEST(virgl_test_render_xfb)
virgl_renderer_submit_cmd(ctx.cbuf->buf, ctx.ctx_id, ctx.cbuf->cdw);
/* create a fence */
testvirgl_reset_fence();
ret = virgl_renderer_create_fence(1, ctx.ctx_id);
ck_assert_int_eq(ret, 0);
......
......@@ -104,6 +104,11 @@ uint32_t testvirgl_get_last_fence(void)
return testvirgl_last_fence;
}
void testvirgl_reset_fence(void)
{
testvirgl_last_fence = 0;
}
int testvirgl_init_single_ctx(void)
{
int ret;
......
......@@ -65,6 +65,7 @@ void testvirgl_init_single_ctx_nr(void);
void testvirgl_fini_single_ctx(void);
uint32_t testvirgl_get_last_fence(void);
void testvirgl_reset_fence(void);
int testvirgl_init_ctx_cmdbuf(struct virgl_context *ctx);
void testvirgl_fini_ctx_cmdbuf(struct virgl_context *ctx);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment