summaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorKrishna Reddy <vdumpa@nvidia.com>2013-08-27 17:15:03 -0400
committerDan Willemsen <dwillemsen@nvidia.com>2015-03-18 15:05:58 -0400
commit6ea3836d7add4892ffa6cf3dbed0164af1a80a99 (patch)
tree5d36b21c8654b87c4017d6e63f4bb3bedad7b96a /include/linux
parent6f8a611a94d8b8864759e66e0a9d66b0605b4612 (diff)
video: tegra: nvmap: add api's that take dmabuf
add api's that take dmabuf instead of nvmap_handle_ref. these are necessary for nvhost to start using dmabuf. Bug 1356091 Change-Id: I61c74641f2c013e4aa9812aabf2a6f558fdf1fcf Signed-off-by: Krishna Reddy <vdumpa@nvidia.com> Reviewed-on: http://git-master/r/266897 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/nvmap.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/linux/nvmap.h b/include/linux/nvmap.h
index 6ed486ccb..25f413116 100644
--- a/include/linux/nvmap.h
+++ b/include/linux/nvmap.h
@@ -97,6 +97,8 @@ struct dma_buf *nvmap_dmabuf_export_from_ref(struct nvmap_handle_ref *ref);
97 97
98ulong nvmap_ref_to_user_id(struct nvmap_handle_ref *ref); 98ulong nvmap_ref_to_user_id(struct nvmap_handle_ref *ref);
99 99
100ulong nvmap_dmabuf_to_user_id(struct dma_buf *dmabuf);
101
100phys_addr_t nvmap_get_addr_from_user_id(ulong user_id); 102phys_addr_t nvmap_get_addr_from_user_id(ulong user_id);
101 103
102void nvmap_free(struct nvmap_client *client, struct nvmap_handle_ref *r); 104void nvmap_free(struct nvmap_client *client, struct nvmap_handle_ref *r);
@@ -155,6 +157,14 @@ void nvmap_free_sg_table(struct nvmap_client *client,
155void nvmap_set_nvhost_private(struct nvmap_handle_ref *ref, void *priv, 157void nvmap_set_nvhost_private(struct nvmap_handle_ref *ref, void *priv,
156 void (*delete)(void *priv)); 158 void (*delete)(void *priv));
157void *nvmap_get_nvhost_private(struct nvmap_handle_ref *ref); 159void *nvmap_get_nvhost_private(struct nvmap_handle_ref *ref);
160
161struct sg_table *nvmap_dmabuf_sg_table(struct dma_buf *dmabuf);
162void nvmap_dmabuf_free_sg_table(struct dma_buf *dmabuf, struct sg_table *sgt);
163
164void nvmap_set_dmabuf_private(struct dma_buf *dmabuf, void *priv,
165 void (*delete)(void *priv));
166void *nvmap_get_dmabuf_private(struct dma_buf *dmabuf);
167
158/* 168/*
159 * Flush cache maintenance operations for the handle that have been deferred. 169 * Flush cache maintenance operations for the handle that have been deferred.
160 * Use this if you don't use nvmap_pin for mapping the buffer to IOVA. 170 * Use this if you don't use nvmap_pin for mapping the buffer to IOVA.