Merge "Pass Binder token to ISuspendControlServiceInternal#enableAutosuspend" am: 530fbd2d14 am: 91b6322393
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1841755 Change-Id: Iefe3dc119bcf8fa72b453d4cf0d302b844757377
This commit is contained in:
@@ -178,9 +178,10 @@ sp<system::suspend::internal::ISuspendControlServiceInternal> getSuspendControlI
|
|||||||
void enableAutoSuspend() {
|
void enableAutoSuspend() {
|
||||||
static bool enabled = false;
|
static bool enabled = false;
|
||||||
if (!enabled) {
|
if (!enabled) {
|
||||||
|
static sp<IBinder> autosuspendClientToken = new BBinder();
|
||||||
sp<system::suspend::internal::ISuspendControlServiceInternal> suspendControl =
|
sp<system::suspend::internal::ISuspendControlServiceInternal> suspendControl =
|
||||||
getSuspendControlInternal();
|
getSuspendControlInternal();
|
||||||
suspendControl->enableAutosuspend(&enabled);
|
suspendControl->enableAutosuspend(autosuspendClientToken, &enabled);
|
||||||
}
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user