From 8f997cbe9f33e7a2ae52d69ba7f17b83d297c665 Mon Sep 17 00:00:00 2001 From: Matt Buckley Date: Sat, 16 Nov 2024 19:26:34 -0800 Subject: Refactor initial support check to use SupportInfo This change makes the intial support check when APerformanceHintManager starts pass the SupportInfo object instead of just relying on the preferred rate Bug: 367803904 Test: atest PerformanceHintNativeTestCases Test: atest HintManagerServiceTest Flag: EXEMPT refactor Change-Id: Iba93310c58896a2b1d02c6156b4e67eaa766af5b --- services/powermanager/PowerHalController.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'services/powermanager/PowerHalController.cpp') diff --git a/services/powermanager/PowerHalController.cpp b/services/powermanager/PowerHalController.cpp index 40fd097491..0ba1909a44 100644 --- a/services/powermanager/PowerHalController.cpp +++ b/services/powermanager/PowerHalController.cpp @@ -168,6 +168,11 @@ HalResult PowerHalController::closeSessionChannel(int tgid, int uid) { "closeSessionChannel")); } +HalResult PowerHalController::getSupportInfo() { + std::shared_ptr handle = initHal(); + return CACHE_SUPPORT(6, processHalResult(handle->getSupportInfo(), "getSupportInfo")); +} + } // namespace power } // namespace android -- cgit v1.2.3-59-g8ed1b