diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2010-11-21 14:46:44 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2010-12-01 20:10:22 -0200 |
commit | 8e815e1763b8d4e5adf0dc14bde8c55329cf95a8 (patch) | |
tree | 517994a565f567d1317ba86222f3a64ffd8c042b /drivers/media/video/uvc/uvc_v4l2.c | |
parent | 23d9f3ef23f0dc4bb20ccd5540b9a91ff08da08f (diff) |
[media] uvcvideo: Move mutex lock/unlock inside uvc_free_buffers
Callers outside uvc_queue.c should not be forced to lock/unlock the
queue mutex manually. Move the mutex operations inside
uvc_free_buffers().
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/uvc/uvc_v4l2.c')
-rw-r--r-- | drivers/media/video/uvc/uvc_v4l2.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/media/video/uvc/uvc_v4l2.c b/drivers/media/video/uvc/uvc_v4l2.c index 0f865e97cf4..0fd9848bd9d 100644 --- a/drivers/media/video/uvc/uvc_v4l2.c +++ b/drivers/media/video/uvc/uvc_v4l2.c @@ -494,11 +494,9 @@ static int uvc_v4l2_release(struct file *file) if (uvc_has_privileges(handle)) { uvc_video_enable(stream, 0); - mutex_lock(&stream->queue.mutex); if (uvc_free_buffers(&stream->queue) < 0) uvc_printk(KERN_ERR, "uvc_v4l2_release: Unable to " "free buffers.\n"); - mutex_unlock(&stream->queue.mutex); } /* Release the file handle. */ |