diff options
author | Joonyoung Shim <jy0922.shim@samsung.com> | 2013-06-28 07:24:54 +0200 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2013-07-05 07:44:49 +0200 |
commit | 78467dc5f70fb9bee4a32c0c3714c99b0b5465c7 (patch) | |
tree | fe5b399e17578e2a819083df5d7e0fee11df4027 /include/drm | |
parent | drm: add mmap function to prime helpers (diff) | |
download | linux-78467dc5f70fb9bee4a32c0c3714c99b0b5465c7.tar.xz linux-78467dc5f70fb9bee4a32c0c3714c99b0b5465c7.zip |
drm/cma: add low-level hook functions to use prime helpers
Instead of using the dma_buf functionality for GEM CMA, we can use prime
helpers if we can provide low-level hook functions for GEM CMA.
Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'include/drm')
-rw-r--r-- | include/drm/drm_gem_cma_helper.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/drm/drm_gem_cma_helper.h b/include/drm/drm_gem_cma_helper.h index 6e17251e9b28..9d39d2a51906 100644 --- a/include/drm/drm_gem_cma_helper.h +++ b/include/drm/drm_gem_cma_helper.h @@ -54,4 +54,13 @@ struct dma_buf *drm_gem_cma_dmabuf_export(struct drm_device *drm_dev, struct drm_gem_object *drm_gem_cma_dmabuf_import(struct drm_device *drm_dev, struct dma_buf *dma_buf); +struct sg_table *drm_gem_cma_prime_get_sg_table(struct drm_gem_object *obj); +struct drm_gem_object * +drm_gem_cma_prime_import_sg_table(struct drm_device *dev, size_t size, + struct sg_table *sgt); +int drm_gem_cma_prime_mmap(struct drm_gem_object *obj, + struct vm_area_struct *vma); +void *drm_gem_cma_prime_vmap(struct drm_gem_object *obj); +void drm_gem_cma_prime_vunmap(struct drm_gem_object *obj, void *vaddr); + #endif /* __DRM_GEM_CMA_HELPER_H__ */ |