mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 10:41:38 -04:00
[media] fimc-lite: Don't use mutex_lock_interruptible() in device release()
Use uninterruptible mutex_lock in the release() file op to make sure all resources are properly freed when a process is being terminated. Returning -ERESTARTSYS has no effect for a terminating process and this may cause driver resources not to be released. This patch is required for stable kernels v3.5+. Reported-by: Marek Szyprowski <[email protected]> Signed-off-by: Sylwester Nawrocki <[email protected]> Signed-off-by: Kyungmin Park <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
This commit is contained in:
parent
ba6b372cf0
commit
ddc43d6dc7
1 changed files with 1 additions and 2 deletions
|
|
@ -491,8 +491,7 @@ static int fimc_lite_close(struct file *file)
|
|||
struct fimc_lite *fimc = video_drvdata(file);
|
||||
int ret;
|
||||
|
||||
if (mutex_lock_interruptible(&fimc->lock))
|
||||
return -ERESTARTSYS;
|
||||
mutex_lock(&fimc->lock);
|
||||
|
||||
if (--fimc->ref_count == 0 && fimc->out_path == FIMC_IO_DMA) {
|
||||
clear_bit(ST_FLITE_IN_USE, &fimc->state);
|
||||
|
|
|
|||
Loading…
Reference in a new issue