diff options
author | Shalaj Jain <shalajj@codeaurora.org> | 2014-09-10 15:51:58 -0700 |
---|---|---|
committer | David Keitel <dkeitel@codeaurora.org> | 2016-03-22 11:04:09 -0700 |
commit | 117c202b36dbe5191213d670250183fd43d1f4e6 (patch) | |
tree | dd9278f1a9d8e2469fe38bd7a2ce50705b64375b | |
parent | f29d7e7e0e574372fe6c6b6feb07f020914744e6 (diff) |
ion: Remove secure and unsecure buffer APIs
These APIs are deprecated as securing and unsecuring for secure
buffers is done on allocation and free respectively by the secure
heap layer. Clients don't have to call these explicitly.
Change-Id: If88cd1c47cba346446ebdcad494850b54ba954ab
Signed-off-by: Shalaj Jain <shalajj@codeaurora.org>
[mitchelh: dropped all client changes (since they're not in yet)]
Signed-off-by: Mitchel Humpherys <mitchelh@codeaurora.org>
-rw-r--r-- | drivers/staging/android/ion/msm/msm_ion.h | 35 | ||||
-rw-r--r-- | drivers/staging/android/ion/msm/secure_buffer.c | 41 |
2 files changed, 0 insertions, 76 deletions
diff --git a/drivers/staging/android/ion/msm/msm_ion.h b/drivers/staging/android/ion/msm/msm_ion.h index 3bb7bd074f6b..8db7945e9060 100644 --- a/drivers/staging/android/ion/msm/msm_ion.h +++ b/drivers/staging/android/ion/msm/msm_ion.h @@ -150,27 +150,6 @@ int ion_handle_get_size(struct ion_client *client, struct ion_handle *handle, int msm_ion_do_cache_op(struct ion_client *client, struct ion_handle *handle, void *vaddr, unsigned long len, unsigned int cmd); -/** - * msm_ion_secure_buffer - secure an individual buffer - * - * @client - client who has access to the buffer - * @handle - buffer to secure - * @usage - usage hint to TZ - * @flags - flags for the securing - */ -int msm_ion_secure_buffer(struct ion_client *client, struct ion_handle *handle, - enum cp_mem_usage usage, int flags); - -/** - * msm_ion_unsecure_buffer - unsecure an individual buffer - * - * @client - client who has access to the buffer - * @handle - buffer to secure - */ -int msm_ion_unsecure_buffer(struct ion_client *client, - struct ion_handle *handle); - - int msm_ion_secure_table(struct sg_table *table, enum cp_mem_usage usage, int flags); @@ -194,20 +173,6 @@ static inline int msm_ion_do_cache_op(struct ion_client *client, return -ENODEV; } -static inline int msm_ion_secure_buffer(struct ion_client *client, - struct ion_handle *handle, - enum cp_mem_usage usage, - int flags) -{ - return -ENODEV; -} - -static inline int msm_ion_unsecure_buffer(struct ion_client *client, - struct ion_handle *handle) -{ - return -ENODEV; -} - static inline int msm_ion_secure_table(struct sg_table *table, enum cp_mem_usage usage, int flags) diff --git a/drivers/staging/android/ion/msm/secure_buffer.c b/drivers/staging/android/ion/msm/secure_buffer.c index 83c0b80497da..1e108c281c43 100644 --- a/drivers/staging/android/ion/msm/secure_buffer.c +++ b/drivers/staging/android/ion/msm/secure_buffer.c @@ -235,25 +235,6 @@ out: } -int msm_ion_secure_buffer(struct ion_client *client, struct ion_handle *handle, - enum cp_mem_usage usage, int flags) -{ - struct sg_table *table; - int ret; - - table = ion_sg_table(client, handle); - - if (IS_ERR_OR_NULL(table)) { - ret = -EINVAL; - goto out; - } - - ret = msm_ion_secure_table(table, usage, flags); -out: - return ret; -} -EXPORT_SYMBOL(msm_ion_secure_buffer); - static void msm_secure_buffer_release(struct kref *kref) { struct secure_meta *meta = container_of(kref, struct secure_meta, @@ -285,28 +266,6 @@ out: } -int msm_ion_unsecure_buffer(struct ion_client *client, - struct ion_handle *handle) -{ - struct sg_table *table; - int ret = 0; - - table = ion_sg_table(client, handle); - - if (IS_ERR_OR_NULL(table)) { - WARN(1, "Could not get table for handle %p to unsecure\n", - handle); - ret = -EINVAL; - goto out; - } - - msm_ion_unsecure_table(table); - -out: - return ret; -} -EXPORT_SYMBOL(msm_ion_unsecure_buffer); - #define MAKE_CP_VERSION(major, minor, patch) \ (((major & 0x3FF) << 22) | ((minor & 0x3FF) << 12) | (patch & 0xFFF)) |