aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/usbvision
diff options
context:
space:
mode:
authorAndrew Morton <akpm@linux-foundation.org>2007-12-12 16:25:23 -0500
committerMauro Carvalho Chehab <mchehab@infradead.org>2008-01-25 16:03:37 -0500
commit544e6175330c86ad87abeeb1b048f56bafd96c31 (patch)
treeedf329c8e7266e2862dcc0c037ff8636ce65641f /drivers/media/video/usbvision
parent0991112c1c4625323df8a582de1b2f8609922248 (diff)
V4L/DVB (6811): media-video-usbvision-add-mutex_unlock-to-error-paths-fix
Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Thierry MERLE <thierry.merle@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/usbvision')
-rw-r--r--drivers/media/video/usbvision/usbvision-video.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/media/video/usbvision/usbvision-video.c b/drivers/media/video/usbvision/usbvision-video.c
index d929ced58ec3..92e72910792b 100644
--- a/drivers/media/video/usbvision/usbvision-video.c
+++ b/drivers/media/video/usbvision/usbvision-video.c
@@ -1290,8 +1290,8 @@ static int usbvision_radio_open(struct inode *inode, struct file *file)
1290 errCode = usbvision_set_alternate(usbvision); 1290 errCode = usbvision_set_alternate(usbvision);
1291 if (errCode < 0) { 1291 if (errCode < 0) {
1292 usbvision->last_error = errCode; 1292 usbvision->last_error = errCode;
1293 mutex_unlock(&usbvision->lock); 1293 errCode = -EBUSY;
1294 return -EBUSY; 1294 goto out;
1295 } 1295 }
1296 1296
1297 // If so far no errors then we shall start the radio 1297 // If so far no errors then we shall start the radio
@@ -1308,6 +1308,7 @@ static int usbvision_radio_open(struct inode *inode, struct file *file)
1308 usbvision->initialized = 0; 1308 usbvision->initialized = 0;
1309 } 1309 }
1310 } 1310 }
1311out:
1311 mutex_unlock(&usbvision->lock); 1312 mutex_unlock(&usbvision->lock);
1312 return errCode; 1313 return errCode;
1313} 1314}