Loading services/surfaceflinger/Scheduler/RefreshRateConfigs.cpp +0 −5 Original line number Diff line number Diff line Loading @@ -867,11 +867,6 @@ RefreshRateConfigs::KernelIdleTimerAction RefreshRateConfigs::getIdleTimerAction return RefreshRateConfigs::KernelIdleTimerAction::TurnOff; } if (minByPolicy == maxByPolicy) { // Do not sent the call to toggle off kernel idle timer if the device min and policy min and // max are all the same. This saves us extra unnecessary calls to sysprop. if (deviceMin == minByPolicy) { return RefreshRateConfigs::KernelIdleTimerAction::NoChange; } return RefreshRateConfigs::KernelIdleTimerAction::TurnOff; } // Turn on the timer in all other cases. Loading services/surfaceflinger/Scheduler/RefreshRateConfigs.h +0 −1 Original line number Diff line number Diff line Loading @@ -318,7 +318,6 @@ public: // Class to enumerate options around toggling the kernel timer on and off. We have an option // for no change to avoid extra calls to kernel. enum class KernelIdleTimerAction { NoChange, // Do not change the idle timer. TurnOff, // Turn off the idle timer. TurnOn // Turn on the idle timer. }; Loading services/surfaceflinger/SurfaceFlinger.cpp +0 −2 Original line number Diff line number Diff line Loading @@ -5811,8 +5811,6 @@ void SurfaceFlinger::toggleKernelIdleTimer() { mKernelIdleTimerEnabled = true; } break; case KernelIdleTimerAction::NoChange: break; } } Loading services/surfaceflinger/tests/unittests/RefreshRateConfigsTest.cpp +2 −2 Original line number Diff line number Diff line Loading @@ -1897,10 +1897,10 @@ TEST_F(RefreshRateConfigsTest, testKernelIdleTimerAction) { 0); EXPECT_EQ(KernelIdleTimerAction::TurnOn, refreshRateConfigs->getIdleTimerAction()); // SetPolicy(60, 60), current 60Hz => NoChange, avoid extra calls. // SetPolicy(60, 60), current 60Hz => TurnOff ASSERT_GE(refreshRateConfigs->setDisplayManagerPolicy({HWC_CONFIG_ID_60, {Fps(60), Fps(60)}}), 0); EXPECT_EQ(KernelIdleTimerAction::NoChange, refreshRateConfigs->getIdleTimerAction()); EXPECT_EQ(KernelIdleTimerAction::TurnOff, refreshRateConfigs->getIdleTimerAction()); // SetPolicy(90, 90), current 90Hz => TurnOff. ASSERT_GE(refreshRateConfigs->setDisplayManagerPolicy({HWC_CONFIG_ID_90, {Fps(90), Fps(90)}}), Loading Loading
services/surfaceflinger/Scheduler/RefreshRateConfigs.cpp +0 −5 Original line number Diff line number Diff line Loading @@ -867,11 +867,6 @@ RefreshRateConfigs::KernelIdleTimerAction RefreshRateConfigs::getIdleTimerAction return RefreshRateConfigs::KernelIdleTimerAction::TurnOff; } if (minByPolicy == maxByPolicy) { // Do not sent the call to toggle off kernel idle timer if the device min and policy min and // max are all the same. This saves us extra unnecessary calls to sysprop. if (deviceMin == minByPolicy) { return RefreshRateConfigs::KernelIdleTimerAction::NoChange; } return RefreshRateConfigs::KernelIdleTimerAction::TurnOff; } // Turn on the timer in all other cases. Loading
services/surfaceflinger/Scheduler/RefreshRateConfigs.h +0 −1 Original line number Diff line number Diff line Loading @@ -318,7 +318,6 @@ public: // Class to enumerate options around toggling the kernel timer on and off. We have an option // for no change to avoid extra calls to kernel. enum class KernelIdleTimerAction { NoChange, // Do not change the idle timer. TurnOff, // Turn off the idle timer. TurnOn // Turn on the idle timer. }; Loading
services/surfaceflinger/SurfaceFlinger.cpp +0 −2 Original line number Diff line number Diff line Loading @@ -5811,8 +5811,6 @@ void SurfaceFlinger::toggleKernelIdleTimer() { mKernelIdleTimerEnabled = true; } break; case KernelIdleTimerAction::NoChange: break; } } Loading
services/surfaceflinger/tests/unittests/RefreshRateConfigsTest.cpp +2 −2 Original line number Diff line number Diff line Loading @@ -1897,10 +1897,10 @@ TEST_F(RefreshRateConfigsTest, testKernelIdleTimerAction) { 0); EXPECT_EQ(KernelIdleTimerAction::TurnOn, refreshRateConfigs->getIdleTimerAction()); // SetPolicy(60, 60), current 60Hz => NoChange, avoid extra calls. // SetPolicy(60, 60), current 60Hz => TurnOff ASSERT_GE(refreshRateConfigs->setDisplayManagerPolicy({HWC_CONFIG_ID_60, {Fps(60), Fps(60)}}), 0); EXPECT_EQ(KernelIdleTimerAction::NoChange, refreshRateConfigs->getIdleTimerAction()); EXPECT_EQ(KernelIdleTimerAction::TurnOff, refreshRateConfigs->getIdleTimerAction()); // SetPolicy(90, 90), current 90Hz => TurnOff. ASSERT_GE(refreshRateConfigs->setDisplayManagerPolicy({HWC_CONFIG_ID_90, {Fps(90), Fps(90)}}), Loading