Add a flag for refresh rate switching

Some devices don't do refresh rate switching, so we should take that
into account when filtering display manager config settings and deciding
scheduling behavior.

This CL adds a sysprop that can be set to indicate if surface flinger
should do refresh rate switching, and modifies surface flinger to have
the correct behavior when we're not doing refresh rate switching.

Bug: 147233255
Bug: 136592946
Bug: 138261472

Test: Ran through various 60/90 switching scenarios on a device with
refresh rate switching.

Test: Set the refresh rate switching sysprop to false, and confirmed we
get a consistent 60Hz.

Test: Inspected dumpsys output and confirmed it looks correct. In
particular, refresh rate stats are output correctly.

Test: Ran automated tests: RefreshRateConfigsTest, RefreshRateStatsTest,
SchedulerTest.

Change-Id: I54cd5be9d2c1b9abc8475c3ce39846cbe9f9fe53
Merged-In: I54cd5be9d2c1b9abc8475c3ce39846cbe9f9fe53
18 files changed