From 720054de96c7006e463b4f57a4749fc3786e9c0c Mon Sep 17 00:00:00 2001 From: Jimmy Shiu Date: Sat, 25 Feb 2023 08:44:31 +0800 Subject: [PATCH] power-libperfmgr: ADPF: support sending power hint Send a hint only when the system can support the hint. Bug: 243025173 Test: PtsUiBench & CUJ Original-Change-Id: If56d0c22f8dd61f5fe27ba79f08f2963269abe41 Change-Id: I2c190ac357aa8c5b5da52e3e1566f4f62c388ba6 --- power-libperfmgr/aidl/PowerHintSession.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/power-libperfmgr/aidl/PowerHintSession.cpp b/power-libperfmgr/aidl/PowerHintSession.cpp index 11529ac..eadc4cf 100644 --- a/power-libperfmgr/aidl/PowerHintSession.cpp +++ b/power-libperfmgr/aidl/PowerHintSession.cpp @@ -364,7 +364,7 @@ ndk::ScopedAStatus PowerHintSession::sendHint(SessionHint hint) { ALOGE("Error: hint is invalid"); return ndk::ScopedAStatus::fromExceptionCode(EX_ILLEGAL_ARGUMENT); } - setCpuLoadChangeHint(toString(hint)); + tryToSendPowerHint(toString(hint)); mLastUpdatedTime.store(std::chrono::steady_clock::now()); if (ATRACE_ENABLED()) { mLastHintSent = static_cast(hint);