]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commitdiff
media: atomisp: make function calls cleaner
authorMauro Carvalho Chehab <mchehab@s-opensource.com>
Tue, 31 Oct 2017 15:54:07 +0000 (11:54 -0400)
committerMauro Carvalho Chehab <mchehab@s-opensource.com>
Wed, 1 Nov 2017 16:25:55 +0000 (12:25 -0400)
The #ifs inside the code makes confusing for reviewers and also
cause problems with smatch:
drivers/staging/media/atomisp/pci/atomisp2/atomisp_ioctl.c:2937:1: error: directive in argument list
drivers/staging/media/atomisp/pci/atomisp2/atomisp_ioctl.c:2939:1: error: directive in argument list
drivers/staging/media/atomisp/pci/atomisp2/atomisp_ioctl.c:2941:1: error: directive in argument list

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Acked-by: Sakari Ailus <sakari.ailus@iki.fi>
drivers/staging/media/atomisp/pci/atomisp2/atomisp_ioctl.c

index 8698f8f758ca285e4682252e0965a4097649f0ab..339b5d31e1f1591a0cbcb03c64cc7b80dc979396 100644 (file)
@@ -2933,13 +2933,15 @@ static long atomisp_vidioc_default(struct file *file, void *fh,
 #else
                if (isp->motor)
 #endif
-                       err = v4l2_subdev_call(
 #ifndef ISP2401
+                       err = v4l2_subdev_call(
                                        isp->inputs[asd->input_curr].motor,
+                                       core, ioctl, cmd, arg);
 #else
+                       err = v4l2_subdev_call(
                                        isp->motor,
-#endif
                                        core, ioctl, cmd, arg);
+#endif
                else
                        err = v4l2_subdev_call(
                                        isp->inputs[asd->input_curr].camera,