summaryrefslogtreecommitdiff
path: root/hwc3/impl/HalImpl.cpp
diff options
context:
space:
mode:
authorMidas Chien <midaschieh@google.com>2021-12-20 13:03:42 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2021-12-20 13:03:42 +0000
commitefc63c49f167db0c2788fe69eb6aba04cf7c2859 (patch)
treeb6be0a952d7553107f401092ea24f61a7afe81cd /hwc3/impl/HalImpl.cpp
parent139c5539d48b14df34ab4aabc8fbd22487ad56f6 (diff)
parentf72a3bba89df212d83ff0f94e23e7cef8bc4c231 (diff)
Merge "hwc3: do acceptDisplayChanges if display is validated"
Diffstat (limited to 'hwc3/impl/HalImpl.cpp')
-rw-r--r--hwc3/impl/HalImpl.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/hwc3/impl/HalImpl.cpp b/hwc3/impl/HalImpl.cpp
index 45dfa32..f79073b 100644
--- a/hwc3/impl/HalImpl.cpp
+++ b/hwc3/impl/HalImpl.cpp
@@ -536,6 +536,16 @@ int32_t HalImpl::presentDisplay(int64_t display, ndk::ScopedFileDescriptor& fenc
ExynosDisplay* halDisplay;
RET_IF_ERR(getHalDisplay(display, halDisplay));
+ // TODO: not expect acceptDisplayChanges if there are no changes to accept
+ if (halDisplay->mRenderingState == RENDERING_STATE_VALIDATED) {
+ LOG(INFO) << halDisplay->mDisplayName.string()
+ << ": acceptDisplayChanges was not called";
+ if (halDisplay->acceptDisplayChanges() != HWC2_ERROR_NONE) {
+ LOG(ERROR) << halDisplay->mDisplayName.string()
+ << ": acceptDisplayChanges is failed";
+ }
+ }
+
int32_t hwcFence;
RET_IF_ERR(halDisplay->presentDisplay(&hwcFence));
h2a::translate(hwcFence, fence);