Skip to contentSkip to conversation

staging: media: atomisp: pci: runtime: debug: src: remove curly braces for single line if

PATCH In review Johts 2 participants 2 messages Apr 23

Subsystems (4)
lore
Share & tools
lore

Johts

author
#0 lore raw

PATCH 1/1 staging: media: atomisp: pci: runtime: debug: src: remove curly braces for single line if

Fix checkpath error "WARNING: braces {} are not necessary for single statement blocks" in sh_css_params.c:1931

---
 drivers/staging/media/atomisp/pci/sh_css_params.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/staging/media/atomisp/pci/sh_css_params.c +2 -4
index fcebace11daf..31426001864e 100644
@@ -1928,10 +1928,8 @@ sh_css_set_per_frame_isp_config_on_pipe(
 	params = stream->per_frame_isp_params_configs;
 
 	/* update new ISP params object with the new config */
-	if (!sh_css_init_isp_params_from_global(stream, params, false, pipe)) {
-		err1 = -EINVAL;
-	}
-
+	if (!sh_css_init_isp_params_from_global(stream, params, false, pipe))	err1 = -EINVAL;
+	
 	err2 = sh_css_init_isp_params_from_config(stream->pipes[0], params, config, pipe);
 
 	if (per_frame_config_created) {
Signature · 1 line
2.43.0
reviewer
#1 lore raw

Hi Johts,

Quoted 3 lines · Johts

Fix checkpath error "WARNING: braces {} are not necessary for single statement blocks" in sh_css_params.c:1931

We need a more specific name here.

Quoted 9 lines
---
 drivers/staging/media/atomisp/pci/sh_css_params.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/staging/media/atomisp/pci/sh_css_params.c +0 -0
index fcebace11daf..31426001864e 100644

drivers/staging/media/atomisp/pci/sh_css_params.c sh_css_set_per_frame_isp_config_on_pipe( · line 1931

Quoted 8 lines
drivers/staging/media/atomisp/pci/sh_css_params.c +1 -4
@@ -1928,10 +1928,8 @@ sh_css_set_per_frame_isp_config_on_pipe(
 	params = stream->per_frame_isp_params_configs;
 
 	/* update new ISP params object with the new config */
-	if (!sh_css_init_isp_params_from_global(stream, params, false, pipe)) {
-		err1 = -EINVAL;
-	}
-
+	if (!sh_css_init_isp_params_from_global(stream, params, false, pipe))	err1 = -EINVAL;

Please run checkpatch.pl on this.

Quoted 4 lines
drivers/staging/media/atomisp/pci/sh_css_params.c +1 -0
+	
 	err2 = sh_css_init_isp_params_from_config(stream->pipes[0], params, config, pipe);
 
 	if (per_frame_config_created) {
Signature · 3 lines
Regards,

Sakari Ailus