diff options
author | Marco Nelissen <marcone@google.com> | 2013-10-16 10:57:51 -0700 |
---|---|---|
committer | Marco Nelissen <marcone@google.com> | 2013-10-25 12:50:04 -0700 |
commit | 708cc794f6ccd4d31e0a00a23b289272c665adc1 (patch) | |
tree | 692a142f18ed435ad9d19b8eb2351335a95f767d /services/powermanager | |
parent | c354effe97be26638618e3bc0da81a3f8b384b20 (diff) | |
download | frameworks_native-708cc794f6ccd4d31e0a00a23b289272c665adc1.zip frameworks_native-708cc794f6ccd4d31e0a00a23b289272c665adc1.tar.gz frameworks_native-708cc794f6ccd4d31e0a00a23b289272c665adc1.tar.bz2 |
Native counterpart of new power manager method
Cherrypicked from master.
b/9464621
Change-Id: I54c0ed50a57ac870da91db8589a73a2c792dbd8d
Diffstat (limited to 'services/powermanager')
-rw-r--r-- | services/powermanager/IPowerManager.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/services/powermanager/IPowerManager.cpp b/services/powermanager/IPowerManager.cpp index 9f60e75..5ecd299 100644 --- a/services/powermanager/IPowerManager.cpp +++ b/services/powermanager/IPowerManager.cpp @@ -32,6 +32,7 @@ enum { ACQUIRE_WAKE_LOCK = IBinder::FIRST_CALL_TRANSACTION, ACQUIRE_WAKE_LOCK_UID = IBinder::FIRST_CALL_TRANSACTION + 1, RELEASE_WAKE_LOCK = IBinder::FIRST_CALL_TRANSACTION + 2, + UPDATE_WAKE_LOCK_UIDS = IBinder::FIRST_CALL_TRANSACTION + 3, }; class BpPowerManager : public BpInterface<IPowerManager> @@ -78,6 +79,16 @@ public: data.writeInt32(flags); return remote()->transact(RELEASE_WAKE_LOCK, data, &reply); } + + virtual status_t updateWakeLockUids(const sp<IBinder>& lock, int len, const int *uids) { + Parcel data, reply; + data.writeInterfaceToken(IPowerManager::getInterfaceDescriptor()); + data.writeStrongBinder(lock); + data.writeInt32Array(len, uids); + // We don't really care too much if this succeeds (there's nothing we can do if it doesn't) + // but it should return ASAP + return remote()->transact(UPDATE_WAKE_LOCK_UIDS, data, &reply, IBinder::FLAG_ONEWAY); + } }; IMPLEMENT_META_INTERFACE(PowerManager, "android.os.IPowerManager"); |