summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorErik Faye-Lund <[email protected]>2018-12-11 11:16:35 +0000
committerErik Faye-Lund <[email protected]>2018-12-13 16:12:10 +0100
commit00143a62418687d388a0563b3044e2fd82d18e2e (patch)
treee14a9e0bfe4e99b2c0752afc60fd5f18afd2e55a /src
parent0991085f6634e9de08c2a63cbb2cd837cb216ddb (diff)
virgl: simplify virgl_hw_set_vertex_buffers
Signed-off-by: Erik Faye-Lund <[email protected]> Reviewed-by: Mathias Fröhlich <[email protected]> Tested-By: Gert Wollny <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/gallium/drivers/virgl/virgl_context.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/gallium/drivers/virgl/virgl_context.c b/src/gallium/drivers/virgl/virgl_context.c
index f0ee64c1457..b03e9508c61 100644
--- a/src/gallium/drivers/virgl/virgl_context.c
+++ b/src/gallium/drivers/virgl/virgl_context.c
@@ -425,10 +425,8 @@ static void virgl_set_vertex_buffers(struct pipe_context *ctx,
vctx->vertex_array_dirty = TRUE;
}
-static void virgl_hw_set_vertex_buffers(struct pipe_context *ctx)
+static void virgl_hw_set_vertex_buffers(struct virgl_context *vctx)
{
- struct virgl_context *vctx = virgl_context(ctx);
-
if (vctx->vertex_array_dirty) {
virgl_encoder_set_vertex_buffers(vctx, vctx->num_vertex_buffers, vctx->vertex_buffer);
virgl_attach_res_vertex_buffers(vctx);
@@ -700,7 +698,7 @@ static void virgl_draw_vbo(struct pipe_context *ctx,
u_upload_unmap(vctx->uploader);
vctx->num_draws++;
- virgl_hw_set_vertex_buffers(ctx);
+ virgl_hw_set_vertex_buffers(vctx);
if (info.index_size)
virgl_hw_set_index_buffer(ctx, &ib);