Fix a deadlock involving BatteryService.
Fix a deadlock involving BatteryService.

The PowerManager may call into the BatteryService while
holding its locks.  We need to be careful that the BatteryService
doesn't call into other services, particularly the ActivityManager
while holding its own locks.

Bug: 7298218
Change-Id: Ibf8ab13224f204a9857825265e864f93583bce8e

xorware/android_frameworks_base,xorware/android_frameworks_base,xorware/android_frameworks_base,xorware/android_frameworks_base,xorware/android_frameworks_base,xorware/android_frameworks_base