MLK-11917-1 media: output: pxp_v4l2: remove some duplicate dead code
authorFancy Fang <chen.fang@freescale.com>
Mon, 30 Nov 2015 02:19:35 +0000 (10:19 +0800)
committerNitin Garg <nitin.garg@nxp.com>
Mon, 19 Mar 2018 19:49:16 +0000 (14:49 -0500)
The code slice in the 'v4l2_fmt_to_pxp_fmt()' function:
"
        else if (v4l2_pix_fmt == V4L2_PIX_FMT_RGB555)
                pxp_fmt = PXP_PIX_FMT_RGB555;
"
appears twice continuously. And the second code slice
will become dead code which is never executed. So
remove the second one.

Signed-off-by: Fancy Fang <chen.fang@freescale.com>
drivers/media/platform/mxc/output/mxc_pxp_v4l2.c

index 005bb92..7d89d32 100644 (file)
@@ -110,8 +110,6 @@ static unsigned int v4l2_fmt_to_pxp_fmt(u32 v4l2_pix_fmt)
                pxp_fmt = PXP_PIX_FMT_RGB565;
        else if (v4l2_pix_fmt == V4L2_PIX_FMT_RGB555)
                pxp_fmt = PXP_PIX_FMT_RGB555;
-       else if (v4l2_pix_fmt == V4L2_PIX_FMT_RGB555)
-               pxp_fmt = PXP_PIX_FMT_RGB555;
        else if (v4l2_pix_fmt == V4L2_PIX_FMT_YUV420)
                pxp_fmt = PXP_PIX_FMT_YUV420P;
        else if (v4l2_pix_fmt == V4L2_PIX_FMT_YUV422P)