diff options
author | Amitoj Kaur Chawla <amitoj1606@gmail.com> | 2017-07-10 15:27:28 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@s-opensource.com> | 2017-07-19 16:26:57 -0400 |
commit | 05f1d92f2b68386a66086b08fc6257c1c143b7ac (patch) | |
tree | 5192520da63d134313974da8612a992e152823da /drivers/staging/media/atomisp/pci/atomisp2/atomisp_internal.h | |
parent | e19902225473529c8b84579930fe66156cd1f258 (diff) | |
download | linux-05f1d92f2b68386a66086b08fc6257c1c143b7ac.tar.bz2 |
media: staging: atomisp: Use kvfree() instead of kfree()/vfree()
Conditionally calling kfree()/vfree() can be replaced by a call to
kvfree() which handles both kmalloced memory and vmalloced memory.
The resulting wrapper function has been replaced with direct calls
to kvfree().
This change was made with the help of the following Coccinelle
semantic patch:
//<smpl>
@@
expression a;
@@
- if(...) { vfree(a); }
- else { kfree(a); }
+ kvfree(a);
// </smpl>
Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'drivers/staging/media/atomisp/pci/atomisp2/atomisp_internal.h')
-rw-r--r-- | drivers/staging/media/atomisp/pci/atomisp2/atomisp_internal.h | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/staging/media/atomisp/pci/atomisp2/atomisp_internal.h b/drivers/staging/media/atomisp/pci/atomisp2/atomisp_internal.h index d3667132851b..afced4f4eb6a 100644 --- a/drivers/staging/media/atomisp/pci/atomisp2/atomisp_internal.h +++ b/drivers/staging/media/atomisp/pci/atomisp2/atomisp_internal.h @@ -312,8 +312,6 @@ extern struct device *atomisp_dev; extern void *atomisp_kernel_malloc(size_t bytes); -extern void atomisp_kernel_free(void *ptr); - #define atomisp_is_wdt_running(a) timer_pending(&(a)->wdt) #ifdef ISP2401 extern void atomisp_wdt_refresh_pipe(struct atomisp_video_pipe *pipe, |