]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commitdiff
staging: atomisp: remove useless condition in if-statements
authorDaeseok Youn <daeseok.youn@gmail.com>
Tue, 21 Mar 2017 02:12:57 +0000 (11:12 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 21 Mar 2017 07:39:58 +0000 (08:39 +0100)
The css_pipe_id was checked with 'CSS_PIPE_ID_COPY' in previous if-
statement. In this case, if the css_pipe_id equals to 'CSS_PIPE_ID_COPY',
it could not enter the next if-statement. But the "next" if-statement
has the condition to check whether the css_pipe_id equals to
'CSS_PIPE_ID_COPY' or not. It should be removed.

Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c

index 9d44a1dd220ae6b2b2b9af4af06b20b279d4a3f7..94bc7938f533c63e521c7d4fd623557825ae6449 100644 (file)
@@ -903,8 +903,7 @@ static struct atomisp_video_pipe *__atomisp_get_pipe(
        } else if (asd->run_mode->val == ATOMISP_RUN_MODE_VIDEO) {
                /* For online video or SDV video pipe. */
                if (css_pipe_id == CSS_PIPE_ID_VIDEO ||
-                   css_pipe_id == CSS_PIPE_ID_COPY ||
-                   css_pipe_id == CSS_PIPE_ID_YUVPP) {
+                   css_pipe_id == CSS_PIPE_ID_COPY) {
                        if (buf_type == CSS_BUFFER_TYPE_OUTPUT_FRAME)
                                return &asd->video_out_video_capture;
                        return &asd->video_out_preview;
@@ -912,8 +911,7 @@ static struct atomisp_video_pipe *__atomisp_get_pipe(
        } else if (asd->run_mode->val == ATOMISP_RUN_MODE_PREVIEW) {
                /* For online preview or ZSL preview pipe. */
                if (css_pipe_id == CSS_PIPE_ID_PREVIEW ||
-                   css_pipe_id == CSS_PIPE_ID_COPY ||
-                   css_pipe_id == CSS_PIPE_ID_YUVPP)
+                   css_pipe_id == CSS_PIPE_ID_COPY)
                        return &asd->video_out_preview;
        }
        /* For capture pipe. */