zink: only get swapchain present semaphore on batch flush if not presented
otherwise this has already been present-waited and can just be used whenever Reviewed-by: Dave Airlie <airlied@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15820>
This commit is contained in:
parent
21496dea9c
commit
b3ee943050
|
@ -497,7 +497,7 @@ zink_end_batch(struct zink_context *ctx, struct zink_batch *batch)
|
||||||
batch->work_count = 0;
|
batch->work_count = 0;
|
||||||
|
|
||||||
if (batch->swapchain) {
|
if (batch->swapchain) {
|
||||||
if (batch->swapchain->obj->acquired) {
|
if (batch->swapchain->obj->acquired && !batch->swapchain->obj->present) {
|
||||||
batch->state->present = zink_kopper_present(screen, batch->swapchain);
|
batch->state->present = zink_kopper_present(screen, batch->swapchain);
|
||||||
batch->state->swapchain = batch->swapchain;
|
batch->state->swapchain = batch->swapchain;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue