media: atomisp: pci: remove unneeded variable 'err'
Subsystems (4)
PATCH 1/1 media: atomisp: pci: remove unneeded variable 'err'
Fix the following coccicheck warning:
drivers/staging/media/atomisp/pci/sh_css_mipi.c:39:5-8:
Unneeded variable: "err". Return "0" on line 44
--- drivers/staging/media/atomisp/pci/sh_css_mipi.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/staging/media/atomisp/pci/sh_css_mipi.c +1 -2
@@ -36,12 +36,11 @@ ref_count_mipi_allocation[N_CSI_PORTS]; /* Initialized in mipi_init */int ia_css_mipi_frame_specify (const unsigned int size_mem_words,const bool contiguous) { -int err =0 ; my_css.size_mem_words = size_mem_words; (void )contiguous; -return err; +return 0 ; }/*
Signature · 1 line
2.25.1
Quoted 32 lines · Saurav Girepunje
Fix the following coccicheck warning:
drivers/staging/media/atomisp/pci/sh_css_mipi.c:39:5-8:
Unneeded variable: "err". Return "0" on line 44Signed-off-by Saurav Girepunje <[email protected]>--- drivers/staging/media/atomisp/pci/sh_css_mipi.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)drivers/staging/media/atomisp/pci/sh_css_mipi.c +1
-2@@ -36,12 +36,11 @@ ref_count_mipi_allocation[N_CSI_PORTS]; /* Initialized in mipi_init */int ia_css_mipi_frame_specify (const unsigned int size_mem_words,const bool contiguous) { -int err =0 ; my_css.size_mem_words = size_mem_words; (void )contiguous; -return err; +return 0 ; }/* Signature · 1 line
2.25.1
Hi Saurav,
this ia_css_mipi_frame_specify seems to be unused. On header file, before the prototype it is said that it could be removed only when all drivers moved to a new API.
Is that comment obsolete?
thank you,
fabio
Re: [PATCH] media: atomisp: pci: remove unneeded variable 'err'[email protected],
Quoted 40 lines · Fabio Aiuto
Quoted 32 lines · Saurav Girepunje
Fix the following coccicheck warning:
drivers/staging/media/atomisp/pci/sh_css_mipi.c:39:5-8:
Unneeded variable: "err". Return "0" on line 44Signed-off-by Saurav Girepunje <[email protected]>--- drivers/staging/media/atomisp/pci/sh_css_mipi.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)drivers/staging/media/atomisp/pci/sh_css_mipi.c +1
-2@@ -36,12 +36,11 @@ ref_count_mipi_allocation[N_CSI_PORTS]; /* Initialized in mipi_init */int ia_css_mipi_frame_specify (const unsigned int size_mem_words,const bool contiguous) { -int err =0 ; my_css.size_mem_words = size_mem_words; (void )contiguous; -return err; +return 0 ; }/* Signature · 1 line
2.25.1Hi Saurav,
this
ia_css_mipi_frame_specifyseems to be unused. On header file, before the prototype it is said that it could be removed only when all drivers moved to a new API.
Quoted 5 lines
Is that comment obsolete?
thank you,
fabio
yes this ia_css_mipi_frame_specify is unused. On header file
/* Backward compatible for CSS API 2.0 only
* TO BE REMOVED when all drivers move to CSS API 2.1. */
deprecated{Use ia_css_mipi_buffer_config instead.}
new api also suggested on comment.
saurav