SF: Remove refresh_rate_switching flag. With a fix.

ag/9294789 introduce a flag to only allow refresh rate switching on the
devices that have that flag set to true, because it broke devices that
didn't support multiple refresh rates, and Android TV.

LocalDisplayAdapter sets the refresh rate to default when booting the
phone, so no need for that in SF anymore.

Test: Turn off Smooth display (see b/148821456), device doesn't crash.
Test: Install on devices that doesn't have multiple refresh rates.
Test: Run SF unittests.
Test: Turn on all the flags, and run through set of examples:
      Video playback stays at 60.
      Camera stays at 60.
      Maps play at 60.
      Low brightness stays at 90.
      Swappy successfully switches between 60 & 90.
Test: Turn off all the flags, and rerun the examples from previous.
      If applications requested the change, the change is honored,
      otherwise we stay at default (set by DM).
Test: Ask Android TV team to test the patch.
Bug: 148427603
Bug: 148821456

Change-Id: I5bb964572d93e5cb78d7b75054b900917be563b0
diff --git a/services/surfaceflinger/Scheduler/RefreshRateConfigs.h b/services/surfaceflinger/Scheduler/RefreshRateConfigs.h
index c4dea0d..fc95959 100644
--- a/services/surfaceflinger/Scheduler/RefreshRateConfigs.h
+++ b/services/surfaceflinger/Scheduler/RefreshRateConfigs.h
@@ -94,9 +94,6 @@
     // Returns true if config is allowed by the current policy.
     bool isConfigAllowed(HwcConfigIndexType config) const EXCLUDES(mLock);
 
-    // Returns true if this device is doing refresh rate switching. This won't change at runtime.
-    bool refreshRateSwitchingSupported() const { return mRefreshRateSwitching; }
-
     // Describes the different options the layer voted for refresh rate
     enum class LayerVoteType {
         NoVote,          // Doesn't care about the refresh rate
@@ -167,10 +164,9 @@
         nsecs_t vsyncPeriod = 0;
     };
 
-    RefreshRateConfigs(bool refreshRateSwitching, const std::vector<InputConfig>& configs,
+    RefreshRateConfigs(const std::vector<InputConfig>& configs,
                        HwcConfigIndexType currentHwcConfig);
-    RefreshRateConfigs(bool refreshRateSwitching,
-                       const std::vector<std::shared_ptr<const HWC2::Display::Config>>& configs,
+    RefreshRateConfigs(const std::vector<std::shared_ptr<const HWC2::Display::Config>>& configs,
                        HwcConfigIndexType currentConfigId);
 
 private:
@@ -208,8 +204,6 @@
     const RefreshRate* mMinSupportedRefreshRate;
     const RefreshRate* mMaxSupportedRefreshRate;
 
-    const bool mRefreshRateSwitching;
-
     mutable std::mutex mLock;
 };