aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/uvc
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2011-03-06 06:32:04 -0500
committerMauro Carvalho Chehab <mchehab@redhat.com>2011-05-20 08:30:38 -0400
commit507910799160e85eac5e7729e0d2f1ba26f6a8cf (patch)
treee21dd07da18bbc706742ca20c6a68e0103945273 /drivers/media/video/uvc
parentfb08a5cd57bfd6daf90a850c8081d6805a8b9900 (diff)
[media] uvcvideo: Add support for V4L2_PIX_FMT_RGB565
The TomTom navigation system used in the Sony XNV 660BT and 770BT reports an RGB565 (RGBP) format, support it in the driver. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/uvc')
-rw-r--r--drivers/media/video/uvc/uvc_driver.c5
-rw-r--r--drivers/media/video/uvc/uvcvideo.h3
2 files changed, 8 insertions, 0 deletions
diff --git a/drivers/media/video/uvc/uvc_driver.c b/drivers/media/video/uvc/uvc_driver.c
index 6459b8cba223..61e5137dbcb7 100644
--- a/drivers/media/video/uvc/uvc_driver.c
+++ b/drivers/media/video/uvc/uvc_driver.c
@@ -103,6 +103,11 @@ static struct uvc_format_desc uvc_fmts[] = {
103 .guid = UVC_GUID_FORMAT_BY8, 103 .guid = UVC_GUID_FORMAT_BY8,
104 .fcc = V4L2_PIX_FMT_SBGGR8, 104 .fcc = V4L2_PIX_FMT_SBGGR8,
105 }, 105 },
106 {
107 .name = "RGB565",
108 .guid = UVC_GUID_FORMAT_RGBP,
109 .fcc = V4L2_PIX_FMT_RGB565,
110 },
106}; 111};
107 112
108/* ------------------------------------------------------------------------ 113/* ------------------------------------------------------------------------
diff --git a/drivers/media/video/uvc/uvcvideo.h b/drivers/media/video/uvc/uvcvideo.h
index 18d76679d952..cd58ea81320b 100644
--- a/drivers/media/video/uvc/uvcvideo.h
+++ b/drivers/media/video/uvc/uvcvideo.h
@@ -176,6 +176,9 @@ struct uvc_xu_control_query {
176#define UVC_GUID_FORMAT_BY8 \ 176#define UVC_GUID_FORMAT_BY8 \
177 { 'B', 'Y', '8', ' ', 0x00, 0x00, 0x10, 0x00, \ 177 { 'B', 'Y', '8', ' ', 0x00, 0x00, 0x10, 0x00, \
178 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71} 178 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71}
179#define UVC_GUID_FORMAT_RGBP \
180 { 'R', 'G', 'B', 'P', 0x00, 0x00, 0x10, 0x00, \
181 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71}
179 182
180/* ------------------------------------------------------------------------ 183/* ------------------------------------------------------------------------
181 * Driver specific constants. 184 * Driver specific constants.