Commit 5bdcd0d5 authored by Kai Engert's avatar Kai Engert Committed by Greg Kroah-Hartman

[PATCH] USB: enable pwc usb camera driver

The attached patch enables the pwc driver included with kernel 2.6.7-rc2

It also removes the warnings during compilation.
However, note that I blindly duplicated the release approach used by
other usb camera drivers, replacing the current no-op.

The driver works for me with a Logitech QuickCam Notebook Pro and
GnomeMeeting.
Signed-off-by: default avatarGreg Kroah-Hartman <greg@kroah.com>
parent 08786bea
...@@ -108,7 +108,7 @@ config USB_OV511 ...@@ -108,7 +108,7 @@ config USB_OV511
config USB_PWC config USB_PWC
tristate "USB Philips Cameras" tristate "USB Philips Cameras"
depends on USB && VIDEO_DEV && BROKEN depends on USB && VIDEO_DEV
---help--- ---help---
Say Y or M here if you want to use one of these Philips & OEM Say Y or M here if you want to use one of these Philips & OEM
webcams: webcams:
......
...@@ -129,7 +129,6 @@ static struct { ...@@ -129,7 +129,6 @@ static struct {
static int pwc_video_open(struct inode *inode, struct file *file); static int pwc_video_open(struct inode *inode, struct file *file);
static int pwc_video_close(struct inode *inode, struct file *file); static int pwc_video_close(struct inode *inode, struct file *file);
static int pwc_video_release(struct video_device *);
static ssize_t pwc_video_read(struct file *file, char *buf, static ssize_t pwc_video_read(struct file *file, char *buf,
size_t count, loff_t *ppos); size_t count, loff_t *ppos);
static unsigned int pwc_video_poll(struct file *file, poll_table *wait); static unsigned int pwc_video_poll(struct file *file, poll_table *wait);
...@@ -1121,12 +1120,6 @@ static int pwc_video_close(struct inode *inode, struct file *file) ...@@ -1121,12 +1120,6 @@ static int pwc_video_close(struct inode *inode, struct file *file)
return 0; return 0;
} }
static int pwc_video_release(struct video_device *vfd)
{
Trace(TRACE_OPEN, "pwc_video_release() called. Now what?\n");
}
/* /*
* FIXME: what about two parallel reads ???? * FIXME: what about two parallel reads ????
* ANSWER: Not supported. You can't open the device more than once, * ANSWER: Not supported. You can't open the device more than once,
...@@ -1855,7 +1848,7 @@ static int usb_pwc_probe(struct usb_interface *intf, const struct usb_device_id ...@@ -1855,7 +1848,7 @@ static int usb_pwc_probe(struct usb_interface *intf, const struct usb_device_id
} }
} }
pdev->vdev.release = pwc_video_release; pdev->vdev.release = video_device_release;
i = video_register_device(&pdev->vdev, VFL_TYPE_GRABBER, video_nr); i = video_register_device(&pdev->vdev, VFL_TYPE_GRABBER, video_nr);
if (i < 0) { if (i < 0) {
Err("Failed to register as video device (%d).\n", i); Err("Failed to register as video device (%d).\n", i);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment