radv: Skip wait timeline ioctl with 0 handles.

Fixes: 55d8022878 "radv: Add winsys functions for timeline syncobj."
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14165>
This commit is contained in:
Bas Nieuwenhuizen 2021-12-12 01:01:55 +01:00 committed by Marge Bot
parent afff9dd0f0
commit 20b51cdabe

View file

@ -4875,8 +4875,12 @@ wait_for_submission_timelines_available(struct radv_deferred_queue_submission *s
points[syncobj_idx] = submission->wait_values[i]; points[syncobj_idx] = submission->wait_values[i];
++syncobj_idx; ++syncobj_idx;
} }
bool success = device->ws->wait_timeline_syncobj(device->ws, syncobj, points, syncobj_idx, true,
true, timeout); bool success = true;
if (syncobj_idx > 0) {
success = device->ws->wait_timeline_syncobj(device->ws, syncobj, points, syncobj_idx, true,
true, timeout);
}
free(points); free(points);
return success ? VK_SUCCESS : VK_TIMEOUT; return success ? VK_SUCCESS : VK_TIMEOUT;