SurfaceFlinger: mExpectedPresentTime should not be updated outside the
main thread

mExpectedPresentTime should be set only by the main thread when
composition starts as it is used throughout the composition stage,
and updates to this variable may cause SF to use inconsistent values
for determining the expected present time.

Test: Run TouchLatency app and observe systraces
Test: Expand notification shade and observe systraces
Bug: 178148035
Change-Id: Ie221d7e1fb0b0965460af773d3ecf0b06b5c5d7a
3 files changed