16020 Commits

Author SHA1 Message Date
Craig Mautner
53cc7d7998 am 7611a5d3: am 5acdd0f6: Merge "[ActivityManager] Ensure alive process is not killedByAm."
* commit '7611a5d32889f54b1763cf076a442a0575c69b51':
  [ActivityManager] Ensure alive process is not killedByAm.
2014-07-07 15:06:41 +00:00
Craig Mautner
7611a5d328 am 5acdd0f6: Merge "[ActivityManager] Ensure alive process is not killedByAm."
* commit '5acdd0f67db9b5f41a89dfb5200f37d6f5f984ec':
  [ActivityManager] Ensure alive process is not killedByAm.
2014-07-07 15:00:47 +00:00
riddle_hsu
abc69e93d6 [ActivityManager] Ensure alive process is not killedByAm.
Symptom: Unable to kill by Am again and will be skipped updating its oom adj.

Root Cause:
A restarted process will reuse original process record.
The flag killedByAm will keep previous state.

Solution:
Reset the flag killedByAm to false when the process is started.

Note: Found another similiar patch If95137d91939cc44882ad2813131bcde0edd0c1b


Change-Id: I59a86648ca8d0aed4c489d92751af120aae5ef90
2014-07-04 13:33:19 +00:00
Narayan Kamath
dbbc070670 am e2840977: am 6e84f8c1: Merge "Fix native crashes when APKs can\'t be opened."
* commit 'e2840977d37e4d19425d448b54895536e43a2989':
  Fix native crashes when APKs can't be opened.
2014-07-02 12:18:45 +00:00
Narayan Kamath
e2840977d3 am 6e84f8c1: Merge "Fix native crashes when APKs can\'t be opened."
* commit '6e84f8c1b9c72ab6e1eb189358292237dbe1efe8':
  Fix native crashes when APKs can't be opened.
2014-07-02 12:12:18 +00:00
Nick Kralevich
db32fb646d am d172419e: am 9b1a7d45: Merge "Allow different SELinux policies for third party apps."
* commit 'd172419e9a36f61af8c98d316ec2625e1f1304f6':
  Allow different SELinux policies for third party apps.
2014-07-01 21:16:14 +00:00
Nick Kralevich
d172419e9a am 9b1a7d45: Merge "Allow different SELinux policies for third party apps."
* commit '9b1a7d4570dd692cf86c385dfcdf057ad966fa57':
  Allow different SELinux policies for third party apps.
2014-07-01 21:13:12 +00:00
Robert Craig
83b54ecab7 Allow different SELinux policies for third party apps.
Prior support forced all third party apps
to be resolved against the default stanza
of the mac_permissions.xml file when assigning
seinfo labels. This meant that all third party
apps, in effect, were untrusted regardless of
cert and therefore received the same selinux domain.
This also had the unfortunate side effect of forcing
certain third party apps into the wrong domains
because of shared userid requests among apps.

This patch removes that restriction and instead
allows all apps, regardless of location, to be
matched against the full mac_permissions.xml
policy file. This then allows all apps signed
with known good certs to receive the same selinux
domains of other apps with whom they share trust.

Change-Id: Iba569c046135c0e81140faf6296c5da26a243037
Signed-off-by: rpcraig <rpcraig@tycho.ncsc.mil>
2014-07-01 13:53:11 -07:00
Narayan Kamath
6e84f8c1b9 Merge "Fix native crashes when APKs can't be opened." 2014-07-01 17:48:27 +00:00
Narayan Kamath
ec4516470d Fix native crashes when APKs can't be opened.
There was lax / incomplete error checking around the
construction of Apk handles. This change changes the ApkHandle
API and makes it throw IOException if the zipfile couldn't
be opened.

Additionally :
- Fix a resource leak in DefaultContainerService
- Report errors correctly during package moves.

bug: 15563874
Change-Id: Ic71a10709eb82b8f53405bbfb2320e80aa96b771
2014-06-30 17:14:29 +01:00
Narayan Kamath
152d5cd30b am 22a32d88: am 2a0f9e6a: Merge "Explicitly list out the list of cache subdirs to prune."
* commit '22a32d883794a7a96ff5ffb4830ea59065b3ebda':
  Explicitly list out the list of cache subdirs to prune.
2014-06-24 12:19:10 +00:00
Narayan Kamath
22a32d8837 am 2a0f9e6a: Merge "Explicitly list out the list of cache subdirs to prune."
* commit '2a0f9e6a523abc28bdbc249010f5ddd184a27730':
  Explicitly list out the list of cache subdirs to prune.
2014-06-24 12:14:12 +00:00
Narayan Kamath
2a0f9e6a52 Merge "Explicitly list out the list of cache subdirs to prune." 2014-06-24 06:33:30 +00:00
Jianzheng Zhou
78c8e7c8bf DO NOT MERGE refactor wifi p2p's startDhcpServer function
Add getTetheredDhcpRanges() interface and call it before calling
mNwService.startTethering() to update dhcp ranges. This will allow p2p app
to run well concurrently with other tethering app(e.g. usb tethering).

Change-Id: I5e8ffeb5d2d396f48b897cd9396f133e25ecca57
Signed-off-by: Jianzheng Zhou <jianzheng.zhou@freescale.com>
2014-06-23 21:02:45 +00:00
Brian Carlstrom
9e36a8cd3e am 1b98ccf2: am 0924ef65: Merge "Treat missing package usage data as a separate case"
* commit '1b98ccf275d93197c1aa746d5c492a57cd62be7f':
  Treat missing package usage data as a separate case
2014-06-23 15:47:45 +00:00
Craig Mautner
9587ee0203 am a2121e49: am 5957d6a8: Merge "Fix frontOfTask assignment."
* commit 'a2121e497c2e82676b4bf5dc35b0015c38ddc5ab':
  Fix frontOfTask assignment.
2014-06-23 15:00:10 +00:00
Craig Mautner
aaadf92210 am 90c9fffc: Merge "Do not delete stack if empty task is being reused." into klp-modular-dev
* commit '90c9fffc956589f06d4a0c45a893c5db6a85fabc':
  Do not delete stack if empty task is being reused.
2014-06-21 20:15:36 +00:00
Brian Carlstrom
0924ef6592 Merge "Treat missing package usage data as a separate case" 2014-06-21 03:13:40 +00:00
Danny Baumann
ec4e780e5c Fix frontOfTask assignment.
If all activities of a given stack were finishing, no activity was
marked as front-of-task. This confused ActivityManager, so make sure
there's always exactly one activity marked as front-of-task.

Change-Id: I087cbe10280d4a60aa5ccfaefe24a223523fb3f2
2014-06-23 08:43:37 +02:00
Brian Carlstrom
0547ce55eb Treat missing package usage data as a separate case
Bug: 15520936
Change-Id: I8e1c6921973f84af7ee94de91721cc4a3436ebaf
2014-06-20 12:53:19 -07:00
Craig Mautner
362449af58 Do not delete stack if empty task is being reused.
If a task is being cleared due to Intent flags and that clearing
was causing the last activity in the last task on a stack to be
deleted, then we were deleting the stack. Immediately after
this we were refilling the task with the same activity but the
stack had already been deleted.

This fix preserves the task and stack when it is only being
cleared for the new activity.

Fixes bug 15611901.

Change-Id: I7bcfa826d0852d9c640daa73fe1324b89471fecd
2014-06-20 14:04:39 -07:00
Griff Hazen
a2d30107c4 am f546eeb1: Merge "DO NOT MERGE Reduce chance of notification listener dropped messages." into klp-modular-dev
* commit 'f546eeb1ede3c33ca3ec7fff6b8deb9d4e5cbc3e':
  DO NOT MERGE Reduce chance of notification listener dropped messages.
2014-06-18 03:18:24 +00:00
Griff Hazen
2ea0d3979e DO NOT MERGE Reduce chance of notification listener dropped messages.
The existing code for notification manager/listeners uses a oneway
binder api to deliver messages. One problem with this is that
notification objects can sometimes get fairly large, and can bump
into the oneway binder transaction buffer if many happen at once.

To reduce this issue, flip the service into a oneway delivery of
a status bar notification holder, whose wrapped content is then
immediately fetched upon receipt of the one-way message. This moves
the meat of the fetch to be over a two-way interface without changing
the properties of which object is actually sent (a tickle solution
with lookup key would have changed this)

Further research: attempt to chunk notification objects themselves.
They can sometimes transfer hundreds of KB over a binder transaction.

Bug: 15426276
Change-Id: Ib1a1f4ff848c16f80bcf2ae4dfd2b87a9091f0b2
2014-06-17 20:06:45 -07:00
Narayan Kamath
8df5bd08c2 Explicitly list out the list of cache subdirs to prune.
We don't want directories like profiles and the former
profile-cache from being included in the prune. SELinux would
have prevented the move, but that's very brittle.

bug: 15677279

Change-Id: I2ff5db056757ffacaf108bb07b02dc0cac7172dd
2014-06-17 13:07:45 +01:00
Dan Albert
7bd2992504 Use openssl's SHA1 instead of bionic's.
Bionic is removing its SHA1.

Change-Id: I2b2d028223d2299666511a683cffba29c55639b7
2014-06-16 17:01:21 -07:00
Narayan Kamath
5406f59abd am 6a6411e3: am 076dc013: Merge "Move dex file pruning to installd."
* commit '6a6411e3d8c533a40bfe1897e2c26e3d6f3b52e0':
  Move dex file pruning to installd.
2014-06-16 13:54:10 +00:00
Craig Mautner
916cd9770c am 6335fbcb: Revert "Revert "Close ActivityView and ActivityContainer cleanly.""
* commit '6335fbcba106147d914acae0a9d8f4fcd53af768':
  Revert "Revert "Close ActivityView and ActivityContainer cleanly.""
2014-06-14 00:30:47 +00:00
Craig Mautner
4019037540 am 6fe2184b: Do not treat the dummy animation as an animation
* commit '6fe2184bf10362ac53db7e8f6a0be521ea59b054':
  Do not treat the dummy animation as an animation
2014-06-14 00:22:36 +00:00
Craig Mautner
6335fbcba1 Revert "Revert "Close ActivityView and ActivityContainer cleanly.""
This reverts commit dd5c94717077c9366dee364c88a86a78e5ee2688.
2014-06-13 17:18:47 -07:00
Craig Mautner
6fe2184bf1 Do not treat the dummy animation as an animation
The dummy animation is a place holder. When the task stack is being
removed treating it as a true animation forced us through a path
where we deferred the detachment and made a call to tmpRemoveWindows.

Also replaced call to tmpRemoveWindows with a real remove windows
call. The tmpRemoveWindows call does not clean up the Session
and this leaves a surface on the screen.

Fixes bug 15591610.

Change-Id: I05f7bc276bfed2366bbcd8443c92a4bbbc8a4491
2014-06-13 15:46:22 -07:00
Justin Koh
0f3d3dd26c am dd5c9471: Revert "Close ActivityView and ActivityContainer cleanly."
* commit 'dd5c94717077c9366dee364c88a86a78e5ee2688':
  Revert "Close ActivityView and ActivityContainer cleanly."
2014-06-13 17:27:48 +00:00
Justin Koh
dd5c947170 Revert "Close ActivityView and ActivityContainer cleanly."
This reverts commit 4a9f129874785d34930f165268dbc618e4bc2618.

Conflicts:
	services/core/java/com/android/server/am/ActivityStackSupervisor.java

Change-Id: Ic1f4df7f4cb644de7ddebcdc8ce632b46c5ba8f2
2014-06-13 09:55:09 -07:00
Craig Mautner
4849aa86b1 am be634951: Fix permission problem and NPE
* commit 'be63495101dba3b0c3c496cdd810df9e30e926d4':
  Fix permission problem and NPE
2014-06-12 23:36:54 +00:00
Nick Kralevich
50ece5ec53 am 9a0485aa: am 1ef888e5: Merge "Add service_contexts to policy update bundles."
* commit '9a0485aa567c99157e45d08e9712a281f34ffc5f':
  Add service_contexts to policy update bundles.
2014-06-12 21:10:30 +00:00
Craig Mautner
be63495101 Fix permission problem and NPE
Remove uid before calling into Window Manager. Restore afterwards.

Check for null stack value before dereferencing.

Fixes bug 15591112.

Change-Id: Ida3de556940440162c91b8c1614d0f21e364abd8
2014-06-12 13:50:53 -07:00
Riley Spahn
5f5cf5f670 Add service_contexts to policy update bundles.
Add service_context file to SELinuxPolicyInstallReceiver
to allow updating.

Bug: 12909011
Change-Id: Ic0ad89958cc750413787d57e0f51363212a8730b
2014-06-12 20:46:34 +00:00
Craig Mautner
f5030ecbca am 4a9f1298: Close ActivityView and ActivityContainer cleanly.
* commit '4a9f129874785d34930f165268dbc618e4bc2618':
  Close ActivityView and ActivityContainer cleanly.
2014-06-12 00:00:17 +00:00
Craig Mautner
4a9f129874 Close ActivityView and ActivityContainer cleanly.
- Do not call IActivityContainer.release() from
ActivityView.finalize() if it has already been called from
ActivityView.release(). Eliminates IBinder finalized Exception.

- Call ActivityRecord.makeFinishing() before calling ActivityStack.
destroyActivityLocked(). Forces call to scheduleDestroyActivity()
and eventually removeFromHistory(). Otherwise removeFromHistory()
is never called and window manager AppWindowTokens become orphans.

- Defer call to ActivityContainer.detachLocked() until all
activities have finished or timed out. Fixes problem where Display
is removed while activities are still launching.

- Call ActivityStackSupervisor.deleteActivityContainer() when all
activities have finished or timed out. Fixes orphaned
ActivityContainers.

Fixes bug 15450798.
Fixes bug 15484154.
Fixes bug 15383479.
Fixes bug 15316558.
Fixes bug 15168560.
Fixes bug 15143914.

Change-Id: Id3c641976b6f825458690f9ee063c07818b56f23
2014-06-11 16:33:00 -07:00
Craig Mautner
28084383c1 am e33010a2: Merge "Add NO_ANIMATION flag to ActivityView Intents." into klp-modular-dev
* commit 'e33010a261d881426ce0af9a9e2177137ec3f6b9':
  Add NO_ANIMATION flag to ActivityView Intents.
2014-06-11 17:42:06 +00:00
Craig Mautner
e33010a261 Merge "Add NO_ANIMATION flag to ActivityView Intents." into klp-modular-dev 2014-06-11 08:41:11 +00:00
Griff Hazen
579ace0358 am 9f637d10: Reduce notification service historical archive size to 1 for watches. To remove the memory footprint
* commit '9f637d10959490c3a28e0f40330e97eb67e954d7':
  Reduce notification service historical archive size to 1 for watches. To remove the memory footprint
2014-06-11 01:18:36 +00:00
Griff Hazen
9f637d1095 Reduce notification service historical archive size to 1 for watches.
To remove the memory footprint

Bug: 15536759
Change-Id: I081bd962fef689b5d8ed126208499d56ebf4ae38
2014-06-10 15:31:48 -07:00
Narayan Kamath
5b95e02684 Move dex file pruning to installd.
Companion change for commit 7dbf95cd7606e22267
in frameworks/native.

bug: 14407732
Change-Id: I520aa3950fb6b87c7ca5a805e597d734496407d3
2014-06-16 13:59:21 +01:00
Craig Mautner
e6d80f4ce4 Add NO_ANIMATION flag to ActivityView Intents.
Add Intent.FLAG_ACTIVITY_NO_AMINATION to all Intents passed into
ActivityView.

Fixes bug 15393526.

Change-Id: I1899a5019416109e982f0254aaba410bb1f4a38d
2014-06-10 13:31:02 -07:00
Amit Mahajan
437a77d4bb am 3f175a35: am e5a28d34: am 20c5ce50: Handle provisioning APN by turning off/on radio.
* commit '3f175a3587f5f7c7d6189c0fd09468bae4e81325':
  Handle provisioning APN by turning off/on radio.
2014-06-09 21:12:43 +00:00
Michael Kolb
1e6706abb2 am 4bdc93d6: Merge "Remove circular mask" into klp-modular-dev
* commit '4bdc93d63e9edc7840a227ea1824f1f7ac93933e':
  Remove circular mask
2014-06-09 21:12:19 +00:00
Amit Mahajan
3f175a3587 am e5a28d34: am 20c5ce50: Handle provisioning APN by turning off/on radio.
* commit 'e5a28d34f662c469f85590dda28fc02eca12204b':
  Handle provisioning APN by turning off/on radio.
2014-06-09 19:50:09 +00:00
Amit Mahajan
20c5ce50c4 Handle provisioning APN by turning off/on radio.
The change is specific to AT&T as they want no signaling from device during provisioning.
I've tested following cases:
- expired AT&T SIM to make sure provisioning flow works as expected.
- airplane mode on/off with both active and expired AT&T SIM.
- wifi <-> mobile transitions work okay.
- LTE with Verizon SIM (basic sanity).

bug: 13190133

Change-Id: I215963174ae6000ae71d1dda693f95413f3d6e81
2014-06-09 17:55:27 +00:00
Michael Kolb
4bdc93d63e Merge "Remove circular mask" into klp-modular-dev 2014-06-06 15:26:17 +00:00
Prashant Malani
59b82c3eae am 42db3761: Merge "DO NOT MERGE Change display state modification during dozing" into klp-modular-dev
* commit '42db3761c9ee3df11a367cbc907f2ba433251634':
  DO NOT MERGE Change display state modification during dozing
2014-06-06 00:16:35 +00:00