diff options
author | Hans Verkuil <hverkuil@xs4all.nl> | 2008-12-18 09:16:24 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2008-12-30 06:39:28 -0500 |
commit | 1fe2740ff10b3de1aab8f88f2f05547e5f369035 (patch) | |
tree | efe195799feb740906d0adc35ec7e30efb2e8f74 /drivers/media | |
parent | 531c98e71805b32e9ea35a218119100bbd2b7615 (diff) |
V4L/DVB (9957): v4l2-subdev: add g_sliced_vbi_cap and add NULL pointer checks
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/video/v4l2-subdev.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/media/video/v4l2-subdev.c b/drivers/media/video/v4l2-subdev.c index fe1f01c970ac..e3612f29d0df 100644 --- a/drivers/media/video/v4l2-subdev.c +++ b/drivers/media/video/v4l2-subdev.c | |||
@@ -40,13 +40,13 @@ int v4l2_subdev_command(struct v4l2_subdev *sd, unsigned cmd, void *arg) | |||
40 | case VIDIOC_G_CHIP_IDENT: | 40 | case VIDIOC_G_CHIP_IDENT: |
41 | return v4l2_subdev_call(sd, core, g_chip_ident, arg); | 41 | return v4l2_subdev_call(sd, core, g_chip_ident, arg); |
42 | case VIDIOC_INT_S_STANDBY: | 42 | case VIDIOC_INT_S_STANDBY: |
43 | return v4l2_subdev_call(sd, core, s_standby, *(u32 *)arg); | 43 | return v4l2_subdev_call(sd, core, s_standby, arg ? (*(u32 *)arg) : 0); |
44 | case VIDIOC_INT_RESET: | 44 | case VIDIOC_INT_RESET: |
45 | return v4l2_subdev_call(sd, core, reset, *(u32 *)arg); | 45 | return v4l2_subdev_call(sd, core, reset, arg ? (*(u32 *)arg) : 0); |
46 | case VIDIOC_INT_S_GPIO: | 46 | case VIDIOC_INT_S_GPIO: |
47 | return v4l2_subdev_call(sd, core, s_gpio, *(u32 *)arg); | 47 | return v4l2_subdev_call(sd, core, s_gpio, arg ? (*(u32 *)arg) : 0); |
48 | case VIDIOC_INT_INIT: | 48 | case VIDIOC_INT_INIT: |
49 | return v4l2_subdev_call(sd, core, init, *(u32 *)arg); | 49 | return v4l2_subdev_call(sd, core, init, arg ? (*(u32 *)arg) : 0); |
50 | #ifdef CONFIG_VIDEO_ADV_DEBUG | 50 | #ifdef CONFIG_VIDEO_ADV_DEBUG |
51 | case VIDIOC_DBG_G_REGISTER: | 51 | case VIDIOC_DBG_G_REGISTER: |
52 | return v4l2_subdev_call(sd, core, g_register, arg); | 52 | return v4l2_subdev_call(sd, core, g_register, arg); |
@@ -90,6 +90,8 @@ int v4l2_subdev_command(struct v4l2_subdev *sd, unsigned cmd, void *arg) | |||
90 | return v4l2_subdev_call(sd, video, s_vbi_data, arg); | 90 | return v4l2_subdev_call(sd, video, s_vbi_data, arg); |
91 | case VIDIOC_INT_G_VBI_DATA: | 91 | case VIDIOC_INT_G_VBI_DATA: |
92 | return v4l2_subdev_call(sd, video, g_vbi_data, arg); | 92 | return v4l2_subdev_call(sd, video, g_vbi_data, arg); |
93 | case VIDIOC_G_SLICED_VBI_CAP: | ||
94 | return v4l2_subdev_call(sd, video, g_sliced_vbi_cap, arg); | ||
93 | case VIDIOC_S_FMT: | 95 | case VIDIOC_S_FMT: |
94 | return v4l2_subdev_call(sd, video, s_fmt, arg); | 96 | return v4l2_subdev_call(sd, video, s_fmt, arg); |
95 | case VIDIOC_G_FMT: | 97 | case VIDIOC_G_FMT: |