soc: qcom: Make qcom_smem_get() return a pointer
Passing a void ** almost always requires a cast at the call site. Instead of littering the code with casts every time this function is called, have qcom_smem_get() return a void pointer to the location of the smem item. This frees the caller from having to cast the pointer. Cc: Bjorn Andersson <bjorn.andersson@sonymobile.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org> Reviewed-by: Bjorn Andersson <bjorn.andersson@sonymobile.com> Signed-off-by: Andy Gross <agross@codeaurora.org>
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
#define QCOM_SMEM_HOST_ANY -1
|
||||
|
||||
int qcom_smem_alloc(unsigned host, unsigned item, size_t size);
|
||||
int qcom_smem_get(unsigned host, unsigned item, void **ptr, size_t *size);
|
||||
void *qcom_smem_get(unsigned host, unsigned item, size_t *size);
|
||||
|
||||
int qcom_smem_get_free_space(unsigned host);
|
||||
|
||||
|
Reference in New Issue
Block a user