SF: Add autorefresh to drawingstate

Autorefresh does not need to be an atomic variable. It is
only accessed from the main thread. Move it to drawing
state so it can be accessed from the base Layer class when
creating the starting state.

Test: presubmit
Bug: 200284593
Change-Id: I52a00c4185a3a883e4d5cf850257bb3a098b4d22
diff --git a/services/surfaceflinger/BufferStateLayer.cpp b/services/surfaceflinger/BufferStateLayer.cpp
index f7f96ab..4f0bbd2 100644
--- a/services/surfaceflinger/BufferStateLayer.cpp
+++ b/services/surfaceflinger/BufferStateLayer.cpp
@@ -660,9 +660,7 @@
 }
 
 void BufferStateLayer::setAutoRefresh(bool autoRefresh) {
-    if (!mAutoRefresh.exchange(autoRefresh)) {
-        mFlinger->onLayerUpdate();
-    }
+    mDrawingState.autoRefresh = autoRefresh;
 }
 
 bool BufferStateLayer::latchSidebandStream(bool& recomputeVisibleRegions) {