diff --git a/sdm/libs/hwc2/hwc_session.cpp b/sdm/libs/hwc2/hwc_session.cpp index 02e2129e..81c9154c 100644 --- a/sdm/libs/hwc2/hwc_session.cpp +++ b/sdm/libs/hwc2/hwc_session.cpp @@ -72,6 +72,7 @@ namespace sdm { static HWCUEvent g_hwc_uevent_; Locker HWCSession::locker_[HWC_NUM_DISPLAY_TYPES]; +static const int kSolidFillDelay = 100 * 1000; void HWCUEvent::UEventThread(HWCUEvent *hwc_uevent) { const char *uevent_thread_name = "HWC_UeventThread"; @@ -1530,14 +1531,22 @@ android::status_t HWCSession::QdcmCMDHandler(const android::Parcel *input_parcel ret = color_mgr_->EnableQDCMMode(false, hwc_display_[HWC_DISPLAY_PRIMARY]); break; case kApplySolidFill: - ret = color_mgr_->SetSolidFill(pending_action.params, + { + SCOPE_LOCK(locker_[HWC_DISPLAY_PRIMARY]); + ret = color_mgr_->SetSolidFill(pending_action.params, true, hwc_display_[HWC_DISPLAY_PRIMARY]); + } Refresh(HWC_DISPLAY_PRIMARY); + usleep(kSolidFillDelay); break; case kDisableSolidFill: - ret = color_mgr_->SetSolidFill(pending_action.params, + { + SCOPE_LOCK(locker_[HWC_DISPLAY_PRIMARY]); + ret = color_mgr_->SetSolidFill(pending_action.params, false, hwc_display_[HWC_DISPLAY_PRIMARY]); + } Refresh(HWC_DISPLAY_PRIMARY); + usleep(kSolidFillDelay); break; case kSetPanelBrightness: brightness_value = reinterpret_cast(resp_payload.payload);