diff options
author | Hans Verkuil <hverkuil@xs4all.nl> | 2007-04-27 11:31:08 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2007-04-27 14:43:27 -0400 |
commit | 3434eb7e14d9587ee56f3462bcfa5726b62dadb9 (patch) | |
tree | 49afb0915dac8e7864f89582ddbb7a6453982e2c /drivers/media/video/ov7670.c | |
parent | ced80c67cd1ed503c6fb72f02ac7342ab4ebf67a (diff) |
V4L/DVB (5306): Add support for VIDIOC_G_CHIP_IDENT
VIDIOC_G_CHIP_IDENT improves debugging of card problems: it can be
used to detect which chips are on the board and based on that information
selected register dumps can be made, making it easy to debug complicated
media chips containing tens or hundreds of registers.
This ioctl replaces the internal VIDIOC_INT_G_CHIP_IDENT ioctl.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/ov7670.c')
-rw-r--r-- | drivers/media/video/ov7670.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/media/video/ov7670.c b/drivers/media/video/ov7670.c index 5ed0adc4ca26..5234762c5427 100644 --- a/drivers/media/video/ov7670.c +++ b/drivers/media/video/ov7670.c | |||
@@ -15,6 +15,7 @@ | |||
15 | #include <linux/delay.h> | 15 | #include <linux/delay.h> |
16 | #include <linux/videodev.h> | 16 | #include <linux/videodev.h> |
17 | #include <media/v4l2-common.h> | 17 | #include <media/v4l2-common.h> |
18 | #include <media/v4l2-chip-ident.h> | ||
18 | #include <linux/i2c.h> | 19 | #include <linux/i2c.h> |
19 | 20 | ||
20 | 21 | ||
@@ -1270,9 +1271,8 @@ static int ov7670_command(struct i2c_client *client, unsigned int cmd, | |||
1270 | void *arg) | 1271 | void *arg) |
1271 | { | 1272 | { |
1272 | switch (cmd) { | 1273 | switch (cmd) { |
1273 | case VIDIOC_INT_G_CHIP_IDENT: | 1274 | case VIDIOC_G_CHIP_IDENT: |
1274 | * (enum v4l2_chip_ident *) arg = V4L2_IDENT_OV7670; | 1275 | return v4l2_chip_ident_i2c_client(client, arg, V4L2_IDENT_OV7670, 0); |
1275 | return 0; | ||
1276 | 1276 | ||
1277 | case VIDIOC_INT_RESET: | 1277 | case VIDIOC_INT_RESET: |
1278 | ov7670_reset(client); | 1278 | ov7670_reset(client); |