mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 09:18:04 +02:00
pipebuffer: Wait for the GPU to finish reading too.
No real change, as we're not tracking relocations read/write access yet.
This commit is contained in:
parent
802a5ff507
commit
2c1d40a051
1 changed files with 4 additions and 3 deletions
|
|
@ -296,9 +296,10 @@ fenced_buffer_map(struct pb_buffer *buf,
|
|||
assert(!(flags & ~PIPE_BUFFER_USAGE_CPU_READ_WRITE));
|
||||
flags &= PIPE_BUFFER_USAGE_CPU_READ_WRITE;
|
||||
|
||||
/* Check for GPU read/write access */
|
||||
if(fenced_buf->flags & PIPE_BUFFER_USAGE_GPU_WRITE) {
|
||||
/* Wait for the GPU to finish writing */
|
||||
/* Serialize writes */
|
||||
if((fenced_buf->flags & PIPE_BUFFER_USAGE_GPU_WRITE) ||
|
||||
((fenced_buf->flags & PIPE_BUFFER_USAGE_GPU_READ) && (flags & PIPE_BUFFER_USAGE_CPU_WRITE))) {
|
||||
/* Wait for the GPU to finish */
|
||||
_fenced_buffer_finish(fenced_buf);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue