summaryrefslogtreecommitdiff
path: root/drivers/media/usb
diff options
context:
space:
mode:
authorHans Verkuil <hans.verkuil@cisco.com>2012-09-13 05:37:11 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2013-03-05 14:25:57 -0300
commitfddd14c8f6ca2bb9bfdad1874c172002bc537527 (patch)
treedacdea2d4d2dfb3f7cb5f6aa784a5f9250708caf /drivers/media/usb
parent4bc837d414c36676499220065143743d720bf40f (diff)
[media] cx231xx: add required VIDIOC_DBG_G_CHIP_IDENT support
This fixes a v4l2_compliance failure. [mchehab@redhat.com: CodingStyle fixes] Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/usb')
-rw-r--r--drivers/media/usb/cx231xx/cx231xx-video.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/media/usb/cx231xx/cx231xx-video.c b/drivers/media/usb/cx231xx/cx231xx-video.c
index ffeedcd2448b..1b29158bbbe2 100644
--- a/drivers/media/usb/cx231xx/cx231xx-video.c
+++ b/drivers/media/usb/cx231xx/cx231xx-video.c
@@ -1456,6 +1456,19 @@ static int vidioc_s_frequency(struct file *file, void *priv,
return rc;
}
+static int vidioc_g_chip_ident(struct file *file, void *fh,
+ struct v4l2_dbg_chip_ident *chip)
+{
+ chip->ident = V4L2_IDENT_NONE;
+ chip->revision = 0;
+ if (chip->match.type == V4L2_CHIP_MATCH_HOST) {
+ if (v4l2_chip_match_host(&chip->match))
+ chip->ident = V4L2_IDENT_CX23100;
+ return 0;
+ }
+ return -EINVAL;
+}
+
#ifdef CONFIG_VIDEO_ADV_DEBUG
/*
@@ -2514,6 +2527,7 @@ static const struct v4l2_ioctl_ops video_ioctl_ops = {
.vidioc_s_tuner = vidioc_s_tuner,
.vidioc_g_frequency = vidioc_g_frequency,
.vidioc_s_frequency = vidioc_s_frequency,
+ .vidioc_g_chip_ident = vidioc_g_chip_ident,
#ifdef CONFIG_VIDEO_ADV_DEBUG
.vidioc_g_register = vidioc_g_register,
.vidioc_s_register = vidioc_s_register,