freedreno/drm/virtio: Use userspace IOVA allocation

If supported by host virglrenderer and host kernel, use userspace
allocated GPU virtual addresses.  This lets us avoid stalling on
waiting for response from host kernel until we need to know the
host handle (which is usually not until submit time).

Handling the async response from host to get host_handle is done
thru the submit_queue, so that in the submit path (hot) we do not
need any additional synchronization to know that the host_handle
is valid.

Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16086>
This commit is contained in:
Rob Clark
2022-03-22 16:14:19 -07:00
committed by Marge Bot
parent ae01c27ac0
commit e6b2785811
10 changed files with 341 additions and 35 deletions
+3
View File
@@ -18,6 +18,9 @@ struct virgl_renderer_capset_drm {
union {
struct {
uint32_t has_cached_coherent;
uint32_t priorities;
uint64_t va_start;
uint64_t va_size;
} msm; /* context_type == VIRTGPU_DRM_CONTEXT_MSM */
} u;
};