summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
authorMarco Nelissen <marcone@google.com>2013-10-03 08:49:36 -0700
committerMarco Nelissen <marcone@google.com>2013-10-03 08:49:36 -0700
commitd983ba5cac232c01dff818556b57f497f7d99854 (patch)
tree8ef43b6d5569d295aa60e2b9646955127a9df2c0 /services
parentd6957d5f8ddf3b542996955bf2d6efe0e9804ef4 (diff)
downloadframeworks_base-d983ba5cac232c01dff818556b57f497f7d99854.zip
frameworks_base-d983ba5cac232c01dff818556b57f497f7d99854.tar.gz
frameworks_base-d983ba5cac232c01dff818556b57f497f7d99854.tar.bz2
Add PowerManager method to assign blame to a single uid
Currently used by audioflinger to account for recording wakelocks. b/10985160 Change-Id: I18fc8487f2a197bf02b5269a4bcae9e75b6c2207
Diffstat (limited to 'services')
-rw-r--r--services/java/com/android/server/power/PowerManagerService.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/services/java/com/android/server/power/PowerManagerService.java b/services/java/com/android/server/power/PowerManagerService.java
index fe09a33..4407de6 100644
--- a/services/java/com/android/server/power/PowerManagerService.java
+++ b/services/java/com/android/server/power/PowerManagerService.java
@@ -579,6 +579,12 @@ public final class PowerManagerService extends IPowerManager.Stub
}
@Override // Binder call
+ public void acquireWakeLockWithUid(IBinder lock, int flags, String tag, String packageName,
+ int uid) {
+ acquireWakeLock(lock, flags, tag, packageName, new WorkSource(uid));
+ }
+
+ @Override // Binder call
public void acquireWakeLock(IBinder lock, int flags, String tag, String packageName,
WorkSource ws) {
if (lock == null) {