Commit Graph

253881 Commits

Author SHA1 Message Date
Sudheer Shanka
badc5cd942 Merge "DO NOT MERGE: Clean up when recycling a pid with a pending launch" into nyc-dev 2016-08-19 17:06:49 +00:00
Phil Weaver
c34649411d Dispatch a11y events in separate thread.
Moves the IPCs into a separate thread, where they should affect
jank a lot less.

Bug: 30183085
Change-Id: Ib76159d158e7a867e76cdd5c8ea3a318949fcc5b
2016-08-19 09:22:10 -07:00
Greg Kaiser
f8210797ad ContextHubService: Make app handle size match Java
Our code was sometimes using 'uint32_t' and mostly using 'int'
to represent these custom handles.  It was also passing this
value, as a byte stream, to the Java layer.

In the Java layer, this is an 'int', and thus we change all
of our usages to be 'jint' here.  However, we still pass it
as a byte stream, since we're too late in the release cycle
to change the API.  But now this is at least a consistent
size for the code.

This code still suffers from hub handles being inconsistent
with their types, but we leave that for another bug (b/30958512).

Bug: 30806218
Change-Id: I8d9ae8b9519f399d6723cf96293d84a2f5bd9cce
2016-08-19 09:13:52 -07:00
Greg Kaiser
0d052c9508 ContextHubService: Update caches on nanoapp unload
When we unloaded a nanoapp, we weren't updating the cache of
nanoapp information at the ContextHubServer java layer.  Also,
we were leaking the handle.

We fix both of these by invoking the shared delete_app_instance()
function which properly handles all of this.

Furthermore, we allow delete_app_instance() to accept a nullptr
for the JNIEnv, and fix invalidateNanoApps() so that it won't
crash if it's unable to connect to the JVM.

Note that our Java communication in general here should be
cleaned up, but we're too late in the release cycle for
that, and leave that for b/30961119.

Bug: 30951974, 30968860
Change-Id: Ibb07666a8d54618bddaa3eaf36f9578926eb2b0f
2016-08-19 09:13:52 -07:00
TreeHugger Robot
4ecc9d2db4 Merge "Import translations. DO NOT MERGE" into nyc-mr1-dev 2016-08-19 15:28:29 +00:00
Tyler Gunn
9df655a443 Merge "Add connection events for indicated when a connection is remotely held." into nyc-mr1-dev 2016-08-19 14:28:08 +00:00
Scott Main
c4fb0012e1 Merge "fix redirect for AIDL doc bug: 5967288" into nyc-dev am: 66ffbbfdf9
am: 97d6427ab0

Change-Id: Ic8a4e3c86fed503333e6f46d62ad4fd492430547
2016-08-19 13:29:14 +00:00
smain@google.com
97fd094458 fix redirect for AIDL doc bug: 5967288 am: 9ad944f8c9
am: 3872e56f69

Change-Id: I19e1cb6e9f79edb9755afb66cce4a67db9428f7f
2016-08-19 13:29:12 +00:00
Narayan Kamath
e3cb8a7db9 Merge "Process: Fix communication with zygote." into nyc-dev am: cce8af824a
am: b8f0cd0248

Change-Id: I49cd6679da56f5f853c17c741064db88431ded8c
2016-08-19 13:29:10 +00:00
Narayan Kamath
b060316945 Process: Fix communication with zygote. am: 448be0a622
am: 99f960f7da

Change-Id: I471c81919cce6725433895c3d20ca22a8e827b98
2016-08-19 13:29:07 +00:00
Bill Yi
02799d57d7 Import translations. DO NOT MERGE
Change-Id: I89cc90bed937b12a939bd4c43f0a6ee834ce088a
Auto-generated-cl: translation import
2016-08-19 04:31:46 -07:00
Rubin Xu
9201a30a95 Set DeviceLockedForUser state synchronously
Setting DeviceLockedForUser on the handler thread will lead to a race
condition where an immedidate read might see a stale value.

Bug: 30728557
Change-Id: Id9d510d7ad4dbcde6344a044e45f4b2feac19257
2016-08-19 11:37:14 +01:00
Jim Miller
b6f4b48df2 Bind fingerprint when we start authentication - DO NOT MERGE
This fixes a bug where it was possible to authenticate the wrong user.
We now bind the userId when we start authentication and confirm it when
authentication completes.

Fixes bug 30744668

Change-Id: I346d92c301414ed81e11fa9c171584c7ae4341c2
2016-08-19 03:46:40 +00:00
Svetoslav Ganov
d44d46aa50 Add resource based mechanism to grant default permissions
This CL adds a mechanism for an OEM to grant default permissions
using the build system. This allows permissions for which they
got default grant exceptions to be added without modifying the
platform code. The format is a simple XML listing the packages
and the permissions to be granted for a package. The XML file
is placed in etc/default-permissions.

bug:29546655
bug:30929033

Change-Id: Ib6d671dac9201812bd2c47010c2c4b1330ef6b6e
2016-08-18 18:39:33 -07:00
Scott Main
97d6427ab0 Merge "fix redirect for AIDL doc bug: 5967288" into nyc-dev
am: 66ffbbfdf9

Change-Id: Ib72ec2497e7b58c42ecca05cc318d7345e9fce69
2016-08-19 01:12:09 +00:00
smain@google.com
3872e56f69 fix redirect for AIDL doc bug: 5967288
am: 9ad944f8c9

Change-Id: I8614af80ea19a68d078ea578d2f8e7a3286f930a
2016-08-19 01:12:05 +00:00
Scott Main
66ffbbfdf9 Merge "fix redirect for AIDL doc bug: 5967288" into nyc-dev 2016-08-19 01:04:03 +00:00
Dianne Hackborn
e9563659a5 Fix issue #30929080: Default Assist app is set to None...
...on removing the third pary search app

We weren't taking into account old style assistants when determining
whether something interesting had been removed.

Change-Id: I6b7b09cdf0781622924e10556d678565570dbd05
2016-08-18 17:33:41 -07:00
TreeHugger Robot
1b58e1c821 Merge "Isolated processes don't get precached system service binders" into nyc-mr1-dev 2016-08-19 00:29:36 +00:00
Svetoslav Ganov
9a6008a334 Merge "Add resource based mechanism to grant default permissions" into nyc-mr1-dev 2016-08-18 23:38:34 +00:00
TreeHugger Robot
42b14329f5 Merge "Release mPackages lock earlier" into nyc-mr1-dev 2016-08-18 23:16:04 +00:00
Narayan Kamath
b8f0cd0248 Merge "Process: Fix communication with zygote." into nyc-dev
am: cce8af824a

Change-Id: I9e945b2a660d5daf57d7c51e8e7c9d814e78a728
2016-08-18 23:08:51 +00:00
Narayan Kamath
99f960f7da Process: Fix communication with zygote.
am: 448be0a622

Change-Id: I530a1f04545a796d22ca59141aa8fe3de349388c
2016-08-18 23:08:49 +00:00
George Mount
2613fb543a Merge "Fix NPE during Activity transition using wrong Activity." into nyc-mr1-dev 2016-08-18 22:27:31 +00:00
Andy Hung
47c7a8c19a Merge "AudioSystem: Verify audio port array information" into nyc-mr1-dev 2016-08-18 22:25:20 +00:00
smain@google.com
9ad944f8c9 fix redirect for AIDL doc
bug: 5967288

Change-Id: Ia2a4cbdde56d2e6baca4c5f74ea92bb7bfaf2938
2016-08-18 14:41:47 -07:00
Tim Murray
bb4e37c602 Merge "Prevent FIFO threads from creating more FIFO threads." into nyc-mr1-dev 2016-08-18 20:25:38 +00:00
Svet Ganov
59020bffb7 Add resource based mechanism to grant default permissions
This CL adds a mechanism for an OEM to grant default permissions
using the build system. This allows permissions for which they
got default grant exceptions to be added without modifying the
platform code. The format is a simple XML listing the packages
and the permissions to be granted for a package. The XML file
is placed in etc/default-permissions.

bug:29546655
bug:30929033

Change-Id: Ifb0516d7e2d0b399532024438bc0f86068a2e4e2
2016-08-18 19:52:15 +00:00
Svetoslav Ganov
6642c963d9 Merge "Grab lock when accessing mutable state" into nyc-mr1-dev 2016-08-18 19:05:49 +00:00
Todd Kennedy
a8d4f48997 Release mPackages lock earlier
We cannot hold mPackages when calling into generatePackageDexopts().
This method takes Package Manager's mInstallLock. By holding mPackages,
we have lock inversion and hilarity ensues.

Change-Id: Ia11a158677051e3511702f38cde6780e75b256fb
Fixes: 30927731
2016-08-18 11:22:52 -07:00
Philip P. Moltmann
366262dc78 Only have a single call into pdfium at a time.
Pdfium is not thread safe and uses global variables, hence no
parallel call pdfium is safe

Fixes: 28705066
Change-Id: I04309ee691bd9cea37587e0af5be2c07ce8c9f2c
(cherry picked from commit 0768a7dc45)
2016-08-18 18:20:59 +00:00
Tim Murray
38ee337f45 Prevent FIFO threads from creating more FIFO threads.
SCHED_FIFO threads shouldn't be able to arbitrarily create more
SCHED_FIFO threads.

bug 30898724

Change-Id: I3704b47b88b573313e9b1610556648c8595d4108
2016-08-18 11:14:15 -07:00
Christopher Tate
2c61c57ac5 Isolated processes don't get precached system service binders
More specifically, they get a PackageManager binder -- necessary for
Android process startup and configuration -- but none of the other
usual preloaded service binders.

Bug 30202228

Change-Id: I3810649f504cd631665ece338a83d2e54d41ad05
2016-08-18 10:15:59 -07:00
George Mount
a3edbf6a5d Fix NPE during Activity transition using wrong Activity.
Bug 30786309

If the Activity used in makeSceneTransitionAnimation isn't
the same one used in the startActivity call, a NullPointerException
could be thrown.

Change-Id: Id21c54fcf99b353feab62f7fc160997ed06e7d23
(cherry picked from commit 3289bfa289)
2016-08-18 17:15:43 +00:00
Ajay Panicker
9a236066db Protect various Bluetooth broadcasts
Bug: 30832954
Change-Id: I37e0b2ffab65c0703244917a4ade9bb8afbb5e6f
2016-08-18 17:10:58 +00:00
Felipe Leme
f8dd7b4e8d Removed screen on/off callbacks from NPMS.
NetworkPolicyManagerService (NPMS) used to depend on screen on/off
changes to determine if a foreground activity should have network
restrictions, but such check is now redundant since ActivityManager
already changes the proper UID state (like going from TOP to
TOP_SLEEPING) when the screen status is changed.

Removing such code decreases the NPMS lock contention when the screen is
turned on in about 3-5ms.

Change-Id: I2853443efedbf14961ae9a5b2e72689d4d1a646c
BUG: 30785671
(cherry picked from commit 88f40ad9a7)
2016-08-18 09:57:11 -07:00
Narayan Kamath
c6c7ca0cde Merge "Process: Fix communication with zygote." into klp-dev am: 6829cf28e2 am: 8fdee85e87 am: 4cf5241f47 am: efab128e67
am: 86437ec433

Change-Id: If18135c4aebd55fa9a1f08e275dbfef3dc433b5e
2016-08-18 10:30:00 +00:00
Narayan Kamath
3c63bb367f Process: Fix communication with zygote. am: 8e69dd2284 am: b85e9e9108 am: b56f4f53e1 -s ours am: 2984748753
am: b9fae65605

Change-Id: I3df204c005d61091f83e6ee2bd6bcd2a63a68c2b
2016-08-18 10:29:55 +00:00
Narayan Kamath
86437ec433 Merge "Process: Fix communication with zygote." into klp-dev am: 6829cf28e2 am: 8fdee85e87 am: 4cf5241f47
am: efab128e67

Change-Id: I7159b2996f35311a630cdb7b2646c0e94d159c1f
2016-08-18 10:23:23 +00:00
Narayan Kamath
b9fae65605 Process: Fix communication with zygote. am: 8e69dd2284 am: b85e9e9108 am: b56f4f53e1 -s ours
am: 2984748753

Change-Id: Id9f73afcbc747e3e341c5cfa665e4929747fdbac
2016-08-18 10:23:20 +00:00
Narayan Kamath
e24a4590bf Merge "Process: Fix communication with zygote." into nyc-dev
am: cce8af824a

Change-Id: I1086785cde9f5d9bbdff84b225c4d20582977c75
2016-08-18 10:20:00 +00:00
Narayan Kamath
ac16712d8a Process: Fix communication with zygote.
am: 448be0a622

Change-Id: I5d496613f53c339c75a3293845670d9d8360c90f
2016-08-18 10:19:57 +00:00
Narayan Kamath
efab128e67 Merge "Process: Fix communication with zygote." into klp-dev am: 6829cf28e2 am: 8fdee85e87
am: 4cf5241f47

Change-Id: Ibd736c16c8af9397e774c5abb917a9a3d31681a0
2016-08-18 10:19:28 +00:00
Narayan Kamath
2984748753 Process: Fix communication with zygote. am: 8e69dd2284 am: b85e9e9108
am: b56f4f53e1  -s ours

Change-Id: I67e1ff67c88d8c70a9d6d0698c857be77f09f534
2016-08-18 10:16:48 +00:00
Narayan Kamath
cce8af824a Merge "Process: Fix communication with zygote." into nyc-dev 2016-08-18 10:14:31 +00:00
Narayan Kamath
8788a2413c Process: Fix communication with zygote. am: e29c6493c0
am: 1bd43c162f

Change-Id: Ic38c43db48584b3d899e120fd65a4058d806a39f
2016-08-18 09:58:45 +00:00
Narayan Kamath
4cf5241f47 Merge "Process: Fix communication with zygote." into klp-dev am: 6829cf28e2
am: 8fdee85e87

Change-Id: I654191bebb88a8005e9f46ad8b8b1f932214b3c9
2016-08-18 09:56:29 +00:00
Narayan Kamath
b56f4f53e1 Process: Fix communication with zygote. am: 8e69dd2284
am: b85e9e9108

Change-Id: Ie4874c088e05f4f5bc2073661010d413e60b3f7b
2016-08-18 09:56:24 +00:00
Narayan Kamath
1bd43c162f Process: Fix communication with zygote.
am: e29c6493c0

Change-Id: I86b073f7f69943911aa0bea782e29ae6d86609a2
2016-08-18 09:53:12 +00:00
Narayan Kamath
8fdee85e87 Merge "Process: Fix communication with zygote." into klp-dev
am: 6829cf28e2

Change-Id: I740364ba90a8d1f14a5b2d2aacfe44948a4583d2
2016-08-18 09:50:56 +00:00