Resync on the transaction.
Currently only Choreographer requestNextVsync will resync otherwise.
Scheduler::resync already checks to make sure resync won't happen too
frequently (750 ms currently).
Bug: 266128330
Test: see b/380398647 and its child bugs
Flag: EXEMPT bugfix
Change-Id: Id3c0fc6a62b45262f4338f8154ad2fa8c0c16a05
(cherry picked from commit a5be328a8f3cb420ecdae34e9b25060631616a8f)
diff --git a/services/surfaceflinger/SurfaceFlinger.cpp b/services/surfaceflinger/SurfaceFlinger.cpp
index 4b36edc..12a99a8 100644
--- a/services/surfaceflinger/SurfaceFlinger.cpp
+++ b/services/surfaceflinger/SurfaceFlinger.cpp
@@ -4552,6 +4552,7 @@
SFTRACE_INT("mTransactionFlags", transactionFlags);
if (const bool scheduled = transactionFlags & mask; !scheduled) {
+ mScheduler->resync();
scheduleCommit(frameHint);
} else if (frameHint == FrameHint::kActive) {
// Even if the next frame is already scheduled, we should reset the idle timer