aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/exynos/exynos_drm_buf.h
diff options
context:
space:
mode:
authorInki Dae <inki.dae@samsung.com>2012-03-16 05:47:05 -0400
committerDave Airlie <airlied@redhat.com>2012-03-20 05:40:21 -0400
commit2b35892e9da672df40ce890bffc4f9f6119c57e0 (patch)
tree89c7faa07c4ffd583d08f83c0ddf7f8b7da01f76 /drivers/gpu/drm/exynos/exynos_drm_buf.h
parent1de425b0bdbc457dbd4a012760da4a3f204d0ab3 (diff)
drm/exynos: update gem and buffer framework.
with this patch, we can allocate physically continuous or non-continuous memory and also it creates scatterlist for iommu support so allocated memory region can be mapped to iommu page table using scatterlist. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/exynos/exynos_drm_buf.h')
-rw-r--r--drivers/gpu/drm/exynos/exynos_drm_buf.h22
1 files changed, 16 insertions, 6 deletions
diff --git a/drivers/gpu/drm/exynos/exynos_drm_buf.h b/drivers/gpu/drm/exynos/exynos_drm_buf.h
index c913f2bad760..3388e4eb4ba2 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_buf.h
+++ b/drivers/gpu/drm/exynos/exynos_drm_buf.h
@@ -26,12 +26,22 @@
26#ifndef _EXYNOS_DRM_BUF_H_ 26#ifndef _EXYNOS_DRM_BUF_H_
27#define _EXYNOS_DRM_BUF_H_ 27#define _EXYNOS_DRM_BUF_H_
28 28
29/* allocate physical memory. */ 29/* create and initialize buffer object. */
30struct exynos_drm_gem_buf *exynos_drm_buf_create(struct drm_device *dev, 30struct exynos_drm_gem_buf *exynos_drm_init_buf(struct drm_device *dev,
31 unsigned int size); 31 unsigned int size);
32 32
33/* remove allocated physical memory. */ 33/* destroy buffer object. */
34void exynos_drm_buf_destroy(struct drm_device *dev, 34void exynos_drm_fini_buf(struct drm_device *dev,
35 struct exynos_drm_gem_buf *buffer); 35 struct exynos_drm_gem_buf *buffer);
36
37/* allocate physical memory region and setup sgt and pages. */
38int exynos_drm_alloc_buf(struct drm_device *dev,
39 struct exynos_drm_gem_buf *buf,
40 unsigned int flags);
41
42/* release physical memory region, sgt and pages. */
43void exynos_drm_free_buf(struct drm_device *dev,
44 unsigned int flags,
45 struct exynos_drm_gem_buf *buffer);
36 46
37#endif 47#endif