From: Ricardo Ribalda Date: Mon, 4 May 2015 08:07:32 +0000 (-0300) Subject: [media] media/vivid: Code cleanout X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=ed1bc664daf58af7da47581fe43d42b95a1de65a;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git [media] media/vivid: Code cleanout Remove code duplication by merging two cases in a switch. Signed-off-by: Ricardo Ribalda Delgado Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/platform/vivid/vivid-tpg.c b/drivers/media/platform/vivid/vivid-tpg.c index 9e50303a19c5..af4bc9780099 100644 --- a/drivers/media/platform/vivid/vivid-tpg.c +++ b/drivers/media/platform/vivid/vivid-tpg.c @@ -293,6 +293,7 @@ bool tpg_s_fourcc(struct tpg_data *tpg, u32 fourcc) } switch (fourcc) { + case V4L2_PIX_FMT_GREY: case V4L2_PIX_FMT_RGB332: tpg->twopixelsize[0] = 2; break; @@ -331,9 +332,6 @@ bool tpg_s_fourcc(struct tpg_data *tpg, u32 fourcc) case V4L2_PIX_FMT_YUV32: tpg->twopixelsize[0] = 2 * 4; break; - case V4L2_PIX_FMT_GREY: - tpg->twopixelsize[0] = 2; - break; case V4L2_PIX_FMT_NV12: case V4L2_PIX_FMT_NV21: case V4L2_PIX_FMT_NV12M: