35014 Commits

Author SHA1 Message Date
Fyodor Kupolov
f3d241486b Merge "Allow deleting accounts when user is locked" into nyc-dev 2016-04-11 19:16:18 +00:00
Julia Reynolds
f64a0fea6c Merge "Don't get application info for the system" into nyc-dev 2016-04-11 19:09:56 +00:00
Julia Reynolds
b401fa75f9 Don't get application info for the system
Bug: 28107178
Change-Id: Ic1a75a7d6d6e80e0df8f3017fb8737cf18f4dd3a
2016-04-11 14:53:42 -04:00
Jorim Jaggi
dd05f0365a Death to synchronous transactions (2/2)
Bug: 28068298
Change-Id: I7d2d7aba8c16aa5e0b9c288bc747ed62f9292381
2016-04-11 18:35:01 +00:00
Jeff Sharkey
bdae9296be Merge "Send USER_UNLOCKED broadcasts before PRE_BOOT." into nyc-dev 2016-04-11 18:20:22 +00:00
Jeff Sharkey
a66bffb0e7 Merge "Skip unlock requests for users who aren't running." into nyc-dev 2016-04-11 18:20:01 +00:00
Jeff Sharkey
155e5d6de7 Send USER_UNLOCKED broadcasts before PRE_BOOT.
Apps handling the PRE_BOOT_COMPLETED broadcast expect the user to be
fully unlocked and working.  Most system internals are using the
SystemServer interface, and we dispatch the unlocked event through
them before starting the PRE_BOOT process.

However, there are still some system internals that haven't been
converted to SystemServer, so we need to also send USER_UNLOCKED
for them to pick up before starting PRE_BOOT work.

Bug: 28086245
Change-Id: Ie847b463ea55a6dddcc49d243ef8fb308e5179a7
2016-04-11 12:13:08 -06:00
Jeff Davidson
b53874e714 Merge changes from topic 'carrier-app-race' into nyc-dev
* changes:
  Disable preinstalled carrier apps earlier in boot.
  Move CarrierAppUtils into frameworks/base/telephony.
2016-04-11 17:58:18 +00:00
Gustav Sennton
95cd5d58a8 Merge "Clear calling identity when enabling WebView fallback logic." into nyc-dev 2016-04-11 17:29:20 +00:00
Todd Kennedy
f86ce783c6 Merge "Add systrace for resolveIntent()" into nyc-dev 2016-04-11 17:18:26 +00:00
Todd Kennedy
42cf25f735 Merge "Don't allow userID changes on upgrade" into nyc-dev 2016-04-11 17:17:54 +00:00
Jeff Sharkey
27b5d2e2f9 Skip unlock requests for users who aren't running.
Bug: 28111989
Change-Id: I80b6dd1e5a2d919b0a198667e18b7979effe6999
2016-04-11 11:14:04 -06:00
Makoto Onuki
390a81302f Merge "Add UserHandle to ShortcutInfo, and simplify LauncherApps APIs." into nyc-dev 2016-04-11 16:45:10 +00:00
Fyodor Kupolov
4c74334c44 Merge "Added getProfileIds method returning array of userIds" into nyc-dev 2016-04-11 16:40:55 +00:00
Chris Wren
248a2e0364 Merge "don't copy importance forward" into nyc-dev 2016-04-11 16:30:07 +00:00
Lorenzo Colitti
ed748c2c56 Merge "Reinstate much-reduced ConnectivityService logging." into nyc-dev 2016-04-11 16:08:52 +00:00
Yohei Yukawa
063fe652be Merge "Make additional IME Subtype ID persistent." into nyc-dev 2016-04-11 15:46:12 +00:00
Gustav Sennton
15e636b570 Merge "Ensure we don't crash the system server when disabling/enabling package." into nyc-dev 2016-04-11 15:10:35 +00:00
David Brazdil
ffdaae004b Merge "Retry compiling a previously failing package after update" into nyc-dev 2016-04-11 15:04:20 +00:00
David Brazdil
ace80c56d7 Retry compiling a previously failing package after update
BackgroundDexOptimizer (BDOS) keeps a list of packages it attempted
to compile but dexopt failed. Once such a package is put on the list,
it is never removed from it until reboot.

This CL modifies BDOS to accept notificiations from
PackageManagerService on recently installed packages and removes
their names from the list.

Bug: 28082762
Change-Id: I0c3d3f657bd3ff5f0a61dfeef1d8174ed7be0b74
2016-04-11 15:45:46 +01:00
Chris Wren
1f602dc326 don't copy importance forward
copyRankingInformation should only copy side notes to be used by rankers.

Bug: 26919636
Change-Id: I6d0d87d4dc93ced65180ce58a4dcde2cac60e8b6
2016-04-11 10:36:01 -04:00
Lorenzo Colitti
b89d33ee44 Merge changes Ic2c84de7,I379aef92 into nyc-dev
* changes:
  Remove duplicated code in NetworkStateTrackerHandler.
  Improve Tethering and NativeDaemonConnector logging.
2016-04-11 14:27:31 +00:00
Lorenzo Colitti
39d2bb56b6 Reinstate much-reduced ConnectivityService logging.
Change-Id: I9d1292f8c036be2a854fdb537f4ccb957d211966
2016-04-11 23:19:06 +09:00
Julia Reynolds
02d01b7b01 Merge "DND related restrictions" into nyc-dev 2016-04-11 14:05:06 +00:00
David Brazdil
80932c1418 Assume package failed to compile unless proven otherwise
BackgroundDexOptService keeps a list of packages which failed to
compile so that they are not revisited. If compilation takes so long
that the background job is killed, the offending package is not
recorded.

This patch records the package before dexopt is called and removes it
from the list if dexopt succeeds.

Bug: 28082762
Change-Id: If7388e159b999287b60f19dc99cf4dde61ec64c8
2016-04-11 11:42:23 +01:00
David Brazdil
6a3b2d2bc6 Refactor return values of performDexOpt
PackageDexOptimizer.performDexOpt would return DEX_OPT_PERFORMED if
dexopt succeeded on the package and DEX_OPT_SKIPPED otherwise, even
if dexopt failed. This patch fixes that and cleans up the code.

PackageManagerService.performDexOpt* would return true only if
PackageDexOptimizer.performDexOpt returned DEX_OPT_PERFORMED.
Consequently, it would return false when dexopt was not needed. This
patch refactors the code to return true unless PackageDexOptimizer
returns DEX_OPT_FAILED and documents the behaviour.

Bug: 28082762
Change-Id: Ica73e67ab02025ef5619746bb8c465c96b72846b
2016-04-11 11:42:23 +01:00
David Brazdil
37a87698f5 Update packages in post-boot background job
Adds a post-boot job which scans all optimizable packages and updates
those whose OAT files are out of date. This is meant to offset the
fact that on OTA we only update the most used packages.

Bug: 27901338
Change-Id: Ia4d4362ecead1ca63d08d62c6814dad4b810f7cc
2016-04-11 11:42:18 +01:00
Yohei Yukawa
66baf69042 Make additional IME Subtype ID persistent.
It turns out that IME subtypes specified to
InputMethodManager#setAdditionalInputMethodSubtypes() are stored in the
presistent storate without subtype IDs.  As a result, when the system is
rebooted, the system would no longer consider those additional subtypes
as enabled due to subtype ID mismatch, until the IME re-adds those
additional subtypes again with the original subtype IDs.

Bug: 28104337
Change-Id: I1445213e0b83d76631a839b974ec1ab9b28ad7d2
2016-04-11 02:29:35 -07:00
Lorenzo Colitti
9b0c8fd95c Remove duplicated code in NetworkStateTrackerHandler.
Also use MessageUtils to decode message names.

Change-Id: Ic2c84de73fbf3eb10cc9634a083e5d3b3ffb807a
2016-04-11 17:40:22 +09:00
Lorenzo Colitti
cd63d247f0 Improve Tethering and NativeDaemonConnector logging.
1. Deduplicate the Tethering message numbers, and use MessageUtils
   to convert them to strings.
2. Add a warning to NativeDaemonConnector when an unsolicited
   event is more than 500ms late or takes more than 500ms to
   process.

Bug: 27857665
Change-Id: I379aef9257027d1ccf30906e79c6389ef1f95420
2016-04-11 17:40:21 +09:00
Jeff Sharkey
2e3ce4ca46 Merge "Use inode numbers for CE storage." into nyc-dev 2016-04-11 06:12:37 +00:00
Yohei Yukawa
270fe5dbe4 Merge "Shift+Meta+Space should reverse-rotate subtypes." into nyc-dev 2016-04-11 05:27:30 +00:00
Jeff Sharkey
4288419787 Use inode numbers for CE storage.
Certain operations, such as clearing/destroying app data, or just
counting on-disk size, require us to know the CE storage directory
of a particular app.  To facilitate these operations, offer a method
to get the inode of a CE directory, and accept that inode number
for later operations.  Collect and store the inode number in
PackageUserState for future use when that user's CE storage is
still locked.  This design means it's safe to clear/destroy app
data in both CE/DE storage at the same time.

Move most installd-related methods to a uniform calling convention
that accepts a single parent PackageParser.Package, and internally
fans out to handle all "leaf" packages under that parent.

In previous releases, we started installing apps using a new
directory-based layout, where all app code, unpacked native libraries,
and optimized code is bundled together.  So now we only have a single
path to measure for code size.  This fixes several outstanding bugs
that were causing sizes to be miscounted for apps supporting multiple
architectures.

Fix a subtle bug in PackageSettings that would cause "notLaunched"
to be parsed incorrectly.

Bug: 27828915, 27197819
Change-Id: Ia582cf3550553292bde4bb4313367111332913ec
2016-04-10 23:26:09 -06:00
Yohei Yukawa
d39ae85482 Shift+Meta+Space should reverse-rotate subtypes.
This is a follow up CL to my previous CL [1], which added a new key
binding Meta+Space to rotate enabled IME subtypes.  With this CL,
Shift+Meta+Space starts reverse-rotating enabled IME subtypes as
originally planed.

 [1]: I4005692215edfcf8bed3e86b1e07000148f986f5
      ae61f7118a92e097e854c840d5726c0920f5db0e

Bug: 25753404
Bug: 28103839
Change-Id: I3694edd80be6dfe18b90360e24ae4d451b331928
2016-04-10 20:28:40 -07:00
Andrii Kulian
c92490ac17 Merge "Fix minimal size for tasks in right-hand pane" into nyc-dev 2016-04-11 03:19:13 +00:00
Jeff Sharkey
d4041db120 More freezing of apps when doing surgery.
We're still hearing rare reports of apps running while the system
is trying to do surgery on app code/data.  To fix this once and for
all, start guarding all PackageManager critical sections by freezing
and then killing the app before doing surgery.

This is done by introducing a new PackageFreezer class which can be
used in try-with-resources blocks.  It also handles child packages
uniformly, and it uses CloseGuard to defensively un-freeze packages
if a caller leaks without closing.

The set of frozen packages is now maintained outside of PackageSetting
to support newly installed packages.  Add docs for the various locks
and method syntax conventions, including the new "LIF" syntax which
indicates the caller is responsible for freezing the package being
worked on.

Bug: 27698554
Change-Id: I64c4c48123060ccb4d4c50c2fbf3ef223c01e659
2016-04-09 17:25:06 -06:00
Jeff Sharkey
8ed9ece93d Revert "Keep read/write external storage as built-in permissions"
This reverts commit 4086750e30d04715d5be3ca6eaa75a4a1fa41d56.
2016-04-09 16:12:01 -06:00
Jeff Sharkey
edd11f50c6 Add missing method called from native code.
Without this method, boot would fail.

Bug: 28093387
Change-Id: I304d48bbf3ea24ce6af3b5a71c60b8ed06be38e1
2016-04-09 15:48:46 -06:00
Svetoslav Ganov
30f37594e0 Merge "Keep read/write external storage as built-in permissions" into nyc-dev 2016-04-09 20:16:13 +00:00
Svet Ganov
4086750e30 Keep read/write external storage as built-in permissions
These are permissions that were mapped to gids but we need
to keep them listed event though they are no longer mapped
to gis until an upgrade from L to the current version is to
be supported. These permissions are built-in and in L were
not stored in packages.xml as a result if they are not defined
in the platform.xml while parsing packages.xml we would
ignore these permissions being granted to apps and not
propagate the granted state. From N we are storing the built-in
permissions in packages.xml as the saved storage is negligible
(one tag with the permission) compared to the fragility as one
can remove a built-in permission which no longer needs to be
mapped to gids and break grant propagation.

bug:27185272

Change-Id: I440f6ceb7bc4710dece1a2fadabc995b18fc2a83
2016-04-09 13:05:26 -07:00
Lorenzo Colitti
6ad205b66d Merge "More APF debuggability." into nyc-dev 2016-04-09 10:13:24 +00:00
Gustav Sennton
ff396f2710 Ensure we don't crash the system server when disabling/enabling package.
We shouldn't crash when trying to disable/enable a non-existent fallback
package.

Bug: 27918467
Change-Id: Ia94425ac197b17430900bb7a9e7b2d2bf65ab9b3
2016-04-09 09:59:46 +01:00
Jorim Jaggi
c3769ae3f3 Merge "Disable snap targets that make apps <220dp" into nyc-dev 2016-04-09 07:07:02 +00:00
Jorim Jaggi
19cf297258 Disable snap targets that make apps <220dp
- Make minimal task size 220dp.
- Disable upper and lower targets if they result in less
than 220dp task size.
- If even the middle target doesn't allow 220dp task size,
disable entering split screen altogether.

Bug: 26451260
Change-Id: I06e358c9b3da0172c5def75cdadf975f87f9fa57
2016-04-09 00:02:49 -07:00
Jorim Jaggi
fe52f91f0c Merge "Only force drawing status bar background if target >= N" into nyc-dev 2016-04-09 04:04:35 +00:00
Jorim Jaggi
8f5701bd9f Only force drawing status bar background if target >= N
Since forcing it all the time has the potential of breaking
compatibility with apps, we don't want to do this.

Instead, we only force it if the app targets >= N.

We communicate this to window manager with
PRIVATE_FLAG_FORCE_DRAW_STATUS_BAR_BACKGROUND.

We introduced this for 2-up split-screen. If we have an app
that doesn't draw the status bar background by itself, we
just force the whole bar to be black.

The same applies for windows that used translucent status
bar - we also force the whole bar to be black

Bug: 27285627
Change-Id: I7f1ceaa364f8a4e851935f77aa5e8d913bf11791
2016-04-08 20:49:20 -07:00
Jack Yu
2e062ab8de Merge "Excluded certain APNs (e.g. IMS) from mobile data usage." into nyc-dev 2016-04-09 03:30:31 +00:00
Chong Zhang
c9039e05ea Merge "Fix for activity manager crash due to null task" into nyc-dev 2016-04-09 03:18:26 +00:00
Arunesh Mishra
1f07649e7d Merge "SoundTriggerHelper re-design." into nyc-dev 2016-04-09 01:31:49 +00:00
Jorim Jaggi
af80db4489 Fix a few issues with non-resizable info activity
- If stack doesn't have focus, we execute TASK_TO_FRONT transition.
Set the correct animation for this transition type.
- Make sure to execute app transition when we are finishing an
activity that isn't resumed.
- Correctly set mAnimatingExit for the case if the activity is
already paused.

Bug: 27327287
Bug: 27154882
Change-Id: I253938727ba0eea76ebadba242315bd2d305d0b4
2016-04-09 01:18:40 +00:00