diff options
| author | Krishna Reddy <vdumpa@nvidia.com> | 2013-09-25 17:01:45 -0400 |
|---|---|---|
| committer | Dan Willemsen <dwillemsen@nvidia.com> | 2015-03-18 15:06:25 -0400 |
| commit | bba815d481b8efcf6f13bb4dd9917c3b5e4c9507 (patch) | |
| tree | 9bf69106b4eac48eedbcc600b3e092e454777f4e /include/linux/nvmap.h | |
| parent | a0fffd92bd4fb972a13de12c4d80b58a24094cee (diff) | |
video: tegra: nvmap: remove obsolete NvMap API
remove obsolete NvMap API nvmap_mmap/_munmap/_kmap/_kunmap,
nvmap_sg_table/_free_sg_table/_set_host_private/_get_host_private,
nvmap_flush_deferred_cache/duplicate_handle_user_id and
nvmap_get_handle_user_id/_put_handle_user_id.
remove unused macros as well from public header.
Change-Id: Ib8ceacb892a8a648543b4ce1b86f2331aa0d5190
Signed-off-by: Krishna Reddy <vdumpa@nvidia.com>
Reviewed-on: http://git-master/r/279025
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
(cherry picked from commit 7c46dee98669e2b08b5e5f72b0be93c9a82c0f5d)
Signed-off-by: Ajay Nandakumar <anandakumarm@nvidia.com>
Diffstat (limited to 'include/linux/nvmap.h')
| -rw-r--r-- | include/linux/nvmap.h | 58 |
1 files changed, 0 insertions, 58 deletions
diff --git a/include/linux/nvmap.h b/include/linux/nvmap.h index 2b230e3a8..f72e7433b 100644 --- a/include/linux/nvmap.h +++ b/include/linux/nvmap.h | |||
| @@ -57,30 +57,9 @@ struct nvmap_handle_ref; | |||
| 57 | 57 | ||
| 58 | #if defined(__KERNEL__) | 58 | #if defined(__KERNEL__) |
| 59 | 59 | ||
| 60 | #if defined(CONFIG_TEGRA_NVMAP) | ||
| 61 | struct nvmap_client; | 60 | struct nvmap_client; |
| 62 | struct nvmap_device; | 61 | struct nvmap_device; |
| 63 | 62 | ||
| 64 | /* Convert User space handle to Kernel. */ | ||
| 65 | #define nvmap_convert_handle_u2k(h) (h) | ||
| 66 | |||
| 67 | #elif defined(CONFIG_ION_TEGRA) | ||
| 68 | /* For Ion Mem Manager support through nvmap_* API's. */ | ||
| 69 | #include "../../../../../drivers/gpu/ion/ion_priv.h" | ||
| 70 | #define nvmap_client ion_client | ||
| 71 | #define nvmap_device ion_device | ||
| 72 | #define nvmap_handle ion_handle | ||
| 73 | #define nvmap_handle_ref ion_handle | ||
| 74 | /* Convert User space handle to Kernel. */ | ||
| 75 | #define nvmap_convert_handle_u2k(h) ({ \ | ||
| 76 | if ((u32)h >= TASK_SIZE) { \ | ||
| 77 | pr_err("Invalid user space handle."); \ | ||
| 78 | BUG(); \ | ||
| 79 | } \ | ||
| 80 | (*((u32 *)h)); }) | ||
| 81 | |||
| 82 | #endif /* CONFIG_ION_TEGRA */ | ||
| 83 | |||
| 84 | struct nvmap_client *nvmap_create_client(struct nvmap_device *dev, | 63 | struct nvmap_client *nvmap_create_client(struct nvmap_device *dev, |
| 85 | const char *name); | 64 | const char *name); |
| 86 | 65 | ||
| @@ -100,15 +79,6 @@ ulong nvmap_dmabuf_to_user_id(struct dma_buf *dmabuf); | |||
| 100 | 79 | ||
| 101 | phys_addr_t nvmap_get_addr_from_user_id(ulong user_id); | 80 | phys_addr_t nvmap_get_addr_from_user_id(ulong user_id); |
| 102 | 81 | ||
| 103 | void *nvmap_mmap(struct nvmap_handle_ref *r); | ||
| 104 | |||
| 105 | void nvmap_munmap(struct nvmap_handle_ref *r, void *addr); | ||
| 106 | |||
| 107 | void *nvmap_kmap(struct nvmap_handle_ref *r, unsigned int pagenum); | ||
| 108 | |||
| 109 | void nvmap_kunmap(struct nvmap_handle_ref *r, unsigned int pagenum, | ||
| 110 | void *addr); | ||
| 111 | |||
| 112 | struct nvmap_client *nvmap_client_get_file(int fd); | 82 | struct nvmap_client *nvmap_client_get_file(int fd); |
| 113 | 83 | ||
| 114 | struct nvmap_client *nvmap_client_get(struct nvmap_client *client); | 84 | struct nvmap_client *nvmap_client_get(struct nvmap_client *client); |
| @@ -123,28 +93,6 @@ phys_addr_t nvmap_handle_address_user_id(struct nvmap_client *c, | |||
| 123 | 93 | ||
| 124 | void nvmap_unpin(struct nvmap_client *client, struct nvmap_handle_ref *r); | 94 | void nvmap_unpin(struct nvmap_client *client, struct nvmap_handle_ref *r); |
| 125 | 95 | ||
| 126 | struct nvmap_handle_ref *nvmap_duplicate_handle_user_id( | ||
| 127 | struct nvmap_client *client, | ||
| 128 | unsigned long user_id); | ||
| 129 | |||
| 130 | ulong nvmap_get_handle_user_id(struct nvmap_client *client, | ||
| 131 | unsigned long id); | ||
| 132 | |||
| 133 | void nvmap_put_handle_user_id(ulong user_id); | ||
| 134 | |||
| 135 | /* | ||
| 136 | * Create a sg_table struct from the pages allocated for a handle. Note that | ||
| 137 | * this does not increment refcount of the handle, so keep a reference to the | ||
| 138 | * buffer for as long as you use the sg_table. | ||
| 139 | */ | ||
| 140 | struct sg_table *nvmap_sg_table(struct nvmap_client *client, | ||
| 141 | struct nvmap_handle_ref *ref); | ||
| 142 | void nvmap_free_sg_table(struct nvmap_client *client, | ||
| 143 | struct nvmap_handle_ref *ref, struct sg_table *sgt); | ||
| 144 | void nvmap_set_nvhost_private(struct nvmap_handle_ref *ref, void *priv, | ||
| 145 | void (*delete)(void *priv)); | ||
| 146 | void *nvmap_get_nvhost_private(struct nvmap_handle_ref *ref); | ||
| 147 | |||
| 148 | struct sg_table *nvmap_dmabuf_sg_table(struct dma_buf *dmabuf); | 96 | struct sg_table *nvmap_dmabuf_sg_table(struct dma_buf *dmabuf); |
| 149 | void nvmap_dmabuf_free_sg_table(struct dma_buf *dmabuf, struct sg_table *sgt); | 97 | void nvmap_dmabuf_free_sg_table(struct dma_buf *dmabuf, struct sg_table *sgt); |
| 150 | 98 | ||
| @@ -152,12 +100,6 @@ void nvmap_set_dmabuf_private(struct dma_buf *dmabuf, void *priv, | |||
| 152 | void (*delete)(void *priv)); | 100 | void (*delete)(void *priv)); |
| 153 | void *nvmap_get_dmabuf_private(struct dma_buf *dmabuf); | 101 | void *nvmap_get_dmabuf_private(struct dma_buf *dmabuf); |
| 154 | 102 | ||
| 155 | /* | ||
| 156 | * Flush cache maintenance operations for the handle that have been deferred. | ||
| 157 | * Use this if you don't use nvmap_pin for mapping the buffer to IOVA. | ||
| 158 | */ | ||
| 159 | void nvmap_flush_deferred_cache(struct nvmap_client *client, | ||
| 160 | struct nvmap_handle_ref *ref); | ||
| 161 | int nvmap_get_handle_param(struct nvmap_client *client, | 103 | int nvmap_get_handle_param(struct nvmap_client *client, |
| 162 | struct nvmap_handle_ref *ref, u32 param, u64 *result); | 104 | struct nvmap_handle_ref *ref, u32 param, u64 *result); |
| 163 | 105 | ||
