zink: add batch api for adding a wait semaphore

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17066>
This commit is contained in:
Mike Blumenkrantz 2022-06-10 15:28:18 -04:00 committed by Marge Bot
parent 48b56d2efd
commit 285a5144cc
2 changed files with 9 additions and 0 deletions

View file

@ -523,6 +523,12 @@ zink_batch_reference_resource_rw(struct zink_batch *batch, struct zink_resource
zink_batch_resource_usage_set(batch, res, write);
}
void
zink_batch_add_wait_semaphore(struct zink_batch *batch, VkSemaphore sem)
{
util_dynarray_append(&batch->state->acquires, VkSemaphore, sem);
}
bool
batch_ptr_add_usage(struct zink_batch *batch, struct set *s, void *ptr)
{

View file

@ -179,6 +179,9 @@ zink_start_batch(struct zink_context *ctx, struct zink_batch *batch);
void
zink_end_batch(struct zink_context *ctx, struct zink_batch *batch);
void
zink_batch_add_wait_semaphore(struct zink_batch *batch, VkSemaphore sem);
void
zink_batch_resource_usage_set(struct zink_batch *batch, struct zink_resource *res, bool write);