diff options
author | Pascal Terjan <pterjan@mandriva.com> | 2008-03-07 06:22:57 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2008-03-20 11:39:01 -0400 |
commit | 974a911d2ae310d7082100e9992d1efdf72d86a5 (patch) | |
tree | 509fe12e57bf0a349c3a522526c133bc536a1349 /drivers/media/video/usbvideo/usbvideo.c | |
parent | c77990e754af7443246f24ccb2336bbd62b01cc0 (diff) |
V4L/DVB (7334): usb video: add a device link to usbvideo devices, else hal will ignore them
Signed-off-by: Pascal Terjan <pterjan@mandriva.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/usbvideo/usbvideo.c')
-rw-r--r-- | drivers/media/video/usbvideo/usbvideo.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/media/video/usbvideo/usbvideo.c b/drivers/media/video/usbvideo/usbvideo.c index fb434b5602a3..5d363be7bc73 100644 --- a/drivers/media/video/usbvideo/usbvideo.c +++ b/drivers/media/video/usbvideo/usbvideo.c | |||
@@ -1034,6 +1034,11 @@ int usbvideo_RegisterVideoDevice(struct uvd *uvd) | |||
1034 | info("%s: iface=%d. endpoint=$%02x paletteBits=$%08lx", | 1034 | info("%s: iface=%d. endpoint=$%02x paletteBits=$%08lx", |
1035 | __FUNCTION__, uvd->iface, uvd->video_endp, uvd->paletteBits); | 1035 | __FUNCTION__, uvd->iface, uvd->video_endp, uvd->paletteBits); |
1036 | } | 1036 | } |
1037 | if (uvd->dev == NULL) { | ||
1038 | err("%s: uvd->dev == NULL", __FUNCTION__); | ||
1039 | return -EINVAL; | ||
1040 | } | ||
1041 | uvd->vdev.dev=&(uvd->dev->dev); | ||
1037 | if (video_register_device(&uvd->vdev, VFL_TYPE_GRABBER, video_nr) == -1) { | 1042 | if (video_register_device(&uvd->vdev, VFL_TYPE_GRABBER, video_nr) == -1) { |
1038 | err("%s: video_register_device failed", __FUNCTION__); | 1043 | err("%s: video_register_device failed", __FUNCTION__); |
1039 | return -EPIPE; | 1044 | return -EPIPE; |
@@ -1041,10 +1046,6 @@ int usbvideo_RegisterVideoDevice(struct uvd *uvd) | |||
1041 | if (uvd->debug > 1) { | 1046 | if (uvd->debug > 1) { |
1042 | info("%s: video_register_device() successful", __FUNCTION__); | 1047 | info("%s: video_register_device() successful", __FUNCTION__); |
1043 | } | 1048 | } |
1044 | if (uvd->dev == NULL) { | ||
1045 | err("%s: uvd->dev == NULL", __FUNCTION__); | ||
1046 | return -EINVAL; | ||
1047 | } | ||
1048 | 1049 | ||
1049 | info("%s on /dev/video%d: canvas=%s videosize=%s", | 1050 | info("%s on /dev/video%d: canvas=%s videosize=%s", |
1050 | (uvd->handle != NULL) ? uvd->handle->drvName : "???", | 1051 | (uvd->handle != NULL) ? uvd->handle->drvName : "???", |