mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 04:38:03 +02:00
venus: fix empty submits with BOs
Empty submits with BOs (!batch_count && bo_count) were incorrectly skipped. Signed-off-by: Chia-I Wu <olvaffe@gmail.com> Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11791>
This commit is contained in:
parent
80c45928b4
commit
d0fa4933b7
1 changed files with 11 additions and 0 deletions
|
|
@ -542,6 +542,17 @@ sim_submit(struct virtgpu *gpu, const struct vn_renderer_submit *submit)
|
|||
}
|
||||
}
|
||||
|
||||
if (!submit->batch_count && submit->bo_count) {
|
||||
struct drm_virtgpu_execbuffer args = {
|
||||
.bo_handles = (uintptr_t)gem_handles,
|
||||
.num_bo_handles = submit->bo_count,
|
||||
};
|
||||
|
||||
ret = drmIoctl(gpu->fd, DRM_IOCTL_VIRTGPU_EXECBUFFER, &args);
|
||||
if (ret)
|
||||
vn_log(gpu->instance, "failed to execbuffer: %s", strerror(errno));
|
||||
}
|
||||
|
||||
free(gem_handles);
|
||||
|
||||
return ret;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue