Commit Graph

4194 Commits

Author SHA1 Message Date
Dianne Hackborn
8b4c4f09f6 Merge "Fix issue #37360626: Apps can schedule alarms (and other things) with temp whitelist" into oc-dev
am: c3b938ca5e

Change-Id: I585bf57074064761c7d216f05be23d7f044208fa
2017-05-11 18:45:00 +00:00
Dianne Hackborn
c3b938ca5e Merge "Fix issue #37360626: Apps can schedule alarms (and other things) with temp whitelist" into oc-dev 2017-05-11 18:28:46 +00:00
Fyodor Kupolov
0e861d3e25 Merge "Added isUserNameSet" into oc-dev
am: a9154ab391

Change-Id: I013381eab8809b98d17e7cf9063a62e4884b0e2a
2017-05-11 05:22:19 +00:00
TreeHugger Robot
a9154ab391 Merge "Added isUserNameSet" into oc-dev 2017-05-11 03:19:52 +00:00
Michael Wachenschwanz
c7373d1f5e Merge "WTF Logging for catching memory issue in Parcel" into oc-dev
am: 9254322192

Change-Id: I2471901f1504c242b9020f575126c56375036498
2017-05-11 02:01:55 +00:00
Michael Wachenschwanz
9254322192 Merge "WTF Logging for catching memory issue in Parcel" into oc-dev 2017-05-11 01:26:11 +00:00
Dianne Hackborn
983055231b Fix issue #37360626: Apps can schedule alarms (and other things) with temp whitelist
There is now an IBinder "token" that must be specified when setting
the whitelist duration for an Intent.  To have the whitelist supplied,
the caller to send a PendingIntent must pass in the same token.  The
PendingIntent and IntentSender classes now internally maintain this token
to pass in when their send() is called.

The big complexity for making this work is we now need to associate this
whitelist token correctly with the actual PendingIntent objects that
applications and other code is getting.  To do this, we propagate the
token in the Notification object, and have a new API on Parcel that allows
us to make it available to PendingIntent when it is unmarshalled.  And
this allows to deal with PendingIntents appearing in nested bundles, as
we can propagate that information from the original Parcel to the new
Parcel that Bundle keeps to delay unmarshalling.

Test: manual
Change-Id: Idda00490ccfe2be37e4ab21354b9ab7528a52750
2017-05-10 17:23:02 -07:00
Fyodor Kupolov
605b12a6d0 Added isUserNameSet
It can be used to check that the value returned by getUserName() was set
by the user and is not a default value returned by the system.

Test: UserManagerServiceUserInfoTest pass
Bug: 38138381
Change-Id: I0ca37970fda548508190bffd1fa7be95d4a15076
2017-05-10 15:58:09 -07:00
Michael Wachenschwanz
101e38cbec WTF Logging for catching memory issue in Parcel
Catch an exception sent from native code looking for a specific known
bug and report via wtf which code path is hitting the bug. Revert this
change once bug has been resolved.

Bug: 37298089
Test: manual

Change-Id: Ieb98a8a82a9a2cffe4d0cfbbc8333f453b3e36d5
Signed-off-by: Michael Wachenschwanz <mwachens@google.com>
2017-05-10 15:38:30 -07:00
Bookatz
eb5a068cbc Merge "Add BLE results counter to batterystats" into oc-dev
am: 7080fa5282

Change-Id: I8e485d5a97d46f6787b5b32c17ab5b85463f2653
2017-05-09 17:08:03 +00:00
TreeHugger Robot
7080fa5282 Merge "Add BLE results counter to batterystats" into oc-dev 2017-05-09 16:03:27 +00:00
Bookatz
6103e0445f Merge changes from topic 'wakelockTotalDuration' into oc-dev
am: 6b1989c7e2

Change-Id: I04a7323ed927ebfad40129166d7e0cc61be7b3af
2017-05-08 18:57:34 +00:00
Bookatz
6d70b7aa2f Added actual (unpooled) partial wakelock times.
am: 506a8183fd

Change-Id: I684b9287bf7bec032da54c497744f863768917e2
2017-05-08 18:56:33 +00:00
TreeHugger Robot
6b1989c7e2 Merge changes from topic 'wakelockTotalDuration' into oc-dev
* changes:
  Wakelock durations are 0 instead of -1 if unused
  Added actual (unpooled) partial wakelock times.
2017-05-08 18:34:42 +00:00
Michael Wright
b9e1b02f72 Merge "Also log the value of the IAEs thrown in VibrationEffect" into oc-dev
am: 00487cf936

Change-Id: Iee08e297248aa57179a434f81f27e3e7924aa201
2017-05-08 14:53:51 +00:00
TreeHugger Robot
00487cf936 Merge "Also log the value of the IAEs thrown in VibrationEffect" into oc-dev 2017-05-08 14:49:27 +00:00
Yifan Hong
6d62f812e9 Merge "android.os.VintfObject: add API for EDI." into oc-dev
am: 718688f39b

Change-Id: I937b7972b40747e36b9fe3a2ff008c1052652962
2017-05-05 22:05:08 +00:00
TreeHugger Robot
718688f39b Merge "android.os.VintfObject: add API for EDI." into oc-dev 2017-05-05 21:47:47 +00:00
Yifan Hong
687113a082 android.os.VintfObject: add API for EDI.
Add APIs for EDI (extensive device information).

Test: CtsDeviceInfo
Bug: 28656227
Change-Id: I609d4f1f07e20717827ef024ff8cbe124d7e54a6
2017-05-04 14:11:22 -07:00
Ian Pedowitz
c96a358318 Merge "Revert "O is API 26"" into oc-dev
am: b42b9a22df

Change-Id: Ic869f9f6f627c960222cb5364e04e6f4491c0a88
2017-05-04 00:18:19 +00:00
Ian Pedowitz
b42b9a22df Merge "Revert "O is API 26"" into oc-dev 2017-05-04 00:07:10 +00:00
Yifan Hong
2e5ed49e86 Merge "Add compatibility matrices to VintfObject.report()" into oc-dev
am: 0e0a37635e

Change-Id: I6e2c660971c296f363b66baa43231e18464ffc34
2017-05-03 22:48:32 +00:00
Ian Pedowitz
12025857cd Revert "O is API 26"
This reverts commit 9bcef8e2da.

Reason for revert:  b/37355569

Bug: 37480230
Bug: 37355569
Change-Id: I39b4a7fd9bda77df0746c7bc32b87f0c2b722f2b
2017-05-03 22:00:56 +00:00
Tianjie Xu
f2e1a43ac5 Merge "Add error/cause code reporting for Non A/B OTA failures" am: 2db2f6d265 am: c2a0d6776c
am: 1b0da0cdfd

Change-Id: I967edc50dff44d830e475b94678c0194a379dba1
2017-05-03 17:56:39 +00:00
Yifan Hong
75ffd667a9 Add compatibility matrices to VintfObject.report()
Test: FrameworksCoreTests
Bug: 36814503
Change-Id: I27eaea136437afb2102581d410b657e810612a0a
2017-05-03 10:53:53 -07:00
Tianjie Xu
2db2f6d265 Merge "Add error/cause code reporting for Non A/B OTA failures" 2017-05-03 17:34:29 +00:00
Michael Wright
0ef6edd0a5 Also log the value of the IAEs thrown in VibrationEffect
Bug: 36827833
Test: manual
Change-Id: I64b85e746bd046a2718b690cc21c897950e34050
2017-05-03 15:05:46 +01:00
Jorim Jaggi
53f6c02354 Merge "Fix lock contention: Call into power manager service from handler" into oc-dev
am: 251894b134

Change-Id: I63323963266b4194f61c8e6d6cc30a63f9af78eb
2017-05-03 13:21:52 +00:00
TreeHugger Robot
251894b134 Merge "Fix lock contention: Call into power manager service from handler" into oc-dev 2017-05-03 13:16:32 +00:00
Jorim Jaggi
86c39f9ede Fix lock contention: Call into power manager service from handler
Make sure to not hold the wm lock when calling into power manager
service, because PWM will acquire a lock that might be contended.

Test: Make sure user activity timeout is still respected on
Keyguard
Test: Have activity with screenBrightness=1.0, make sure screen
is fully bright when opened

Bug: 37888898
Bug: 36631902
Change-Id: I4b5433dbaf8aa151465ae32232d3b3b8597715df
2017-05-03 13:22:47 +02:00
Tianjie Xu
223edeb272 Add error/cause code reporting for Non A/B OTA failures
Read and report the error_code & cause_code from last_install.

Bug: 36866437
Test: mma & observe the sysui event in logcat -b events
Change-Id: I5357861fc758e14ed3235bfc8cc76d7561ccea58
2017-05-02 23:02:11 -07:00
Bookatz
941d98feba Wakelock durations are 0 instead of -1 if unused
Previously, wakelock max/current/total durations were initialized to -1,
instead of 0. So if, e.g., an app held a full wakelock but not a partial
wakelock, then the partial wakelock would return -1 for these data. This
cl changes that to be 0. The value will only be -1 if the data is not
tracked (as is currently the case for full and window wakelocks), in
which case if the wakelock was held, -1 will be given to signify the
lack of tracking.

Test: manually confirm 0 instead of -1 in batterystats dump.
Change-Id: I934022294ba5adafb2e4d9a5be1dc20aab045cb0
2017-05-02 19:25:18 -07:00
Michael Wright
8433705f77 Merge "O is API 26" into oc-dev
am: 074a67c116

Change-Id: Ie1d9b8ebb3b1c1693bbce5bf7f7d1f8c7159e54e
2017-05-02 22:17:25 +00:00
Michael Wright
9bcef8e2da O is API 26
Bug: 37480230
Test: build, boot
Change-Id: Idfa91e1e094606f92c4141beb8569c241c639ee1
2017-05-02 19:23:12 +01:00
Bookatz
506a8183fd Added actual (unpooled) partial wakelock times.
Previously, partial wakelock times reported the blame apportioned to the
app (i.e. the times were pooled). This CL adds another field to provide
the actual time the partial wakelock was held (unpooled, irrespective of
other app's wakelock usage). Full and window wakelocks also now have the
equivalent field, but it always returns -1 (like their max and current
durations), since none of those are currently tracked. Kernel wakelocks
are unchanged.

Test: cts-tradefed run cts-dev -m CtsDumpsysHostTestCases -t android.dumpsys.cts.BatteryStatsDumpsysTest
Bug: 18998184
Change-Id: Ic4cc8c3abba9afa60902d0c8e17e11abeef52a96
2017-05-02 11:16:55 -07:00
Yifan Hong
9f95b592f8 Add android.os.VintfRuntimeInfo
This is the Java API for ::android::vintf::RuntimeInfo.
This will be used by CTS for device info report purposes.

Bug: 28656227
Test: cts-tradefed run cts -m CtsEdiHostTestCases --skip-preconditions
Change-Id: Id87c95a17e77d7ec1794a6f850de97edf9ae892d
2017-05-01 13:00:04 -07:00
Jeff Sharkey
e13d60764c Merge "Updates based on API council guidance." into oc-dev
am: 3ba7117164

Change-Id: I75953e083e10972dcc44c431ff84bf3977e8d442
2017-05-01 18:43:12 +00:00
Jeff Sharkey
3ba7117164 Merge "Updates based on API council guidance." into oc-dev 2017-05-01 18:36:25 +00:00
Salvador Martinez
ba1cc4bb42 Merge "Added dialog to notify user of thermal shutdown" into oc-dev
am: 4d09adcef1

Change-Id: Ic53481e2aa95146bc33c21174b1a50f62bdc8851
2017-05-01 16:55:44 +00:00
Salvador Martinez
4d09adcef1 Merge "Added dialog to notify user of thermal shutdown" into oc-dev 2017-05-01 16:45:30 +00:00
Jeff Sharkey
000ce80505 Updates based on API council guidance.
Test: builds, boots
Change-Id: I223faf55c1e1b4d81d11b4c8b2d93ccd131c969b
Fixes: 37775662
Fixes: 37748635
Fixes: 37673408
Fixes: 37672564
Fixes: 37672218
Fixes: 37638323
Fixes: 37637423
2017-04-29 13:14:17 -06:00
Yifan Hong
6196ab62fb Merge "Add android.os.VintfRuntimeInfo" am: 4f8a375958 am: e0bf06dd9e
am: 5fe979b404

Change-Id: Iae202b22ecc136343d82711435d49ce3597fa74f
2017-04-29 03:19:09 +00:00
Treehugger Robot
4f8a375958 Merge "Add android.os.VintfRuntimeInfo" 2017-04-29 03:00:08 +00:00
Yifan Hong
1bda67369c Add android.os.VintfRuntimeInfo
This is the Java API for ::android::vintf::RuntimeInfo.
This will be used by CTS for device info report purposes.

Bug: 28656227
Test: cts-tradefed run cts -m CtsEdiHostTestCases --skip-preconditions
Change-Id: Id87c95a17e77d7ec1794a6f850de97edf9ae892d
2017-04-28 17:10:28 -07:00
Bookatz
956f36bfe2 Add BLE results counter to batterystats
Batterystats provides an API to count the number of BLE scan results.

Bug: 37720787
Test: runtest -x frameworks/base/core/tests/coretests/src/com/android/internal/os/BatteryStatsTests.java
Change-Id: Idcb7494b39e88dcbfbb3da1ebe90b8a2f8f4d55c
2017-04-28 11:03:38 -07:00
Jeff Sharkey
1737e50fa1 Merge "@hide non-Handler variant of SM.openProxyFileDescriptor" into oc-dev
am: 4315c1e3d5

Change-Id: I8ec2d24a8b6bda9641bbb627e69521914240942f
2017-04-28 17:38:33 +00:00
Jeff Sharkey
86e27f65f8 Merge "Respond to API council feedback." into oc-dev
am: 77cc43e0d2

Change-Id: I0c2b86d34cfd2b2f5b94bc693657b40ecbd764fe
2017-04-28 17:27:53 +00:00
Jeff Sharkey
4315c1e3d5 Merge "@hide non-Handler variant of SM.openProxyFileDescriptor" into oc-dev 2017-04-28 17:10:26 +00:00
TreeHugger Robot
77cc43e0d2 Merge "Respond to API council feedback." into oc-dev 2017-04-28 17:10:16 +00:00
Pavel Grafov
776158ba4f Merge "Introduce DISALLOW_BLUETOOTH_SHARING." into oc-dev
am: 90357d62e9

Change-Id: I925165817781c3b0f4e37afe8ebcce1ac264d775
2017-04-28 14:23:42 +00:00