summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2008-08-31 23:19:51 +0200
committerHans Verkuil <hverkuil@xs4all.nl>2008-08-31 23:19:51 +0200
commit039647d64a2b2e7065e250580e0d10b9f3320af7 (patch)
tree5920e3a3b95c3fbb6cca7e89a3bdc020df6d8cbc
parent34584ca5eb9a254a02637b9141526f931cde3ce6 (diff)
downloadmediapointer-dvb-s2-039647d64a2b2e7065e250580e0d10b9f3320af7.tar.gz
mediapointer-dvb-s2-039647d64a2b2e7065e250580e0d10b9f3320af7.tar.bz2
uvcvideo: fix compilation on older kernels
From: Laurent Pinchart <laurent.pinchart@skynet.be> The USB reset_resume method appeared in 2.6.23. This patch fixes compilation of the v4l-dvb tree on older kernels. Priority: normal Signed-off-by: Laurent Pinchart <laurent.pinchart@skynet.be> Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
-rw-r--r--linux/drivers/media/video/uvc/uvc_driver.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/linux/drivers/media/video/uvc/uvc_driver.c b/linux/drivers/media/video/uvc/uvc_driver.c
index 4ab4d1ebb..b2482502a 100644
--- a/linux/drivers/media/video/uvc/uvc_driver.c
+++ b/linux/drivers/media/video/uvc/uvc_driver.c
@@ -1692,10 +1692,12 @@ static int uvc_resume(struct usb_interface *intf)
return __uvc_resume(intf, 0);
}
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 23)
static int uvc_reset_resume(struct usb_interface *intf)
{
return __uvc_resume(intf, 1);
}
+#endif
/* ------------------------------------------------------------------------
* Driver initialization and cleanup
@@ -1971,7 +1973,9 @@ struct uvc_driver uvc_driver = {
.disconnect = uvc_disconnect,
.suspend = uvc_suspend,
.resume = uvc_resume,
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 23)
.reset_resume = uvc_reset_resume,
+#endif
.id_table = uvc_ids,
.supports_autosuspend = 1,
},