summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCharmaine Lee <charmainel@vmware.com>2019-05-07 14:07:50 -0700
committerDylan Baker <dylan@pnwbakers.com>2019-06-20 10:04:47 -0700
commitae0caaf194397927858fbb3628ddb277f2ba90cb (patch)
treeb00474169d376f41bf990db8f9a5d32150b5107c
parent6f37df66229d441d4257f51abd69d12358a00627 (diff)
downloadmesa-ae0caaf194397927858fbb3628ddb277f2ba90cb.tar.gz
svga: Remove unnecessary check for the pre flush bit for setting vertex buffers
This fixes the missing rebind when the can_pre_flush bit is not set and the vertex buffers are the same as what have been sent. Cc: mesa-stable@lists.freedesktop.org Reviewed-by: Neha Bhende <bhenden@vmware.com> Signed-off-by: Charmaine Lee <charmainel@vmware.com> Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> (cherry picked from commit f29b8fde915728134b2e2b912642fe573d405fcb)
-rw-r--r--src/gallium/drivers/svga/svga_draw.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/gallium/drivers/svga/svga_draw.c b/src/gallium/drivers/svga/svga_draw.c
index 649bc228c07..c68f12f5333 100644
--- a/src/gallium/drivers/svga/svga_draw.c
+++ b/src/gallium/drivers/svga/svga_draw.c
@@ -619,11 +619,11 @@ draw_vgpu10(struct svga_hwtnl *hwtnl,
vbuffer_attrs[i].sid = 0;
}
- /* If we haven't yet emitted a drawing command or if any
- * vertex buffer state is changing, issue that state now.
+ /* If any of the vertex buffer state has changed, issue
+ * the SetVertexBuffers command. Otherwise, we will just
+ * need to rebind the resources.
*/
- if (((hwtnl->cmd.swc->hints & SVGA_HINT_FLAG_CAN_PRE_FLUSH) == 0) ||
- vbuf_count != svga->state.hw_draw.num_vbuffers ||
+ if (vbuf_count != svga->state.hw_draw.num_vbuffers ||
!vertex_buffers_equal(vbuf_count,
vbuffer_attrs,
vbuffers,