From 54717e8e017c5e985e43f45c81528dd730e7d3d3 Mon Sep 17 00:00:00 2001 From: Boram Park Date: Tue, 27 Feb 2018 08:32:41 +0900 Subject: [PATCH] hwc: unlock before reture Change-Id: Ic60059f20d7a4de093d951ea15800adc14ad1d99 --- src/tdm_output.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/tdm_output.c b/src/tdm_output.c index 3d096d9..e73de5b 100644 --- a/src/tdm_output.c +++ b/src/tdm_output.c @@ -1938,6 +1938,7 @@ tdm_output_hwc_commit_client_target_buffer(tdm_output *output, tdm_output_hwc_ta if (ret != TDM_ERROR_NONE) { /* LCOV_EXCL_START */ TDM_ERR("failed: layer set info(window)"); + _pthread_mutex_unlock(&private_display->lock); /* LCOV_EXCL_STOP */ return ret; } @@ -1960,6 +1961,7 @@ tdm_output_hwc_commit_client_target_buffer(tdm_output *output, tdm_output_hwc_ta if (ret != TDM_ERROR_NONE) { /* LCOV_EXCL_START */ TDM_ERR("failed: layer set info(window)"); + _pthread_mutex_unlock(&private_display->lock); /* LCOV_EXCL_STOP */ return ret; } @@ -1971,6 +1973,7 @@ tdm_output_hwc_commit_client_target_buffer(tdm_output *output, tdm_output_hwc_ta if (!output_hwc_target_buffer_commit_handler) { /* LCOV_EXCL_START */ TDM_ERR("failed: alloc memory"); + _pthread_mutex_unlock(&private_display->lock); return TDM_ERROR_OUT_OF_MEMORY; /* LCOV_EXCL_STOP */ } @@ -1984,6 +1987,7 @@ tdm_output_hwc_commit_client_target_buffer(tdm_output *output, tdm_output_hwc_ta /* LCOV_EXCL_START */ TDM_ERR("failed: commit layer(target buffer)"); free(output_hwc_target_buffer_commit_handler); + _pthread_mutex_unlock(&private_display->lock); /* LCOV_EXCL_STOP */ return ret; } -- 2.7.4