summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authorMathias Fröhlich <[email protected]>2018-11-01 19:03:26 +0100
committerMathias Fröhlich <[email protected]>2018-11-26 07:57:09 +0100
commit774d585d492d9666fc5d6c09b7868064000c96d8 (patch)
tree7f9d9c6e578b6cf04d73ce2f3368b97c66fccf75 /src/mesa
parent65332aff29b26ce2cf277e4c753eb53844038e1e (diff)
mesa/st: Only unmap the uploader that was actually used.
In st_atom_array, we only need to unmap the upload buffer that was actually used. Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Mathias Fröhlich <[email protected]>
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/state_tracker/st_atom_array.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/state_tracker/st_atom_array.c b/src/mesa/state_tracker/st_atom_array.c
index 9831045b340..cd00529ddf3 100644
--- a/src/mesa/state_tracker/st_atom_array.c
+++ b/src/mesa/state_tracker/st_atom_array.c
@@ -499,7 +499,8 @@ st_update_array(struct st_context *st)
&vbuffer[bufidx].buffer_offset,
&vbuffer[bufidx].buffer.resource);
- if (!ctx->Const.AllowMappedBuffersDuringExecution) {
+ if (!ctx->Const.AllowMappedBuffersDuringExecution &&
+ !st->can_bind_const_buffer_as_vertex) {
u_upload_unmap(st->pipe->stream_uploader);
}
}