OSDN Git Service

android-x86/frameworks-base.git
6 years agoMerge "Populate hiddenapi whitelist."
Mathew Inwood [Thu, 22 Feb 2018 17:36:20 +0000 (17:36 +0000)]
Merge "Populate hiddenapi whitelist."

6 years agoMerge changes I8e432950,Id325b8cf
Treehugger Robot [Thu, 22 Feb 2018 13:39:10 +0000 (13:39 +0000)]
Merge changes I8e432950,Id325b8cf

* changes:
  Build android.test.base/legacy against SDK
  Fix visibility issues with android.test.mock.stubs

6 years agoMerge "Package whitelist for hiddenapi checks."
Mathew Inwood [Thu, 22 Feb 2018 12:57:48 +0000 (12:57 +0000)]
Merge "Package whitelist for hiddenapi checks."

6 years agoPopulate hiddenapi whitelist.
Mathew Inwood [Fri, 16 Feb 2018 13:32:19 +0000 (13:32 +0000)]
Populate hiddenapi whitelist.

This list of packages is derived from all packages in the tree that do not
specify LOCAL_SDK_VERSION in their Android.mk. It was done by:

1.  Modifying biuld/core/package_internal.mk to output a warning for all
    packages that do not specify LOCAL_SDK_VERSION, including some
    metadata about the target.

2.  Parsing the output fom the build, then filtering out those that specify
    a test certificate, or with LOCAL_MODULE_TAGS := tests, that depend
    on android.test.runner or whose name includes "Test"

3.  Look up the java package name of each & build the list from these.

Test: N/A, this change is a no-op while all system apps are excluded
from the checks.

BUG: 73244707

Change-Id: Ie3dcb1b4b83c32e93609bc58dc7a1cd513eeea64

6 years agoPackage whitelist for hiddenapi checks.
Mathew Inwood [Fri, 16 Feb 2018 11:49:20 +0000 (11:49 +0000)]
Package whitelist for hiddenapi checks.

Some packages in the system image are not built against the SDK, so
enforcing hiddenapi checks for these will break them. Add a whitelist
for such packages.

For now, just add the contacts provider to the whitelist. The list will be
further populated later.

Test: Added test app package name to whitelist to verify.

Bug: 73244707

Merged-In: I94746b7f12dd9371d5068bb235eb853f63ee4d97
Change-Id: I1cbbd220c61b1b4b767c301f97096607ee902a7b

6 years agoMerge "Cleanup TelephonyManager's log"
Pengquan Meng [Thu, 22 Feb 2018 05:19:11 +0000 (05:19 +0000)]
Merge "Cleanup TelephonyManager's log"

6 years agoMerge "EMBMS API tweaks"
Hall Liu [Thu, 22 Feb 2018 00:35:51 +0000 (00:35 +0000)]
Merge "EMBMS API tweaks"

6 years agoMerge "Check for location access on TelephonyRegistry"
Hall Liu [Wed, 21 Feb 2018 22:42:08 +0000 (22:42 +0000)]
Merge "Check for location access on TelephonyRegistry"

6 years agoMerge "Explicitly restart the killed wallpaper service"
Chris Tate [Wed, 21 Feb 2018 21:49:31 +0000 (21:49 +0000)]
Merge "Explicitly restart the killed wallpaper service"

6 years agoMerge "Fix low probability deadlock"
Xiangyu/Malcolm Chen [Wed, 21 Feb 2018 21:16:44 +0000 (21:16 +0000)]
Merge "Fix low probability deadlock"

6 years agoBuild android.test.base/legacy against SDK
Paul Duffin [Wed, 14 Feb 2018 10:36:16 +0000 (10:36 +0000)]
Build android.test.base/legacy against SDK

android.test.legacy is now build against SDK, thus available to apps
build with SDK.

In doing so, android.test.mock.stubs had to be built with SDK (because
it is used by android.test.legacy). However, this wasn't trivial.

The problem was that some classes in test-mock implemented abstract
methods of platform classes. Even though they are marked as @hide,
doclava automatically emit them to the stub file because otherwise the
class in the stub file does not implement some abstract methods from its
parent class, which in turn makes the stub file non-compilable.

This CL solves the problem by introducing an adapter class in between
the class in test-mock and the class in the framework. The adapter class
implements abstract methods which are @hide and having reference to
types that aren't available to SDK. The abstract methods are removed
from the original class. Then doclava does not emit the abstract
methods.

Also by @hide'ing the adapter classes, they are not compiled when
building the stub library.

Bug: 30188076
Bug: 73339598
Test: m -j android.test.base
Test: m -j android.test.legacy
Test: m -j android.test.mock.stubs
are successful and do not show link-check warning
Merged-In: I8e432950e693ee3c6f0240852e62da6133d31571
Change-Id: I8e432950e693ee3c6f0240852e62da6133d31571

6 years agoCleanup TelephonyManager's log
Pengquan Meng [Wed, 21 Feb 2018 03:09:10 +0000 (19:09 -0800)]
Cleanup TelephonyManager's log

Don't log success calls to TelephonyManager.setTelephonyProperty.

Bug: 71514398
Test: manual test
Change-Id: I2383f1e2925bff959c3d925d7fdc8be891630c61

6 years agoFix low probability deadlock
yifan.bai [Fri, 22 Dec 2017 06:59:57 +0000 (14:59 +0800)]
Fix low probability deadlock

Low probability deadlock in com.android.phone and system_server.
Bug: 70865607

Test: Build pass

6 years agoEMBMS API tweaks
Hall Liu [Tue, 6 Feb 2018 19:36:17 +0000 (11:36 -0800)]
EMBMS API tweaks

Make changes per API council recommendations
Also clean up the download flow -- provide option for app to specify a
destination as long as it's on the same filesystem.

Bug: 72837388
Fixes: 72231372
Test: CTS and testapp

Change-Id: Ia2a68a73e6d61f426b55068542a66995afc20407

6 years agoMerge "Reparent the webview_zygote to be a child of the main app_process zygote."
Treehugger Robot [Wed, 21 Feb 2018 00:43:56 +0000 (00:43 +0000)]
Merge "Reparent the webview_zygote to be a child of the main app_process zygote."

6 years agoReparent the webview_zygote to be a child of the main app_process zygote.
Robert Sesek [Wed, 17 Jan 2018 23:48:18 +0000 (18:48 -0500)]
Reparent the webview_zygote to be a child of the main app_process zygote.

This uses the new ZygoteProcess.startChildZygote() method to launch the
webview_zygote, rather than having init start it. This will share more
memory between the app_process and the webview_zygote, reducing the
overall system footprint.

Bug: 63749735
Test: m
Test: Launch "Third-party licenses" activity from Settings, and it
      renders correctly via the WebView.
Change-Id: I3e39cd8adb9c099c92ee34640428916d90cb2b8f

6 years agoMerge "Consider shared libs when precreating WebView classloader."
Treehugger Robot [Tue, 20 Feb 2018 21:59:54 +0000 (21:59 +0000)]
Merge "Consider shared libs when precreating WebView classloader."

6 years agoMerge "Add new reason code for call failed by unobtainable number"
Brad Ebinger [Tue, 20 Feb 2018 21:00:08 +0000 (21:00 +0000)]
Merge "Add new reason code for call failed by unobtainable number"

6 years agoMerge "Change KEY_CARRIER_VOLTE_TTY_SUPPORTED_BOOL to false"
Pankaj Kanwar [Tue, 20 Feb 2018 20:48:12 +0000 (20:48 +0000)]
Merge "Change KEY_CARRIER_VOLTE_TTY_SUPPORTED_BOOL to false"

6 years agoConsider shared libs when precreating WebView classloader.
Torne (Richard Coles) [Tue, 19 Sep 2017 19:21:29 +0000 (15:21 -0400)]
Consider shared libs when precreating WebView classloader.

The change to handling of the deprecated Apache HTTP library means that
the WebView implementation package might have a non-empty shared library
list. Make sure to fetch shared libraries when querying WebView
implementations, and take them into account when constructing both the
actual classpath to be used to precreate the classloader, and when
deciding what the cache key for the precreated classloader should be.

Change-Id: I5e1409358d935e1c9f325db434bc6d4ef8ead759
Merged-In: I5e1409358d935e1c9f325db434bc6d4ef8ead759
Fixes: 65574359
Test: launch anything that uses WebView
(cherry picked from commit 4fd8aa51e4de5a7c93841571e30ff10077d1b125)

6 years agoMerge "Fix ConnectivityServiceTest for NATT Keepalive"
nharold [Tue, 20 Feb 2018 19:17:23 +0000 (19:17 +0000)]
Merge "Fix ConnectivityServiceTest for NATT Keepalive"

6 years agoMerge "Pass DEXOPT_INSTALL_WITH_DEX_METADATA_FILE for first boot"
Mathieu Chartier [Tue, 20 Feb 2018 19:12:38 +0000 (19:12 +0000)]
Merge "Pass DEXOPT_INSTALL_WITH_DEX_METADATA_FILE for first boot"

6 years agoMerge "WifiTile: Avoid NPE during boot phase"
Treehugger Robot [Tue, 20 Feb 2018 15:23:04 +0000 (15:23 +0000)]
Merge "WifiTile: Avoid NPE during boot phase"

6 years agoMerge "Add flag to AMS.startInstrumentation() to disable hidden API checks"
David Brazdil [Tue, 20 Feb 2018 14:36:18 +0000 (14:36 +0000)]
Merge "Add flag to AMS.startInstrumentation() to disable hidden API checks"

6 years agoChange KEY_CARRIER_VOLTE_TTY_SUPPORTED_BOOL to false
pkanwar [Mon, 19 Feb 2018 18:33:33 +0000 (10:33 -0800)]
Change KEY_CARRIER_VOLTE_TTY_SUPPORTED_BOOL to false

Bug: 73609752
Test: compile

Change-Id: Ie9615e63d136f40ee301504b3e2b3b7ea4aec129

6 years agoAdd flag to AMS.startInstrumentation() to disable hidden API checks
David Brazdil [Mon, 19 Feb 2018 15:39:15 +0000 (15:39 +0000)]
Add flag to AMS.startInstrumentation() to disable hidden API checks

Some tests need to use hidden APIs to check the internal state of
the framework. For those special use cases, we add a new flag to
ActivityManagerService.startInstrumentation that enables to start
instrumented processes without hidden API enforcement. Individual
test harnesses can change their Am command to request the exemption.

Bug: 64382372
Test: adb shell am instrument --no-hidden-api-checks <component>
      adb logcat | grep 'Accessing hidden'
Merged-In: I1d734a95423fae90dae63ff09d5f606495830905
Change-Id: Ifbb0d19d95737a9f601b11e20352cdc11f0ca5b6

6 years agoMerge "Turn on DepAnn for test-base and test-runner"
Paul Duffin [Mon, 19 Feb 2018 13:03:56 +0000 (13:03 +0000)]
Merge "Turn on DepAnn for test-base and test-runner"

6 years agoAdd new reason code for call failed by unobtainable number
haoyu li [Wed, 22 Nov 2017 03:49:49 +0000 (12:49 +0900)]
Add new reason code for call failed by unobtainable number

To show the "Invalid number" on the end call screen when user makes a
IMS call with unobtainable number, this reason code is used.

Test: manual - Checked that "Invalid number" is shown when make the IMS
MO call to unobtainable number.
Bug: 69940434

Change-Id: If3c54e6f55850141efad56ad7712db3c82a14f43

6 years agoExplicitly restart the killed wallpaper service
Tetsutoki Shiozawa [Fri, 2 Feb 2018 05:18:43 +0000 (14:18 +0900)]
Explicitly restart the killed wallpaper service

Symptom:
Live wallpaper setting was reset when a wallpaper service was killed
by Lmk. The wallpaper fell back to the default image wallpaper. It's
a black bitmap.

Root cause:
When restarting wallpaper service takes more than 10 seconds, it's
treated as a bad wallpaper. The wallpaper setting is reset to remove
the bad wallpaper.

This is not a suitable solution under the low memory situation.
Multiple processes are killed by Lmk at one time. Killed services are
automatically restarted by AMS with a few seconds interval.
The restart interval is increased by a factor of the number of killed
services. Sometimes, it takes more than 1 minute.

Solution:
When a wallpaper service is killed, WallpaperManagerService requests
restarting the service immediately. It can ignore the restart interval.

Bug: 73071020
Change-Id: Id5bb1cf121029a513f8773597f296b47667d1e21

6 years agoMerge changes Ic28c5653,Ic635f97b
Treehugger Robot [Mon, 19 Feb 2018 03:45:27 +0000 (03:45 +0000)]
Merge changes Ic28c5653,Ic635f97b

* changes:
  [LT2] Fix release request while lingering.
  [LT1] Add a test for release request while lingering

6 years agoMerge "Don't refcount TRACK_DEFAULT requests."
Chalard Jean [Mon, 19 Feb 2018 02:13:48 +0000 (02:13 +0000)]
Merge "Don't refcount TRACK_DEFAULT requests."

6 years ago[LT2] Fix release request while lingering.
Chalard Jean [Fri, 16 Feb 2018 07:08:35 +0000 (16:08 +0900)]
[LT2] Fix release request while lingering.

Test: runtest framework-net
Change-Id: Ic28c5653d16351903b792e76ba8b199b7ed1f8d4

6 years agoMerge "DO NOT MERGE : fix useless import"
Chalard Jean [Sun, 18 Feb 2018 23:14:42 +0000 (23:14 +0000)]
Merge "DO NOT MERGE : fix useless import"

6 years agoFix visibility issues with android.test.mock.stubs
Paul Duffin [Tue, 19 Dec 2017 15:11:47 +0000 (15:11 +0000)]
Fix visibility issues with android.test.mock.stubs

This ensures that the API definitions for the android.test.mock package
matches the definitions in the api/current.txt file.

Bug: 30188076
Test: make update-api
(cherry-picked from commit bd97e3dd4e5d395f336114016b000ef3cfb26053)

Merged-In: Id325b8cf2f189117ac4cfe7634095ab710eee004
Change-Id: Id325b8cf2f189117ac4cfe7634095ab710eee004

6 years agoMerge "Add @Nullable to return values in Uri"
Treehugger Robot [Sat, 17 Feb 2018 04:49:23 +0000 (04:49 +0000)]
Merge "Add @Nullable to return values in Uri"

6 years agoMerge "Add Zygote.startChildZygote() to fork a new process that itself is a zygote."
Treehugger Robot [Sat, 17 Feb 2018 01:39:54 +0000 (01:39 +0000)]
Merge "Add Zygote.startChildZygote() to fork a new process that itself is a zygote."

6 years agoFix ConnectivityServiceTest for NATT Keepalive
Nathan Harold [Wed, 14 Feb 2018 21:09:45 +0000 (13:09 -0800)]
Fix ConnectivityServiceTest for NATT Keepalive

Fix test breakages I caused when adding cell
support for NATT keepalives.

-Make the minimum keepalive interval a constant in
 ConnectivityManager and use it in tests.
-Re-Disallow IPv6 Keepalives

Bug: 73327535
Test: 'runtest -x ConnectivityServiceTest' now passes
Change-Id: I5ec4367d250ee371014e65c897c3897a25a05e2d

6 years agoWifiTile: Avoid NPE during boot phase
Bruno Martins [Fri, 16 Feb 2018 23:06:06 +0000 (00:06 +0100)]
WifiTile: Avoid NPE during boot phase

* Listening handling can only take place once mController
  is properly initialized.

Change-Id: Icd5003e67a725323a5445a936d5a38a3006c5431

6 years agoMerge "MSIM support for hidden IMS capability and registration query APIs."
Brad Ebinger [Fri, 16 Feb 2018 20:35:45 +0000 (20:35 +0000)]
Merge "MSIM support for hidden IMS capability and registration query APIs."

6 years agoMerge "[DO NOT MERGE] Fix some mouse + list-item selection/scrolling issues"
Treehugger Robot [Fri, 16 Feb 2018 20:02:26 +0000 (20:02 +0000)]
Merge "[DO NOT MERGE] Fix some mouse + list-item selection/scrolling issues"

6 years agoMerge "[DO NOT MERGE] Fix context menu position for RTL"
Treehugger Robot [Fri, 16 Feb 2018 19:54:26 +0000 (19:54 +0000)]
Merge "[DO NOT MERGE] Fix context menu position for RTL"

6 years agoAdd Zygote.startChildZygote() to fork a new process that itself is a zygote.
Robert Sesek [Mon, 12 Feb 2018 23:46:01 +0000 (18:46 -0500)]
Add Zygote.startChildZygote() to fork a new process that itself is a zygote.

This adds a new --start-child-zygote argument that instructs the main
zygote to create a new child process that will also be a zygote. The
system_server generates a random name in the abstract socket namespace
for it and the child-zygote to communicate over, and that is passed as
an argument to the new process.

A child-zygote bypasses the normal post-fork-child of the zygote process
in order to preserve itself as a zygote. This means not starting the
Binder threadpool nor launching into ActivityThread. Instead, a
child-zygote calls into its own main function. The main function runs a
ZygoteServer select loop, listening on the socket name specified by the
system_server when it was forked.

Unlike the system zygotes, a child-zygote can be killed without bringing
down the system. Killing a child-zygote will not terminate its child
processes, which will be reparented to init for reaping when they
eventually exit.

Bug: 63749735
Test: m (with multi-project commits landed)
Change-Id: I3e7ebbdba498f8fec1d84cdf927dc43a92be4b68

6 years agoMerge "Correct bug in IpSecTransformTest"
Benedict Wong [Fri, 16 Feb 2018 18:32:05 +0000 (18:32 +0000)]
Merge "Correct bug in IpSecTransformTest"

6 years agoMerge "Framework: Disable [MissingOverride] for platformprotos"
Treehugger Robot [Fri, 16 Feb 2018 16:05:19 +0000 (16:05 +0000)]
Merge "Framework: Disable [MissingOverride] for platformprotos"

6 years agoTurn on DepAnn for test-base and test-runner
Paul Duffin [Fri, 16 Feb 2018 13:11:05 +0000 (13:11 +0000)]
Turn on DepAnn for test-base and test-runner

Bug: 30188076
Test: m -j20 RUN_ERROR_PRONE=true android.test.base android.test.runner
Change-Id: I735e3fbfcc710f1dc1b96e04f91b9feda8727b6c

6 years agoMerge "BluetoothTile: Avoid NPE during boot up phase"
Treehugger Robot [Fri, 16 Feb 2018 15:20:23 +0000 (15:20 +0000)]
Merge "BluetoothTile: Avoid NPE during boot up phase"

6 years agoMerge "Hidden API blacklisting killswitch."
Treehugger Robot [Fri, 16 Feb 2018 11:50:20 +0000 (11:50 +0000)]
Merge "Hidden API blacklisting killswitch."

6 years agoHidden API blacklisting killswitch.
Mathew Inwood [Thu, 15 Feb 2018 10:28:06 +0000 (10:28 +0000)]
Hidden API blacklisting killswitch.

Just support "*" for now, meaning disable all API blacklisting for all
apps.

Test: Manually verified by:
- installing test app that accesses hidden API
- manually blacklist the API
- $ adb shell settings put global hidden_api_blacklist_exemptions \\*

This is a cherry pick of change I9a41a104742c9aaaf3a753e7b0f3a1106e37d4d3
from internal master.

Merged-In: I9a41a104742c9aaaf3a753e7b0f3a1106e37d4d3
Change-Id: Ibb2a1d054c1b099fc6093e37f24b2ed421a2313c

6 years ago[LT1] Add a test for release request while lingering
Chalard Jean [Fri, 16 Feb 2018 07:07:53 +0000 (16:07 +0900)]
[LT1] Add a test for release request while lingering

Test: runtest framework-net
Change-Id: Ic635f97bf3dad8b695b3b8cc32c1a8b891166f9f

6 years agoDon't refcount TRACK_DEFAULT requests.
Chalard Jean [Fri, 16 Feb 2018 08:59:29 +0000 (17:59 +0900)]
Don't refcount TRACK_DEFAULT requests.

This has no concrete impact on the behavior of ConnectivityService,
but in principle TRACK_DEFAULT requests should not be counted toward
requests that make a network foreground. It does not have an impact
because only VPNs could be affected by this, and VPNs are always in
the foreground by definition.

Test: runtest frameworks-net
Test: cts
Change-Id: Id2ae6b5c9d542fe168e64ed713b6ec0a04062c82

6 years agoDO NOT MERGE : fix useless import
Chalard Jean [Fri, 16 Feb 2018 08:21:39 +0000 (17:21 +0900)]
DO NOT MERGE : fix useless import

This was added to avoid a merge conflict at a sensitive time.
It can (and should) go.

Test: no code change
Change-Id: I11d73e2d988ae61a168aa0f1cc7c2c506f509d30

6 years agoMerge "Add missing'}' in javadoc of public API method"
Treehugger Robot [Fri, 16 Feb 2018 03:19:35 +0000 (03:19 +0000)]
Merge "Add missing'}' in javadoc of public API method"

6 years agoCorrect bug in IpSecTransformTest
Benedict Wong [Fri, 16 Feb 2018 02:47:49 +0000 (18:47 -0800)]
Correct bug in IpSecTransformTest

testCreateTransformsWithSameConfigEqual used assertFalse rather than
assertTrue

Bug: 69385347
Test: Passing on walleye
Change-Id: I8caa26e184e8bfc3e8acc9061d85c22d27ebf448

6 years agoPass DEXOPT_INSTALL_WITH_DEX_METADATA_FILE for first boot
Mathieu Chartier [Fri, 16 Feb 2018 02:35:52 +0000 (18:35 -0800)]
Pass DEXOPT_INSTALL_WITH_DEX_METADATA_FILE for first boot

Motivation, use dm files in system partition for verifying if they
exist.

Bug: 70934104
Test: manual

Change-Id: I1224101eb830ce7c7bedb3a81b7569df1ef50491

6 years agoMerge "Pass the compilation reason to dexopt"
Calin Juravle [Fri, 16 Feb 2018 02:25:48 +0000 (02:25 +0000)]
Merge "Pass the compilation reason to dexopt"

6 years agoMerge "Fix LTE Timing Advance Doc String"
Treehugger Robot [Fri, 16 Feb 2018 01:47:27 +0000 (01:47 +0000)]
Merge "Fix LTE Timing Advance Doc String"

6 years agoMerge "NfcTile: Avoid NPE during boot up phase"
Treehugger Robot [Fri, 16 Feb 2018 01:34:43 +0000 (01:34 +0000)]
Merge "NfcTile: Avoid NPE during boot up phase"

6 years agoFramework: Disable [MissingOverride] for platformprotos
Andreas Gampe [Thu, 15 Feb 2018 23:12:38 +0000 (15:12 -0800)]
Framework: Disable [MissingOverride] for platformprotos

Bug: 72714520
Test: m javac-check-platformprotos RUN_ERROR_PRONE=true
Merged-In: I00f5a588fa74621d4c35dc4e39b54536815ad476
Change-Id: I00f5a588fa74621d4c35dc4e39b54536815ad476

6 years agoMerge "Fix HdmiCecLocalDevice concurrent access"
Dan Zhang [Fri, 16 Feb 2018 01:17:02 +0000 (01:17 +0000)]
Merge "Fix HdmiCecLocalDevice concurrent access"

6 years agoMerge "DndTile: Avoid NPE during boot phase"
Treehugger Robot [Fri, 16 Feb 2018 00:33:37 +0000 (00:33 +0000)]
Merge "DndTile: Avoid NPE during boot phase"

6 years agoMerge "Un-hide Connection-side RTT APIs for Dialer"
Treehugger Robot [Thu, 15 Feb 2018 23:56:55 +0000 (23:56 +0000)]
Merge "Un-hide Connection-side RTT APIs for Dialer"

6 years agoAdd @Nullable to return values in Uri
Scott Kennedy [Thu, 15 Feb 2018 23:36:40 +0000 (15:36 -0800)]
Add @Nullable to return values in Uri

This makes it much easier to add null-safety when calling this from Kotlin.

Test: refactoring CL. Existing unit tests still pass.
Change-Id: I55c33ad4ff1306afd80c1a5562c54dfcb6068b0b

6 years agoUn-hide Connection-side RTT APIs for Dialer
Hall Liu [Mon, 4 Dec 2017 22:19:30 +0000 (14:19 -0800)]
Un-hide Connection-side RTT APIs for Dialer

Bug: 63934808
Test: builds
Change-Id: I59a892fb0e314810e92dd9ad7d0c2f4610055045
Merged-In: I59a892fb0e314810e92dd9ad7d0c2f461005504

6 years agoFix LTE Timing Advance Doc String
Nathan Harold [Thu, 15 Feb 2018 21:06:16 +0000 (13:06 -0800)]
Fix LTE Timing Advance Doc String

The Doc string for LTE timing advance incorrectly
lists the range based on the maximum size of an
incremental TA command rather than the cumulative
timing advance. The spec reference is correct, but
the range was wrong.

Bug: 66751464
Test: compilation (docstring only change)
Change-Id: I0242cae7af40a7d9ed5ae9a2a509592076e5b6a3

6 years agoMerge "Add setting and logging for RTT"
Hall Liu [Thu, 15 Feb 2018 21:01:10 +0000 (21:01 +0000)]
Merge "Add setting and logging for RTT"

6 years agoPass the compilation reason to dexopt
Calin Juravle [Mon, 12 Feb 2018 20:00:44 +0000 (12:00 -0800)]
Pass the compilation reason to dexopt

Record the compilation reason in the oat files to enable better
performance monitoring.

Test: DexoptOptionsTest
      manual
Bug: 73102540

Change-Id: Ifa487d4bc33dcd06f12af6bdd1d9a9c5f4562f4b

6 years agoMerge "Add NetworkRegistrationState into SS's list."
Xiangyu/Malcolm Chen [Thu, 15 Feb 2018 19:01:59 +0000 (19:01 +0000)]
Merge "Add NetworkRegistrationState into SS's list."

6 years agoAdd setting and logging for RTT
Hall Liu [Tue, 30 Jan 2018 01:22:02 +0000 (17:22 -0800)]
Add setting and logging for RTT

Add a system setting to store preferred RTT mode for calls. Add logging
for RTT in Telecom base classes.

Bug: 63934808
Test: manual
Change-Id: Ie26fac800931604379bbe7b8abfed7caa8c0236d
Merged-In: Ie26fac800931604379bbe7b8abfed7caa8c0236d

6 years agoMerge "Add new owners files for Telephony/Telecom frameworks files."
Brad Ebinger [Thu, 15 Feb 2018 17:23:31 +0000 (17:23 +0000)]
Merge "Add new owners files for Telephony/Telecom frameworks files."

6 years agoMerge changes from topic "cp_calin_framework_2017"
Treehugger Robot [Thu, 15 Feb 2018 16:17:06 +0000 (16:17 +0000)]
Merge changes from topic "cp_calin_framework_2017"

* changes:
  Allow public profile compilation for primary apks
  [framework] Pass .dm files to dexopt at install time
  Extend the ArtManager profiling API to cover boot image profiling
  [framework] Extend profile operations to take the profile name
  Accept UserHandle.USER_ALL during profile preparation
  [framework] Prepare profile for app code paths
  Perform a non strict matching of .dm files when computing the size
  Support installation of DexMetadata files (.dm)
  Rename snapshotProfile to createProfileSnapshot for consistency
  Implement ArtManager#snapshotProfile API
  Add SystemApis to expose runtime profile information
  Log SHA256 of secondary dex files during reconcile.

6 years agoMerge "Update hidden API toast message"
David Brazdil [Thu, 15 Feb 2018 11:55:15 +0000 (11:55 +0000)]
Merge "Update hidden API toast message"

6 years agoMerge changes I3d68dbf8,I6ea524bb,I978d9119
Chalard Jean [Thu, 15 Feb 2018 11:25:36 +0000 (11:25 +0000)]
Merge changes I3d68dbf8,I6ea524bb,I978d9119

* changes:
  Deprecate CONNECTIVITY_ACTION.
  Publish FOREGROUND and add NOT_SUSPENDED capabilities.
  Send null UIDs to apps instead of single-uid lists.

6 years agoMerge changes Icd56662d,I0ece820f
Lorenzo Colitti [Thu, 15 Feb 2018 10:03:26 +0000 (10:03 +0000)]
Merge changes Icd56662d,I0ece820f

* changes:
  Restrict OWNERS in android.net.*
  Add OWNERS to the libandroid_net library.

6 years agoUpdate hidden API toast message
David Brazdil [Wed, 14 Feb 2018 22:36:34 +0000 (22:36 +0000)]
Update hidden API toast message

Change the toast message shown by an Activity when VMRuntime reports
that the app has used a private API.
(a) fix a typo: compatiblity -> compatibility
(b) change guidance from "please consult log" to "go to <url> for
    more info" where devs can learn how to proceed if their app does
    have compatibility issues.

Bug: 64382372
Test: make, visual
Change-Id: Idbe32a724438bb7b0826d0b4e11ef505015cb321

6 years agoRestrict OWNERS in android.net.*
Lorenzo Colitti [Thu, 15 Feb 2018 07:43:44 +0000 (16:43 +0900)]
Restrict OWNERS in android.net.*

Test: None
Change-Id: Icd56662dcbc86b49015d094fd8ae2ade235aa475

6 years agoAdd OWNERS to the libandroid_net library.
Lorenzo Colitti [Thu, 15 Feb 2018 06:51:58 +0000 (15:51 +0900)]
Add OWNERS to the libandroid_net library.

Test: None
Change-Id: I0ece820fc0de786a81df9f922135acdf92f1d136

6 years agoMerge "Hearing Aid profile"
Treehugger Robot [Thu, 15 Feb 2018 04:14:43 +0000 (04:14 +0000)]
Merge "Hearing Aid profile"

6 years agoAdd new owners files for Telephony/Telecom frameworks files.
Tyler Gunn [Wed, 14 Feb 2018 22:37:17 +0000 (14:37 -0800)]
Add new owners files for Telephony/Telecom frameworks files.

Test: N/A
Bug: 73373651
Change-Id: Ia0e19018d6cd72923f9f20b372d303fa532409b0

6 years agoAdd NetworkRegistrationState into SS's list.
Malcolm Chen [Tue, 13 Feb 2018 23:42:58 +0000 (15:42 -0800)]
Add NetworkRegistrationState into SS's list.

Add hidden API to add NetworkRegistrationState into SS's
NetworkRegistrationState list.

Bug: 73305596
Test: unittest
Change-Id: Ief7f22632c1f3400c01663d13b990dc9b0d59e2e

6 years agoHearing Aid profile
Jakub Pawlowski [Wed, 22 Nov 2017 19:02:34 +0000 (11:02 -0800)]
Hearing Aid profile

This is implementation of Hearing Aid Profile that will in future
be connected to Bluetooth Manager - see TODOs in BluetoothHearingAid.java

Bug: 69623109
Test: compilation. Manual test with HA.
Change-Id: I79643ea1e14e9df7f5771169359c964a60c56618

6 years agoMerge "Copy IpSecConfig when IpSecTransforms are created"
Benedict Wong [Wed, 14 Feb 2018 19:37:53 +0000 (19:37 +0000)]
Merge "Copy IpSecConfig when IpSecTransforms are created"

6 years agoMerge "add a current table in CarrierIdProvider"
Chen Xu [Wed, 14 Feb 2018 18:54:06 +0000 (18:54 +0000)]
Merge "add a current table in CarrierIdProvider"

6 years agoMSIM support for hidden IMS capability and registration query APIs.
Brad Ebinger [Fri, 9 Feb 2018 00:06:31 +0000 (16:06 -0800)]
MSIM support for hidden IMS capability and registration query APIs.

Modifies TelephonyManager APIs to better support MSIM devices
and adds a method to query MMTEL IMS Registration technology.

Test: Manual, telephony unit tests.
Bug: 35128252
Merged-In: Ie37185bd3477635094a0db998918ba5ad59842be
Change-Id: Ie37185bd3477635094a0db998918ba5ad59842be

6 years agoAllow public profile compilation for primary apks
Calin Juravle [Thu, 1 Feb 2018 17:23:13 +0000 (17:23 +0000)]
Allow public profile compilation for primary apks

It is ok to perform a "public" compilation with
profiles comming from dex metdata files.

(cherry picked from commit ff3e4a1b2fb082e8146d00a41f702d0b00d9cab0)

Test: adb install foo.apk foo.dm
Bug: 30934496
Merged-In: I1d15e3281ccc61b19a2aafe3c885285a83ff6115
Change-Id: I1d15e3281ccc61b19a2aafe3c885285a83ff6115

6 years ago[framework] Pass .dm files to dexopt at install time
Calin Juravle [Thu, 1 Feb 2018 17:20:51 +0000 (17:20 +0000)]
[framework] Pass .dm files to dexopt at install time

(cherry picked from commit cc65194e8e5a284e915176200a846ec75c037d95)

Test: DexoptOptionsTest
      adb install foo.apk foo.dm
Bug: 30934496

Merged-In: If7e705a0efc0954a385ec3bfe7a93921c0d83351
Change-Id: If7e705a0efc0954a385ec3bfe7a93921c0d83351

6 years agoExtend the ArtManager profiling API to cover boot image profiling
Calin Juravle [Mon, 22 Jan 2018 05:39:18 +0000 (21:39 -0800)]
Extend the ArtManager profiling API to cover boot image profiling

The boot image profile is available only on userdebug and eng builds and
combines the boot classpath and system server classpath.

Also, update ArtManager API to use Executors instead of Handlers.

(cherry picked from commit fcbb74a4296fd808e1058ecebd91fac56582e799)

Test: gts GtsAndroidRuntimeManagerHostTestCases
Bug: 30934496
Merged-In: Ie501947a659d644acbde04fb46157dd0c7944e81
Change-Id: Ie501947a659d644acbde04fb46157dd0c7944e81

6 years ago[framework] Extend profile operations to take the profile name
Calin Juravle [Sat, 20 Jan 2018 04:32:47 +0000 (20:32 -0800)]
[framework] Extend profile operations to take the profile name

Extend the installd profile interface to take the profile name as
argument. This shifts the responsibility for choosing the names of
profiles for primary apks completely to PackageManager. Each of the
application code paths will get an unique profile name based on their
split name.

All the profile operations will now work on a specific profile name rather
than assuming a default global name.

Also, move dumpProfiles and clearProfiles functionality to the
ArtManagerService so that we can re-use profileName computations easier.

(cherry picked from commit 6ae39fc2e5b4692d092a042816939fd0a5f3e3b8)

Test: manual (dexopt apps, merge profiles, clear profiles)
      gts GtsAndroidRuntimeManagerHostTestCases
Bug: 30934496

Merged-In: Ie65d45eed7de0844edf4b7af918d7eaa74ec1f2c
Change-Id: Ie65d45eed7de0844edf4b7af918d7eaa74ec1f2c

6 years agoAccept UserHandle.USER_ALL during profile preparation
Calin Juravle [Wed, 24 Jan 2018 22:43:24 +0000 (14:43 -0800)]
Accept UserHandle.USER_ALL during profile preparation

(cherry picked from commit 5bbe26ee01bc9785487fe5e748e624b6fc5bd3a4)

Test: adb install foo.apk
Bug: 72453027
Merged-In: I840d70d47a256c8853bbe1b9b023f51bdd5ddf6b
Change-Id: I840d70d47a256c8853bbe1b9b023f51bdd5ddf6b

6 years ago[framework] Prepare profile for app code paths
Calin Juravle [Thu, 18 Jan 2018 23:17:29 +0000 (15:17 -0800)]
[framework] Prepare profile for app code paths

This CL is an intermediate step to enable the use of profiles shipped in
the dex metadata files.

The preparation consist of:
- creating the current profile
- merging the profile from the dex metadata file (if present) into the
reference profile

and happens:
- after the application data directory is created, to capture system
apps.
- post-install (right before we dexopt), to capture any new code paths

(cherry picked from commit 3621be71d0fe8a349ca468aca99a53a17f6575b3)

Test: manual (install apps and splits, take OTA)
Bug: 30934496

Merged-In: Id36474ab629ad3ffafd24381d30e3d88ac02d576
Change-Id: Id36474ab629ad3ffafd24381d30e3d88ac02d576

6 years agoPerform a non strict matching of .dm files when computing the size
Calin Juravle [Mon, 22 Jan 2018 20:50:01 +0000 (12:50 -0800)]
Perform a non strict matching of .dm files when computing the size

'adb shell pm install' creates the PackageLite structure without
validating or renaming the input files to '.apk'.

Be more permissive in DexMetadataHeler when computing the size of the
package to allow for this scenario.

(cherry picked from commit 10b27eb2ccbb8992895827c0fb21e2d3f9c727db)

Test: atest
core/tests/coretests/src/android/content/pm/dex/DexMetadataHelperTest.java
Bug: 72267410

Merged-In: Ica446b0822be71826d02d01ada015a43d8133c68
Change-Id: Ica446b0822be71826d02d01ada015a43d8133c68

6 years agoSupport installation of DexMetadata files (.dm)
Calin Juravle [Tue, 12 Dec 2017 02:26:13 +0000 (18:26 -0800)]
Support installation of DexMetadata files (.dm)

Add support in the package installer to install dex metadata files
alongside the application apks (base or splits).

During installation or update the dex metadata files will need to have a
matching apk file. The matching is done by checking the file extension
(e.g. base.apk -> base.dm, split_a.apk -> split.dm).

On disk, the metadata files are placed next to the apks.

The .dm files will be used during install-time optimizations and passed
verbatim to dex2oat.

Test: adb shell am instrument -w \
1) adb shell am instrument -w \
  -e class android.content.pm.DexMetadataHelperTest

com.android.frameworks.coretests/android.support.test.runner.AndroidJUnitRunner

2) adb install-multiple CtsClassloaderSplitApp.apk
CtsClassloaderSplitApp.dm CtsClassloaderSplitAppFeatureA.apk
CtsClassloaderSplitAppFeatureA.dm CtsClassloaderSplitAppFeatureB.apk

3) gts-tradefed -m GtsAndroidRuntimeManagerHostTestCases

(cherry picked from commit 3fc56c30000d9b88c2145d4297a97ec5061d60d1)

Bug: 30934496
Merged-In: I86f0a8307705ff3d6a5a85c2fcaae085dd62d4af
Change-Id: I86f0a8307705ff3d6a5a85c2fcaae085dd62d4af

6 years agoRename snapshotProfile to createProfileSnapshot for consistency
Calin Juravle [Tue, 5 Dec 2017 20:33:32 +0000 (12:33 -0800)]
Rename snapshotProfile to createProfileSnapshot for consistency

(cherry picked from commit 388cd5fffe7564ae364776d7f557e3a301387840)

Test: build
Bug: 30934496
Merged-In: I602262d22509b279383ff2a71e38c8bae059498a
Change-Id: I602262d22509b279383ff2a71e38c8bae059498a

6 years agoImplement ArtManager#snapshotProfile API
Calin Juravle [Thu, 30 Nov 2017 02:26:55 +0000 (18:26 -0800)]
Implement ArtManager#snapshotProfile API

Complete the implementation of ArtManager#snapshotProfile. The snapshot is
performed by calling the installer and then return to the caller via the
specified callback.

(cherry picked from commit fd9f8ae973122a50f336e38c386ecbc0095d8adc)

Bug: 30934496
Test: gts-tradefed -m GtsAndroidRuntimeManagerHostTestCases
Merged-In: I87131487846d91d79a56041445420376b61ca8e7
Change-Id: I87131487846d91d79a56041445420376b61ca8e7

6 years agoAdd SystemApis to expose runtime profile information
Calin Juravle [Wed, 8 Nov 2017 02:49:43 +0000 (18:49 -0800)]
Add SystemApis to expose runtime profile information

The API allows a system apps which acquired
{@code android.permission.READ_RUNTIME_PROFILE} to snapshot the runtime
profiles of installed packages.

The API is implemented in a new service class (AndroidRuntimeManager)
accessible from the context using
context().getPackageManager().getAndroidRuntimeManager().

The main functionality is exposed as a one way call into the
AndroidRuntimeManager with the result being posted on a callback. The
profile is available to the caller as a read-only ParcelFileDescriptor.

This CL only adds the API interfaces and validation. It does not fully
implement the functionality.

oneway void snapshotRuntimeProfile(in String packageName,
  in String codePath, in ISnapshotRuntimeProfileCallback callback)

(cherry picked from commit 45f8b29ce0ca9f80c586850c4be3a1e552bc6c2f)

Bug: 30934496
Test: gts-tradefed -m GtsAndroidRuntimeManagerHostTestCases

Merged-In: Iaa6be4715840f24508acba3162ea9c1ab725bd38
Change-Id: Iaa6be4715840f24508acba3162ea9c1ab725bd38

6 years agoLog SHA256 of secondary dex files during reconcile.
Alan Stokes [Mon, 16 Oct 2017 11:31:44 +0000 (12:31 +0100)]
Log SHA256 of secondary dex files during reconcile.

(cherry picked from commit a0023604ddaeef34049f1a245be7c42a66a7d0e8)

Bug: 63927552
Test: Exercised manually. Added unit test for DexManager.

Merged-In: Ic8e9ea4da8eb5c22fbe088a59a406e36bc2eb6fa
Change-Id: Ic8e9ea4da8eb5c22fbe088a59a406e36bc2eb6fa

6 years agoMerge "Fix link-type check warning on PMTest_Java* test apps"
Treehugger Robot [Wed, 14 Feb 2018 15:02:22 +0000 (15:02 +0000)]
Merge "Fix link-type check warning on PMTest_Java* test apps"

6 years agoMerge "Refactor runtime hidden API flag from negative to positive"
Nicolas Geoffray [Wed, 14 Feb 2018 11:41:02 +0000 (11:41 +0000)]
Merge "Refactor runtime hidden API flag from negative to positive"

6 years agoRefactor runtime hidden API flag from negative to positive
David Brazdil [Tue, 13 Feb 2018 17:04:26 +0000 (17:04 +0000)]
Refactor runtime hidden API flag from negative to positive

There are only two situations in which we want to enable hidden API
access flag checks. Turning the flag from DISABLE_ to ENABLE_
simplifies logic in ART and reduces the number places where the flag
had to be passed down to ART.

Bug: 64382372
Test: boot device, install and run apps, check log messages

(cherry picked from commit f7e31c0a2b69e97662e2bdeb7e5b5c6d0a7f995c)

Change-Id: Ib2f70696d98c6e1500d1d419d6acf0a8d0487213

6 years agoMerge "add swapPss of native process to totalSwapPss"
Martijn Coenen [Wed, 14 Feb 2018 09:17:32 +0000 (09:17 +0000)]
Merge "add swapPss of native process to totalSwapPss"

6 years agoadd a current table in CarrierIdProvider
fionaxu [Mon, 29 Jan 2018 22:08:12 +0000 (14:08 -0800)]
add a current table in CarrierIdProvider

restructure CarrierIdProvider into two tables
1. All - a private table which stores a complete mapping of all carriers
2. Current - a public table only stores the carrier identification of the
current active subs. require no permission to query.
expose the content url to public so that apps could be
notified on carrier identity change either on background or foreground.

Bug: 72571475
Test: runtest --path CarrierIdProviderTest.java
Test: Manual
Change-Id: If2a20288e63d25343f5bb582b35564d769a4e13b
(cherry picked from commit 3d00d698d7d6c10628076cca8df30adb50c52563)
Merged-in: If2a20288e63d25343f5bb582b35564d769a4e13b