diff options
author | Alexander Strakh <cromlehg@gmail.com> | 2011-01-25 16:00:13 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-03-22 05:51:57 -0400 |
commit | a07500ef690fcbec76e879ee2093d7ca69883825 (patch) | |
tree | cb210046aa200bca46ac4508de00664a46197b05 /drivers | |
parent | 868e90d55c0eb6f3c5949c2a747714072c3e080a (diff) |
[media] drivers/media/video/tlg2300/pd-video.c: Remove second mutex_unlock in pd_vidioc_s_fmt
Error path in file drivers/media/video/tlg2300/pd-video.c:
1. First mutex_unlock on &pd->lock in line 767 (in function that
called from line 805)
2. Second in line 806
805 pd_vidioc_s_fmt(pd, &f->fmt.pix);
806 mutex_unlock(&pd->lock);
Found by Linux Device Drivers Verification Project
Signed-off-by: Alexander Strakh <strakh@ispras.ru>
Acked-by: Huang Shijie <shijie8@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/media/video/tlg2300/pd-video.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/media/video/tlg2300/pd-video.c b/drivers/media/video/tlg2300/pd-video.c index df33a1d188bb..a794ae62aebf 100644 --- a/drivers/media/video/tlg2300/pd-video.c +++ b/drivers/media/video/tlg2300/pd-video.c | |||
@@ -764,10 +764,8 @@ static int pd_vidioc_s_fmt(struct poseidon *pd, struct v4l2_pix_format *pix) | |||
764 | } | 764 | } |
765 | ret |= send_set_req(pd, VIDEO_ROSOLU_SEL, | 765 | ret |= send_set_req(pd, VIDEO_ROSOLU_SEL, |
766 | vid_resol, &cmd_status); | 766 | vid_resol, &cmd_status); |
767 | if (ret || cmd_status) { | 767 | if (ret || cmd_status) |
768 | mutex_unlock(&pd->lock); | ||
769 | return -EBUSY; | 768 | return -EBUSY; |
770 | } | ||
771 | 769 | ||
772 | pix_def->pixelformat = pix->pixelformat; /* save it */ | 770 | pix_def->pixelformat = pix->pixelformat; /* save it */ |
773 | pix->height = (context->tvnormid & V4L2_STD_525_60) ? 480 : 576; | 771 | pix->height = (context->tvnormid & V4L2_STD_525_60) ? 480 : 576; |