From 85931bcd4f6443b638a1a159268403b7b7ace72a Mon Sep 17 00:00:00 2001 From: Junkyeong Kim Date: Wed, 21 Oct 2020 11:27:30 +0900 Subject: [PATCH] hwc: change use_vblank flag set position Change-Id: I4d7aeb5d879429a1380bccaffb7259f8feb2f3ec Signed-off-by: Junkyeong Kim --- src/tdm_hwc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/tdm_hwc.c b/src/tdm_hwc.c index 47b6abb..a0109bf 100644 --- a/src/tdm_hwc.c +++ b/src/tdm_hwc.c @@ -268,7 +268,6 @@ _tdm_hwc_vblank(tdm_private_hwc *private_hwc, tdm_private_hwc_commit_handler *hw if (ret != TDM_ERROR_NONE) goto done; - hwc_commit_handler->use_vblank = 1; private_output->layer_waiting_vblank = 1; /* tdm_vblank APIs is for server. it should be called in unlock status*/ @@ -277,7 +276,6 @@ _tdm_hwc_vblank(tdm_private_hwc *private_hwc, tdm_private_hwc_commit_handler *hw _pthread_mutex_lock(&private_display->lock); if (ret != TDM_ERROR_NONE) { if (!TDM_OUTPUT_DPMS_VSYNC_IS_OFF(private_output->current_dpms_value)) { - hwc_commit_handler->use_vblank = 0; private_output->layer_waiting_vblank = 0; } } @@ -779,6 +777,8 @@ tdm_hwc_commit(tdm_hwc *hwc, int sync, tdm_hwc_commit_handler func, void *user_d hwc_commit_handler->func = func; hwc_commit_handler->user_data = user_data; hwc_commit_handler->owner_tid = syscall(SYS_gettid); + if (hwc_use_vblank) + hwc_commit_handler->use_vblank = 1; if (private_module == private_display->virtual_module) { private_voutput = private_output->private_voutput; -- 2.7.4