summaryrefslogtreecommitdiff
path: root/src/gallium/winsys/svga/drm/vmw_screen_dri.c
diff options
context:
space:
mode:
authorChristopher James Halse Rogers <raof@ubuntu.com>2013-11-21 15:11:39 +1100
committerMaarten Lankhorst <maarten.lankhorst@canonical.com>2013-12-10 09:46:05 +0100
commitd5a3a2d2fbc42da04ff7ea09356ada134a42d6dd (patch)
tree78713128416960253fd27072b8197f598e91dd13 /src/gallium/winsys/svga/drm/vmw_screen_dri.c
parent343133167f4ae127a375791790c982bde12025c4 (diff)
gallium/winsys/drm: Prepare for passing prime fds in winsys_handle
Signed-off-by: Christopher James Halse Rogers <christopher.halse.rogers@canonical.com> Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Diffstat (limited to 'src/gallium/winsys/svga/drm/vmw_screen_dri.c')
-rw-r--r--src/gallium/winsys/svga/drm/vmw_screen_dri.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gallium/winsys/svga/drm/vmw_screen_dri.c b/src/gallium/winsys/svga/drm/vmw_screen_dri.c
index 511cca73aea..6323a8ae2c4 100644
--- a/src/gallium/winsys/svga/drm/vmw_screen_dri.c
+++ b/src/gallium/winsys/svga/drm/vmw_screen_dri.c
@@ -163,6 +163,12 @@ vmw_drm_surface_from_handle(struct svga_winsys_screen *sws,
int ret;
int i;
+ if (whandle->type != DRM_API_HANDLE_TYPE_SHARED) {
+ vmw_error("Attempt to import unknown handle type %d\n",
+ whandle->type);
+ return NULL;
+ }
+
/**
* The vmware device specific handle is the hardware SID.
* FIXME: We probably want to move this to the ioctl implementations.