aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/et61x251
diff options
context:
space:
mode:
authorLuca Risolia <luca.risolia@studio.unibo.it>2006-11-21 06:13:59 -0500
committerMauro Carvalho Chehab <mchehab@infradead.org>2006-11-26 05:52:37 -0500
commit5718bbd2d92b9c2aa2f5700e4d3ed9d72f72f47e (patch)
tree1f887f31677c5bd370b60d343fad9b246324ba01 /drivers/media/video/et61x251
parenta5bbc7d94cf1dcb2100eeaf68791a401ad7ce54d (diff)
V4L/DVB (4865): Fix: Slot 0 not NULL on disconnecting SN9C10x PC Camera
The patch fix bug 5748. Signed-off-by: Luca Risolia <luca.risolia@studio.unibo.it> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/et61x251')
-rw-r--r--drivers/media/video/et61x251/et61x251_core.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/media/video/et61x251/et61x251_core.c b/drivers/media/video/et61x251/et61x251_core.c
index f786ab11d2cd..86e353b26b53 100644
--- a/drivers/media/video/et61x251/et61x251_core.c
+++ b/drivers/media/video/et61x251/et61x251_core.c
@@ -1182,8 +1182,6 @@ static void et61x251_release_resources(struct et61x251_device* cam)
1182 video_set_drvdata(cam->v4ldev, NULL); 1182 video_set_drvdata(cam->v4ldev, NULL);
1183 video_unregister_device(cam->v4ldev); 1183 video_unregister_device(cam->v4ldev);
1184 1184
1185 usb_put_dev(cam->usbdev);
1186
1187 mutex_unlock(&et61x251_sysfs_lock); 1185 mutex_unlock(&et61x251_sysfs_lock);
1188 1186
1189 kfree(cam->control_buffer); 1187 kfree(cam->control_buffer);
@@ -1275,6 +1273,7 @@ static int et61x251_release(struct inode* inode, struct file* filp)
1275 1273
1276 if (cam->state & DEV_DISCONNECTED) { 1274 if (cam->state & DEV_DISCONNECTED) {
1277 et61x251_release_resources(cam); 1275 et61x251_release_resources(cam);
1276 usb_put_dev(cam->usbdev);
1278 mutex_unlock(&cam->dev_mutex); 1277 mutex_unlock(&cam->dev_mutex);
1279 kfree(cam); 1278 kfree(cam);
1280 return 0; 1279 return 0;