From 772563b27c9f5cb0e19bf6c5fb4383a86e3347e3 Mon Sep 17 00:00:00 2001 From: "NĂ­colas F. R. A. Prado" Date: Fri, 1 May 2020 15:11:12 +0200 Subject: media: vimc: Add missing {RGB,BGR,GBR}888 media bus codes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add missing RGB888_*, BGR888_* and GBR888_* media bus codes in the vimc_pix_map_list. Since there is no GBR24 pixelformat, use the RGB24 pixelformat for MEDIA_BUS_FMT_GBR888_1X24. Acked-by: Helen Koike Co-developed-by: Vitor Massaru Iha Signed-off-by: Vitor Massaru Iha Signed-off-by: NĂ­colas F. R. A. Prado Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab --- drivers/media/test-drivers/vimc/vimc-common.c | 16 ++++++++++++++-- drivers/media/test-drivers/vimc/vimc-common.h | 2 +- 2 files changed, 15 insertions(+), 3 deletions(-) (limited to 'drivers/media/test-drivers/vimc') diff --git a/drivers/media/test-drivers/vimc/vimc-common.c b/drivers/media/test-drivers/vimc/vimc-common.c index 24dcc28854c8..7b27153c0728 100644 --- a/drivers/media/test-drivers/vimc/vimc-common.c +++ b/drivers/media/test-drivers/vimc/vimc-common.c @@ -19,13 +19,25 @@ static const struct vimc_pix_map vimc_pix_map_list[] = { /* RGB formats */ { - .code = { MEDIA_BUS_FMT_BGR888_1X24 }, + .code = { + MEDIA_BUS_FMT_BGR888_1X24, + MEDIA_BUS_FMT_BGR888_3X8 + }, .pixelformat = V4L2_PIX_FMT_BGR24, .bpp = 3, .bayer = false, }, { - .code = { MEDIA_BUS_FMT_RGB888_1X24 }, + .code = { + MEDIA_BUS_FMT_RGB888_1X24, + MEDIA_BUS_FMT_RGB888_2X12_BE, + MEDIA_BUS_FMT_RGB888_2X12_LE, + MEDIA_BUS_FMT_RGB888_3X8, + MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, + MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA, + MEDIA_BUS_FMT_RGB888_1X32_PADHI, + MEDIA_BUS_FMT_GBR888_1X24 + }, .pixelformat = V4L2_PIX_FMT_RGB24, .bpp = 3, .bayer = false, diff --git a/drivers/media/test-drivers/vimc/vimc-common.h b/drivers/media/test-drivers/vimc/vimc-common.h index 1b5fbedae656..ae163dec2459 100644 --- a/drivers/media/test-drivers/vimc/vimc-common.h +++ b/drivers/media/test-drivers/vimc/vimc-common.h @@ -32,7 +32,7 @@ #define VIMC_IS_SRC(pad) (pad) #define VIMC_IS_SINK(pad) (!(pad)) -#define VIMC_PIX_FMT_MAX_CODES 1 +#define VIMC_PIX_FMT_MAX_CODES 8 /** * vimc_colorimetry_clamp - Adjust colorimetry parameters -- cgit v1.2.3