summaryrefslogtreecommitdiffstats
path: root/src/gallium/winsys/svga/drm
diff options
context:
space:
mode:
authorSinclair Yeh <[email protected]>2017-05-15 15:25:31 -0700
committerBrian Paul <[email protected]>2017-07-17 10:09:25 -0600
commit2431cccad1ec8d3fd75f2aec657ce1e57a194ab3 (patch)
treed690558a3a664df9a1f64f58a239e49cc6445dc2 /src/gallium/winsys/svga/drm
parent65175df601003f5ba29dc9c088952f6454adc0d6 (diff)
winsys/svga/drm: Prepare to support fence fd
Make the fields and flags available. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Charmaine Lee <[email protected]>
Diffstat (limited to 'src/gallium/winsys/svga/drm')
-rw-r--r--src/gallium/winsys/svga/drm/vmwgfx_drm.h11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/gallium/winsys/svga/drm/vmwgfx_drm.h b/src/gallium/winsys/svga/drm/vmwgfx_drm.h
index 807ec901ad5..13d779494fb 100644
--- a/src/gallium/winsys/svga/drm/vmwgfx_drm.h
+++ b/src/gallium/winsys/svga/drm/vmwgfx_drm.h
@@ -294,13 +294,17 @@ union drm_vmw_surface_reference_arg {
* @version: Allows expanding the execbuf ioctl parameters without breaking
* backwards compatibility, since user-space will always tell the kernel
* which version it uses.
- * @flags: Execbuf flags. None currently.
+ * @flags: Execbuf flags.
+ * @imported_fence_fd: FD for a fence imported from another device
*
* Argument to the DRM_VMW_EXECBUF Ioctl.
*/
#define DRM_VMW_EXECBUF_VERSION 2
+#define DRM_VMW_EXECBUF_FLAG_IMPORT_FENCE_FD (1 << 0)
+#define DRM_VMW_EXECBUF_FLAG_EXPORT_FENCE_FD (1 << 1)
+
struct drm_vmw_execbuf_arg {
uint64_t commands;
uint32_t command_size;
@@ -309,7 +313,7 @@ struct drm_vmw_execbuf_arg {
uint32_t version;
uint32_t flags;
uint32_t context_handle;
- uint32_t pad64;
+ int32_t imported_fence_fd;
};
/**
@@ -325,6 +329,7 @@ struct drm_vmw_execbuf_arg {
* @passed_seqno: The highest seqno number processed by the hardware
* so far. This can be used to mark user-space fence objects as signaled, and
* to determine whether a fence seqno might be stale.
+ * @fd: FD associated with the fence, -1 if not exported
* @error: This member should've been set to -EFAULT on submission.
* The following actions should be take on completion:
* error == -EFAULT: Fence communication failed. The host is synchronized.
@@ -342,7 +347,7 @@ struct drm_vmw_fence_rep {
uint32_t mask;
uint32_t seqno;
uint32_t passed_seqno;
- uint32_t pad64;
+ int32_t fd;
int32_t error;
};