a4d22d718affbc7145d1012157feb819557b5c06 |
|
17-Sep-2015 |
Michael Wright <michaelwr@google.com> |
Send power hint on fling gestures. Use the existing PointerEventListener infrastructure to listen for gestures that look like flings and hint to the power system when they happen. Since we don't actually have a bound for the fling like a regular application would, limit them to five seconds and refresh every time a new fling is seen until the five second time period is up. bug 24059298 Change-Id: I5757a1e88f2ab2ef08cccefa8221d809ae71bb6f
/frameworks/base/core/java/android/os/PowerManagerInternal.java
|
af575b9f8e1b59be9c8862b6a65c0dcb88145a23 |
|
30-May-2015 |
Amith Yamasani <yamasani@google.com> |
Temporarily whitelist an app for network during doze API to allow an app to be whitelisted for network and wakelock access for a short period. So even if the device is in idle mode, such apps can be given a chance to download the payload related to a high priority cloud-to-device message. This API is meant for system apps only. A new permission CHANGE_DEVICE_IDLE_TEMP_WHITELIST is required to make this call. Bug: 21525864 Change-Id: Id7a761a664f21af5d7ff55aa56e8df98d15511ca
/frameworks/base/core/java/android/os/PowerManagerInternal.java
|
d23e0d6901935588f9472bd7073fea0009581e9b |
|
16-May-2015 |
Dianne Hackborn <hackbod@google.com> |
Update power manager to track uid state like netstats. To follow the correct semantics for when restricts due to device idle can be applied, power manager need to know about uid process states like net policy so that it can allow wake locks from apps that are in the foreground. Since this is being added to a second place, I reworked things so that the activity manager now keeps track of per-uid process states and allows apps to register to listen to those, rather than having to track lower-level process states and transform them into an overall uid state. Both net policy and power manager use this new facility. Change-Id: I77359164c40d0f36fe1ef296dd9f9c3062431148
/frameworks/base/core/java/android/os/PowerManagerInternal.java
|
8d66b3fbf5d8036e25d64a8472bcd2b6b7892a1a |
|
09-May-2015 |
Dianne Hackborn <hackbod@google.com> |
Implement device idle in power manager. When in device idle mode, we now prevent most apps from being able to hold partial wake locks. The device idle controller now pushes its white list of app uids into the power manager, so it can apply this policy correctly to only apps that are not whitelisted. The implementation adds a new "disabled" flag to a wake lock which is set when we want to apply this policy. When set, we ensure that we tell battery stats that the wake lock is not being held and ignore that wake lock when computing the power state summary. Also add new SDK APIs to schedule alarms that are allowed to execute while in idle mode. Finally add new dumpsys commands to the device idle controller to completely disable and re-enable its operation, to use for testing. Change-Id: I1f16672c6ac06d03bb538f9854d5843db9aa6f27
/frameworks/base/core/java/android/os/PowerManagerInternal.java
|
88e98dfa59e68a860d8c3b462ec03bc0b06d6b5c |
|
23-Mar-2015 |
Dianne Hackborn <hackbod@google.com> |
More work on device idle mode. - There is now an API for people to find out about its state. - Moved DeviceIdleController to be closer to the power manager implementation, since they are closely related. - Job scheduler now knows about idle state and doesn't run jobs while the device is idle. - Battery stats now keeps track of "idling" vs "idle mode". Idling is when we consider the device to be idle, independent of whether we are actually in deep idle mode. This allows us to keep track of longer-term changes independently of cycling in and out of idle mode. - Battery stats also now keeps track of package changes in its daily stats. - Small optimization to network policy manager service to not touch uids that do not have the NETWORK permission. Change-Id: I0b3304fb3722c78cdfdd0c1eada7369ece7cbcf9
/frameworks/base/core/java/android/os/PowerManagerInternal.java
|
9ef94019386183cb88ad090965418ef294bbb79a |
|
21-Nov-2014 |
Jeff Brown <jeffbrown@google.com> |
resolved conflicts for merge of 694c1d2b to lmp-mr1-dev Change-Id: I9a9b724e0fd12aa161ff276540431b9d8e218e2b
|
fbe96706bb9754f9ea3f6345f32e058a45ad10b4 |
|
20-Nov-2014 |
Jeff Brown <jeffbrown@google.com> |
Support keeping activities resumed while dozing. If the lock screen is not shown, then let activities keep running while dozing. This is important to support ambient mode on watches since it allows the home app to keep running. To make this possible, we need to inform the activity manager about the exact wakefulness state, not just the overall boolean interactive state. Bug: 18284212 Change-Id: Ia35c99127ce51ffc178f3a2f51fca67d24061c71
/frameworks/base/core/java/android/os/PowerManagerInternal.java
|
5ce1cb240b13db98fbdc21e1ef069b5f9cec8d72 |
|
07-Nov-2014 |
Jeff Brown <jeffbrown@google.com> |
Move device admin max screen off timeout to internal interface. The setting was previously exposed in IPowerManager but it doesn't need to be there. Bug: 17656076 Change-Id: If3ed0cbe89f67c60aa00376be0c54b1bd9656144
/frameworks/base/core/java/android/os/PowerManagerInternal.java
|
970d4132ea28e748c1010be39450a98bbf7466f3 |
|
19-Jul-2014 |
Jeff Brown <jeffbrown@google.com> |
Allow dreams to control screen state and brightness. Added setDozeScreenState() and setDozeScreenBrightness() methods to DreamService. The values specified here only take effect once startDozing is called and can be changed while dozing. This required some significant rework of the display power controller but the result seems quite nice and better represents the policy we want to apply. Changed the test dream a little bit to make it flash the screen every minute using the new functions. Bug: 15903322 Change-Id: I83bcc34503f1b87727d2b2b3c0ef08507f9f0808
/frameworks/base/core/java/android/os/PowerManagerInternal.java
|
2c43c339de5aaf4fef58aa9b5ac3af48609263a8 |
|
13-Jun-2014 |
Jeff Brown <jeffbrown@google.com> |
Resolve boot time dependencies related to the power manager. This change fixes a bug where native daemons may try to communicate with the power manager before it was fully initialized due to a race between publishing the binder service and completing init(). The solution was to simplify the dependencies related to the power manager. It turns out that most services that were passed in init are not actually needed until systemReady. What remained was a dependency on the activity manager to check permissions for incoming calls. So now we start activity manager first. However, the activity manager also depends on power manager for wakelocks. To break the cycle, we now defer initializing the activity manager's wakelocks until after the power manager has been started. Cleaned up a bunch of boot-time service dependencies so that we can have better confidence that they are correctly maintained. Bug: 13884219 Change-Id: If08e2d7ccd44e7026a72441bb6bd5afd7bb9fffe
/frameworks/base/core/java/android/os/PowerManagerInternal.java
|
cbefd8dd2befcb768f911a63becc427ec4c13250 |
|
14-May-2014 |
Dianne Hackborn <hackbod@google.com> |
Battery stats more wake history, power save mode. Add new option for battery stats to record the full wake lock history, and recording the current power save mode. Also add in some additional error constants when generating Binder error exceptions. And fix issue #14974572: Avoid repeating wakeup_reason at the beginning of history Change-Id: I7c1a2ab9569de216634f63d8ad69f1294ef1d235
/frameworks/base/core/java/android/os/PowerManagerInternal.java
|
4ccb823a9f62e57f9d221f83a97e82967e79a9e5 |
|
17-Jan-2014 |
Jeff Brown <jeffbrown@google.com> |
Refactor display manager service to new pattern. Transform DisplayManagerService into a SystemService and start cleaning up other local services that it uses from window manager and input manager. Clean up service thread initialization. Remove unnecessary static variables from ActivityManagerService. It's starting to become clear that we really need a better way to manage service dependencies. Boot phases don't quite cut it. Change-Id: If319dbd7cbfbd4812fe55ece969e818d4b20755b
/frameworks/base/core/java/android/os/PowerManagerInternal.java
|
6f357d3284a833cc50a990e14b39f389b8972254 |
|
16-Jan-2014 |
Jeff Brown <jeffbrown@google.com> |
Start untangling system server early bootstrapping. Refactored SystemServer to get rid of a bunch of legacy cruft related to how the ServerThread used to be started up. Create system context first when system server starts. This removes the tangled initialization order dependency that forced us to start the activity manager service before most anything else. Moved factory test related constants into the FactoryTest class. Partially migrated Installer, ActivityManagerService, and PowerManagerService to the new SystemService pattern. There's more work to be done here, particularly around the lifecycle of the power manager. Bug: 12172368 Change-Id: Ia527dd56e3b3fd90f9eeb41289dbe044921230d4
/frameworks/base/core/java/android/os/PowerManagerInternal.java
|