diff mbox

[1/1] video: exynos_mipi_dsi: Unlock the mutex before returning

Message ID 1382677964-15298-1-git-send-email-sachin.kamat@linaro.org (mailing list archive)
State New, archived
Headers show

Commit Message

Sachin Kamat Oct. 25, 2013, 5:12 a.m. UTC
Mutex should be unlocked before returning. Fixes mutex lock-unlock
imbalance issue.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
---
 drivers/video/exynos/exynos_mipi_dsi_common.c |    1 +
 1 file changed, 1 insertion(+)

Comments

Tomi Valkeinen Oct. 30, 2013, 11:53 a.m. UTC | #1
On 2013-10-25 08:12, Sachin Kamat wrote:
> Mutex should be unlocked before returning. Fixes mutex lock-unlock
> imbalance issue.
> 
> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
> ---
>  drivers/video/exynos/exynos_mipi_dsi_common.c |    1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/video/exynos/exynos_mipi_dsi_common.c b/drivers/video/exynos/exynos_mipi_dsi_common.c
> index 520fc9b..649d9e6 100644
> --- a/drivers/video/exynos/exynos_mipi_dsi_common.c
> +++ b/drivers/video/exynos/exynos_mipi_dsi_common.c
> @@ -376,6 +376,7 @@ int exynos_mipi_dsi_rd_data(struct mipi_dsim_device *dsim, unsigned int data_id,
>  			"data id %x is not supported current DSI spec.\n",
>  			data_id);
>  
> +		mutex_unlock(&dsim->lock);
>  		return -EINVAL;
>  	}
>  
> 

Thanks, queued for 3.13.

 Tomi
diff mbox

Patch

diff --git a/drivers/video/exynos/exynos_mipi_dsi_common.c b/drivers/video/exynos/exynos_mipi_dsi_common.c
index 520fc9b..649d9e6 100644
--- a/drivers/video/exynos/exynos_mipi_dsi_common.c
+++ b/drivers/video/exynos/exynos_mipi_dsi_common.c
@@ -376,6 +376,7 @@  int exynos_mipi_dsi_rd_data(struct mipi_dsim_device *dsim, unsigned int data_id,
 			"data id %x is not supported current DSI spec.\n",
 			data_id);
 
+		mutex_unlock(&dsim->lock);
 		return -EINVAL;
 	}