gfxstream: guest: add experimental fence passing APIs
This uses the new fence passing APIs provided by kumquat. Reviewed-by: Aaron Ruby <aruby@blackberry.com> Acked-by: Yonggang Luo <luoyonggang@gmail.com> Acked-by: Adam Jackson <ajax@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27246>
This commit is contained in:

committed by
Marge Bot

parent
a1bdf71d8e
commit
6c0ce98cb0
@@ -44,14 +44,18 @@ enum VirtGpuParamId : uint32_t {
|
||||
kParamContextInit = 5,
|
||||
kParamSupportedCapsetIds = 6,
|
||||
kParamExplicitDebugName = 7,
|
||||
kParamCreateGuestHandle = 8,
|
||||
kParamMax = 9,
|
||||
// Experimental, not in upstream Linux
|
||||
kParamFencePassing = 8,
|
||||
kParamCreateGuestHandle = 9,
|
||||
kParamMax = 10,
|
||||
};
|
||||
|
||||
enum VirtGpuExecBufferFlags : uint32_t {
|
||||
kFenceIn = 0x0001,
|
||||
kFenceOut = 0x0002,
|
||||
kRingIdx = 0x0004,
|
||||
kShareableIn = 0x0008,
|
||||
kShareableOut = 0x0010,
|
||||
};
|
||||
|
||||
enum VirtGpuCapset {
|
||||
|
@@ -44,6 +44,7 @@ VirtGpuKumquatDevice::VirtGpuKumquatDevice(enum VirtGpuCapset capset, int fd)
|
||||
PARAM(VIRTGPU_KUMQUAT_PARAM_CONTEXT_INIT),
|
||||
PARAM(VIRTGPU_KUMQUAT_PARAM_SUPPORTED_CAPSET_IDs),
|
||||
PARAM(VIRTGPU_KUMQUAT_PARAM_EXPLICIT_DEBUG_NAME),
|
||||
PARAM(VIRTGPU_KUMQUAT_PARAM_FENCE_PASSING),
|
||||
PARAM(VIRTGPU_KUMQUAT_PARAM_CREATE_GUEST_HANDLE),
|
||||
};
|
||||
|
||||
|
@@ -31,6 +31,9 @@
|
||||
#include "virtgpu_drm.h"
|
||||
#include "virtgpu_gfxstream_protocol.h"
|
||||
|
||||
#define VIRTGPU_PARAM_CREATE_FENCE_PASSING 9 /* Fence passing */
|
||||
#define VIRTGPU_PARAM_CREATE_GUEST_HANDLE 10 /* Host OS handle can be created from guest memory. */
|
||||
|
||||
#define PARAM(x) \
|
||||
(struct VirtGpuParam) { x, #x, 0 }
|
||||
|
||||
@@ -42,6 +45,7 @@ LinuxVirtGpuDevice::LinuxVirtGpuDevice(enum VirtGpuCapset capset, int fd) : Virt
|
||||
PARAM(VIRTGPU_PARAM_RESOURCE_BLOB), PARAM(VIRTGPU_PARAM_HOST_VISIBLE),
|
||||
PARAM(VIRTGPU_PARAM_CROSS_DEVICE), PARAM(VIRTGPU_PARAM_CONTEXT_INIT),
|
||||
PARAM(VIRTGPU_PARAM_SUPPORTED_CAPSET_IDs), PARAM(VIRTGPU_PARAM_EXPLICIT_DEBUG_NAME),
|
||||
PARAM(VIRTGPU_PARAM_CREATE_FENCE_PASSING),
|
||||
PARAM(VIRTGPU_PARAM_CREATE_GUEST_HANDLE),
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user