zink: move 'acquired' flag onto swapchain struct

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17149>
This commit is contained in:
Mike Blumenkrantz
2022-06-21 10:59:55 -04:00
committed by Marge Bot
parent c47378fb0f
commit 92228a6d28
5 changed files with 17 additions and 10 deletions

View File

@@ -469,7 +469,7 @@ zink_end_batch(struct zink_context *ctx, struct zink_batch *batch)
batch->work_count = 0;
if (batch->swapchain) {
if (batch->swapchain->obj->acquired && !batch->swapchain->obj->present) {
if (zink_kopper_acquired(batch->swapchain->obj->dt, batch->swapchain->obj->dt_idx) && !batch->swapchain->obj->present) {
batch->state->present = zink_kopper_present(screen, batch->swapchain);
batch->state->swapchain = batch->swapchain;
}