SF: VSyncTracker, clear timestamps on beginResync
DispSync would clear its internal model around power events, as the
vsync timings during power mode changes are not accurate for screen-on
vsync prediction. DispSync uses the beginResync signal for this, and the
new system does the same (although once DispSync is deprecated,
begin/endResync should go away too).
Fixes: 146050690
Test: Dogfooding blueline
Test: 2 new unit tests
Change-Id: Ie4b607029516dcea0e5d65afca75a7017bf63e12
diff --git a/services/surfaceflinger/Scheduler/VSyncReactor.cpp b/services/surfaceflinger/Scheduler/VSyncReactor.cpp
index a652053..57e05d3 100644
--- a/services/surfaceflinger/Scheduler/VSyncReactor.cpp
+++ b/services/surfaceflinger/Scheduler/VSyncReactor.cpp
@@ -185,7 +185,9 @@
return mTracker->currentPeriod();
}
-void VSyncReactor::beginResync() {}
+void VSyncReactor::beginResync() {
+ mTracker->resetModel();
+}
void VSyncReactor::endResync() {}