mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-22 09:10:11 +01:00
st/mesa: Deal with empty textures/buffers in semaphore wait/signal.
The actual texture might not have been created yet. Gitlab: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3257 CC: mesa-stable Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com> Reviewed-by: Marek Olšák <marek.olsak@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6788>
This commit is contained in:
parent
08add9f61c
commit
ade72e677b
1 changed files with 8 additions and 4 deletions
|
|
@ -109,7 +109,8 @@ st_server_wait_semaphore(struct gl_context *ctx,
|
|||
continue;
|
||||
|
||||
bufObj = st_buffer_object(bufObjs[i]);
|
||||
pipe->flush_resource(pipe, bufObj->buffer);
|
||||
if (bufObj->buffer)
|
||||
pipe->flush_resource(pipe, bufObj->buffer);
|
||||
}
|
||||
|
||||
for (unsigned i = 0; i < numTextureBarriers; i++) {
|
||||
|
|
@ -117,7 +118,8 @@ st_server_wait_semaphore(struct gl_context *ctx,
|
|||
continue;
|
||||
|
||||
texObj = st_texture_object(texObjs[i]);
|
||||
pipe->flush_resource(pipe, texObj->pt);
|
||||
if (texObj->pt)
|
||||
pipe->flush_resource(pipe, texObj->pt);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -141,7 +143,8 @@ st_server_signal_semaphore(struct gl_context *ctx,
|
|||
continue;
|
||||
|
||||
bufObj = st_buffer_object(bufObjs[i]);
|
||||
pipe->flush_resource(pipe, bufObj->buffer);
|
||||
if (bufObj->buffer)
|
||||
pipe->flush_resource(pipe, bufObj->buffer);
|
||||
}
|
||||
|
||||
for (unsigned i = 0; i < numTextureBarriers; i++) {
|
||||
|
|
@ -149,7 +152,8 @@ st_server_signal_semaphore(struct gl_context *ctx,
|
|||
continue;
|
||||
|
||||
texObj = st_texture_object(texObjs[i]);
|
||||
pipe->flush_resource(pipe, texObj->pt);
|
||||
if (texObj->pt)
|
||||
pipe->flush_resource(pipe, texObj->pt);
|
||||
}
|
||||
|
||||
/* The driver is allowed to flush during fence_server_signal, be prepared */
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue