Commit Graph

3802 Commits

Author SHA1 Message Date
TreeHugger Robot
205523d0a2 Merge "Add MtpStorageManager for monitoring filesystem events" 2017-12-18 13:52:14 +00:00
Sudheer Shanka
b430d8ff06 Merge "Start processes asynchronously in AMS." 2017-12-16 18:36:48 +00:00
TreeHugger Robot
77dadd9357 Merge "Global app standby flag" 2017-12-16 18:30:23 +00:00
Amith Yamasani
172612c891 Global app standby flag
Disable app standby features if app_standby_enabled
is set to 0. This allows for UI and experiments to
control the feature.

Bug: 70655630
Test: adb shell settings put global app_standby_enabled 0
      adb shell dumpsys usagestats
      adb shell am get-standby-bucket <packagename>

Change-Id: Id6c62b078e52040767100f2997832cc586bb0806
2017-12-16 07:13:53 -08:00
TreeHugger Robot
216da5dc44 Merge "Made Autofill Field Classification API public and documented it." 2017-12-16 00:57:50 +00:00
TreeHugger Robot
391073c998 Merge "Update documentation for DIRTY in VoicemailContract" 2017-12-15 22:11:47 +00:00
TreeHugger Robot
e165e35fb9 Merge "Update documentation for preferred phone account columns" 2017-12-15 22:02:17 +00:00
Sudheer Shanka
f6690100be Start processes asynchronously in AMS.
Currently, process start is initiated in ActivityManagerService
holding the main lock and this takes ~40ms to complete. As seen
in some of the issues in previous releases, this is one of the
contributors of the lock contention in system_server. This change
tries to address this issue by moving the process start outside
the locked section.

When a process start is required, instead of doing it synchronously,
this request will be posted on a handler thread. On the handler thread,
this process start request will be completed without holding a lock.
If for some reason, we decide the process is not needed anymore before
it is actually started or being started, then AMS does everything as
usual removing the references to the process from internal state except
actually killing the process which will be handled on the handler
thread.

Bug: 68775202
Test: Ran app startup perf tests using forrest, will update the bug with results.
Test: https://docs.google.com/spreadsheets/d/1cW81guRALZXKsN-WZsKyQiCSY-RgkJ2m_M9IfqIquz8
Test: cts-tradefed run singleCommand cts-dev -m CtsActivityManagerDeviceTestCases
Test: cts-tradefed run singleCommand cts-dev -m CtsWindowManagerDeviceTestCases
Test: cts-tradefed run singleCommand cts-dev -m CtsAppTestCases
Test: cts-tradefed run singleCommand cts-dev -m CtsMultiUserHostTestCases
Test: adb shell am instrument -e package com.android.server.am -w \
      com.android.frameworks.servicestests/android.support.test.runner.AndroidJUnitRunner
Test: adb shell am instrument -e class com.android.server.pm.UserManagerTest -w \
      com.android.frameworks.servicestests/android.support.test.runner.AndroidJUnitRunner
Test: adb shell am instrument -e package android.content -w \
      com.android.frameworks.coretests/android.support.test.runner.AndroidJUnitRunner
Test: cts-tradefed run singleCommand cts-dev -m CtsProviderTestCases
Test: cts-tradefed run singleCommand cts-dev -m CtsContentTestCases -t \
      android.content.cts.ContentResolverTest
Test: cts-tradefed run singleCommand cts-dev -m CtsContentTestCases -t \
      android.content.cts.ContentProviderTest
Test: cts-tradefed run singleCommand cts-dev -m CtsWebkitTestCases
Test: cts-tradefed run singleCommand cts-dev -m CtsHostsideWebViewTests
Test: cts-tradefed run singleCommand cts-dev -m CtsAssistTestCases
Test: make WebViewLoadingTests && make tradefed-all && tradefed.sh \
      run template/local_min --template:map test=WebViewLoadingTests
Test: adb shell setprop wrap.com.google.android.apps.maps \
      '"LIBC_DEBUG_MALLOC_OPTIONS=backtrace logwrapper"'
      && adb shell dumpsys meminfo --unreachable <PID_OF_APP>
      && check ppid of <APP> is logwrapper's pid.
Test: cts-tradefed run singleCommand cts-dev -m CtsWrapWrapNoDebugTestCases
Test: cts-tradefed run singleCommand cts-dev -m CtsWrapWrapDebugTestCases
Test: cts-tradefed run singleCommand cts-dev -m CtsWrapNoWrapTestCases
Test: cts-tradefed run singleCommand cts-dev -m CtsWrapWrapDebugMallocDebugTestCases
Test: manual

Change-Id: I1fe7ce48cd5a4aadccaf6b3d6fdb5cad3304f1d3
2017-12-15 12:23:12 -08:00
Ta-wei Yen
3ec3d5bbba Update documentation for preferred phone account columns
Fixes: 70299454
Test: N/A
Change-Id: Ib8af85b5c618c1a2c62bc6c09daae057521de5d6
2017-12-15 12:14:46 -08:00
Ta-wei Yen
2fc8983250 Update documentation for DIRTY in VoicemailContract
Change-Id: I1196e5043b1c30a14d7463bd0a5ba1db485c1f57
Fixes: 70639523
Test: N/A
2017-12-15 12:03:51 -08:00
Felipe Leme
78172e70f4 Made Autofill Field Classification API public and documented it.
Test: mmm frameworks/base/:doc-comment-check-docs
Test: atest FrameworksCoreTests:SettingsBackupTest
Test: m -j 100 update-api

Fixes: 67867469

Change-Id: Iedf56a2bbcde3826eb22f5ed7a96d6ed70b968f4
2017-12-14 19:48:26 -08:00
Fyodor Kupolov
a629e4c393 Merge "Added compatibility WAL flags for Global.Settings" 2017-12-15 01:40:17 +00:00
Jerry Zhang
f9c5c2574d Add MtpStorageManager for monitoring filesystem events
MtpStorageManager keeps track of file information and
send notifications for new files. MtpDatabase now uses
this instead of MediaProvider for getting object information,
although some operations are still reflected into MP.

Since MtpStorageManager handles storage ids, remove
that field from StorageVolume and VolumeInfo.

Clean up a lot of the jni code for MtpDatabase.

Bug: 63143623
Test: Test every MtpOperation in a variety of situations on Linux and
Windows. Also use the shell to manipulate files. Verify that the cache
is consistent throughout, and the operations behave as expected. Verify
files created by the shell appear.
Test: adb shell am instrument -w android.mtp /android.support.test.runner.AndroidJUnitRunner
Change-Id: Id4ea810047b0c323399cd833047733e5daafb30a
2017-12-15 00:59:41 +00:00
Fyodor Kupolov
ee90c03fe7 Added compatibility WAL flags for Global.Settings
Added Settings.Global.SQLITE_COMPATIBILITY_WAL_FLAGS -
configuration flags for SQLite Compatibility WAL. Encoded as a key-value
list, separated by commas. E.g.:
compatibility_wal_supported=true, wal_syncmode=OFF

SQLiteCompatibilityWalFlags caches the value of
SQLITE_COMPATIBILITY_WAL_FLAGS on first access and keeps it through
the lifetime of the process for consistent behavior across all
connections.

Test: SQLiteCompatibilityWalFlagsTest
Test: setting put global ... + verify that dumpsys dbinfo has the new flag
Bug: 70226732
Bug: 70517616
Change-Id: Ifacbf5908c83351ebe5dea676eeb716af039fb14
2017-12-14 12:21:27 -08:00
TreeHugger Robot
895d73105b Merge "Add more IntDef prefixes for auto-documenting." 2017-12-14 07:17:52 +00:00
Jeff Sharkey
ce8db99114 Add more IntDef prefixes for auto-documenting.
Test: builds, boots
Bug: 70177949
Exempt-From-Owner-Approval: annotation-only changes
Change-Id: I76dde6054e06f52240bd4b1a0f196dcb74623608
2017-12-13 20:05:36 -07:00
gomo
48f1a64765 Duty Cycling and Low Power Mode GNSS feature implementations
Implementaion of 2 GNSS Android-P features:
- The Duty Cycling API to enable high accuracy applications development
- The Low Power Mode GNSS API to save power when indoor

Bug: 64009176
Test: Existing unit tests still pass.
Change-Id: I3ba3b86a635a54927c694fdd66a038757e843937
2017-12-13 13:38:31 -08:00
Adrian Roos
000cf5e06d Display Cutout: Add emulation
Adds an overlay to SystemUI that draws an emulated
cutout in the bounding polygon that the window manager
supplies.

Bug: 65689439
Test: adb shell settings put global emulate_display_cutout 2
Change-Id: I91e6832d7e4594e995241d29d6f1ed0d918d59a0
2017-12-08 14:45:18 +01:00
Eric Erfanian
62706c510c Add assisted dialing properties to the framework.
This is a manual merge of the oc-mr1-dev change
I086e761ada9a57dca61c3a412561ee54255d6260

These properties allow the feature to be propogated from
the outgoing call broadcast, to the connection, to the call,
and finally to the call log as a feature.

Test: no existing unit tests found. could use some pointers
Bug: 35963245
Change-Id: I84343fb0cda16514c01997fd71d1e819b5b7eebb
2017-12-07 10:29:17 -08:00
TreeHugger Robot
734afbe61e Merge "Moar changes for Autofill Field Classification mechanism:" 2017-12-07 17:35:23 +00:00
Chris Wren
4170751a68 add integer array values to KeyValueListParser
Test: atest NotificationSnoozeTest KeyValueListParserTest AlwaysOnDisplayPolicyTest
Change-Id: Ia26cd38258c2cf83558a9a39a6b1c2ec6dedfcb1
2017-12-07 01:06:31 -05:00
Felipe Leme
329d04097e Moar changes for Autofill Field Classification mechanism:
- Changed max score to float (range 0.0 - 1.0).
- Replaced getTopMatch() to getMatches().
- Created a Scorer interface with a default edit-distance implementation.
- Added a isFieldClassificationEnabled() method.

Test: atest CtsAutoFillServiceTestCases:FieldsClassificationTest
Test: atest CtsAutoFillServiceTestCases:EditDistanceScorerTest
Test: atest CtsAutoFillServiceTestCases:UserDataTest
Test: atest FrameworksCoreTests:SettingsBackupTest

Bug: 68045531

Change-Id: Ice6cbf548053b86b47980d9664a3a21219c0ff08
2017-12-06 13:14:15 -08:00
Makoto Onuki
53f0e02919 Don't persist LOCATION_GLOBAL_KILL_SWITCH
Bug: 68769804
Test: manual test
Test: atest ${ANDROID_BUILD_TOP}/frameworks/base/core/tests/coretests/src/android/provider/SettingsBackupTest.java
Test: atest ${ANDROID_BUILD_TOP}/frameworks/base/core/tests/coretests/src/android/provider/SettingsProviderTest.java
Test: atest SettingsProviderTest

Change-Id: I448e1aad10b517b41f58a15459c6dd1fbaf36478
2017-12-05 14:34:29 -08:00
TreeHugger Robot
5fe8eee682 Merge "Add Preferred Phone Account columns" 2017-12-05 02:49:57 +00:00
TreeHugger Robot
8587adc41e Merge "Add DIRTY_RETAIN constant" 2017-12-05 02:01:48 +00:00
Yueming Wang
edb9535922 Merge "Implement DevicePolicyManager.setSystemSettings." 2017-12-04 21:57:28 +00:00
yuemingw
0de748d833 Implement DevicePolicyManager.setSystemSettings.
b/67627818
Bug: 67627818
Test: runtest -x services/tests/servicestests/src/
com/android/server/devicepolicy/DevicePolicyManagerTest.java

design doc: https://docs.google.com/document/d/
1rvEg5jE3lMhjH-OA0iTLBUY2opM96fg7BrP81MoPnmg/edit#

Change-Id: If5f5c280957085480872f2d59ed59309cf288145
2017-12-04 21:56:46 +00:00
TreeHugger Robot
3ce82e34e6 Merge "Refactored field detection mechanism to support multiple fields." 2017-12-04 19:46:51 +00:00
Felipe Leme
452886a5b8 Refactored field detection mechanism to support multiple fields.
Now instead of using FillResponse.setFieldDetection() with an object that
contains both the autofill ids an the user data, service must:
- Set global mapping through AutofillService.setUserData()
- Pass just the autofill ids to FillResponse.setFieldClassificationIds()

This CL is purely a refactoring CL - although the new API supports multiple
values and multiple fields, the implementation is still hardcode for one
value and one field (as before).

Test: atest CtsAutoFillServiceTestCases:FieldsClassificationTest
Test: atest CtsAutoFillServiceTestCases:UserDataTest
Test: atest CtsAutoFillServiceTestCases:FillResponseTest

Bug: 68045531

Change-Id: I8d846d817dfcde3a4db7abff798bb2250e1c4e7b
2017-12-04 09:56:06 -08:00
Mehdi Alizadeh
dcc0da281b Adds soft AP timeout settings
Adds two different settings for this feature: 1) to enable/disable
the timeout mechanism (by a toggle control from Settings UI). 2) to set
the timeout duration which is configurable as an overlay.

Bug: 68712445
Test: None
Change-Id: I6232410f85b9c25477d3edada37cc7312d888f19
2017-12-01 20:23:12 +00:00
Ta-wei Yen
3c893f5b2c Add DIRTY_RETAIN constant
Previously the DIRTY flag can only be automatically or explicitly set.
There are no option to express "This operation does not change the DIRTY
flag". This causes issue when the voicemail source is downloading
changes from the server instead of uploading and would clobber the flag.

After this CL, if DIRTY is updated with DIRTY_RETAIN, the flag will not
be updated for the operation.

Change-Id: I4ed430865c28c824cbd13ccf884091637b106d8a
Fixes: 64371667
Test: CtsProviderTestCases#VoicemailProviderTest
2017-12-01 10:50:35 -08:00
Bernardo Rufino
728dceac63 Remove old BackupManagerService
As discussed, only removed the class, local interface and trampoline
still exist. That will go into a next CL.

Bug: 65823538
Test: make RunFrameworksServicesRoboTests
Test: runtest -p com.android.server.backup frameworks-services
Test: gts-tradefed run commandAndExit gts-dev -m GtsBackupTestCases
Test: gts-tradefed run commandAndExit gts-dev -m GtsBackupHostTestCases
Test: cts-tradefed run commandAndExit cts-dev -m CtsBackupTestCases
Test: adb shell bmgr backupnow <kv and full-backup packages>
Test: adb backup & adb restore
Change-Id: Ifcb4c02e364b8c4899ff376ff20cd8c89fc1af28
2017-12-01 16:21:23 +00:00
Ta-wei Yen
dc9daaa2b7 Add Preferred Phone Account columns
Fixes: 69868483
Test: CtsProviderTestCases
Change-Id: Ib67b58e7353cc847116296270d56eed216b87e38
2017-11-30 15:21:38 -08:00
Christine Franks
e5d74ccc30 Merge "Promote ACTION_DISMISS_TIMER to public API" 2017-11-30 16:23:46 +00:00
TreeHugger Robot
fd315a9fd9 Merge "Introduce Global.LOCATION_GLOBAL_KILL_SWITCH" 2017-11-29 20:21:40 +00:00
Makoto Onuki
0000d32fee Introduce Global.LOCATION_GLOBAL_KILL_SWITCH
- When it's set to "1", LOCATION_PROVIDERS_ALLOWED will return "".

- When it's updated, the provider will send the changed notification
for LOCATION_PROVIDERS_ALLOWED for all running users.

Bug: 68769804
Test: Manual test with the settings command
Test: atest $ANDROID_BUILD_TOP/frameworks/base/core/tests/coretests/src/android/provider/SettingsBackupTest.java
Change-Id: Ie14ee696788b4152f7ae442da06b0bfa8034db52
2017-11-29 09:46:35 -08:00
TreeHugger Robot
733ce63778 Merge "Extend SearchIndexablesProvider to support query sitemap." 2017-11-28 19:39:02 +00:00
Fan Zhang
9a0f6febf0 Extend SearchIndexablesProvider to support query sitemap.
Bug: 67359411
Bug: 64938328
Test: manual
Change-Id: Ic6e1ba4fc518b3aa7a26303d195c1119f6eeaafc
2017-11-28 09:59:16 -08:00
Jakub Pawlowski
c2d7be6667 Add persistent state for Hearing Aid Profile
Defines the flag used in code and the Settings.Global key names for
persisting state of the Bluetooth Hearing Aid Profile.

Test: manual
Bug: 69623109
Change-Id: I19e68be55a80f338bdc5d39d6c3c6d251f1cb514
2017-11-28 01:03:01 +00:00
Christine Franks
c545799b80 Promote ACTION_DISMISS_TIMER to public API
Bug: 69047776
Test: make -j100 && make cts -j10 && cts-tradefed run cts-dev -m
CtsAlarmClockTestCases

Change-Id: I1fedb6e36c83008ad590602af1b4e06688cc116f
2017-11-27 14:05:03 -08:00
Cody Northrop
1fe5547eda Merge "Rootless GPU Debug" 2017-11-17 20:33:33 +00:00
Cody Northrop
86cedcb583 Rootless GPU Debug
Add the ability to load GPU debug layers from the base
directory of debuggable applications.

This commit:
* Adds a new Setting to Developer options: "Enable GPU debug layers"
* Adds a new way to discover and specify GPU debug layers per app
* Moves much of the layer enabling logic into GraphicsEnvironment
* Removes the JNI component of ApplicationLoaders

Bug: 63708377
Test: Manual, CTS tests to follow
Change-Id: I7d33e9f835f49aa8d86e63bdb32037728bc8b6a4
2017-11-16 22:58:45 -07:00
Fan Zhang
55a7c5ad56 Update javadoc on SearchIndexableData
Bug: 69384409
Test: none, it's javadoc update.
Change-Id: Ifa450bb97183089edfaccabf3cd65c4910349797
2017-11-15 17:07:19 -08:00
TreeHugger Robot
a786f00f06 Merge "Refactor battery saver logic + add "per device" setting" 2017-11-15 21:32:50 +00:00
Makoto Onuki
66a7812bc9 Refactor battery saver logic + add "per device" setting
- Extract the battery saver mode transition logic to BatterySaverController.

This now also supports running different code when screen turns on and off.

- BatterySaverPolicy now takes a "per-device configuration" from config.xml,
which can be overwritten via a global setting. We'll use this to set up
max CPU frequencies.

- The actual part to write max CPU frequencies is not finished yet.

Test: atest BatterySaverPolicyTest
Bug: 68769804
Change-Id: Ife38c2cd94ac9902911b005dbbca8b0d0a62e6d7
2017-11-15 08:34:57 -08:00
Jordan Liu
eaa8032ab9 Merge "Customize the default value of Enhanced 4G LTE mode" am: 0f113b2f25 am: df79be072d
am: 92c4fa8570

Change-Id: I0c40a2435feb57c7ebd90491cd0c3055f47b7a07
2017-11-14 16:51:27 +00:00
Xiangyu/Malcolm Chen
44bb533e74 Merge "Move Ims related settings from global setting to subscription db." 2017-11-14 02:51:21 +00:00
Jordan Liu
92c4fa8570 Merge "Customize the default value of Enhanced 4G LTE mode" am: 0f113b2f25
am: df79be072d

Change-Id: I65d3b0a60ad69cb6e5c07297eeb8166230b9f720
2017-11-14 01:57:39 +00:00
Kweku Adams
b0886f3fe1 incidentd: Updating Settings Provider proto dump.
Handling potential null cases, adding comments, logging new settings,
and dumping historical operations.

Bug: 65750829
Test: flash device and check incident.proto output
Change-Id: I66fe324a91fba136e73761cfb74f3527de75d3ad
2017-11-13 16:37:15 -08:00
Jordan Liu
df79be072d Merge "Customize the default value of Enhanced 4G LTE mode"
am: 0f113b2f25

Change-Id: I85dde983b57cf901e710cd1f1ac3e409b3b7976e
2017-11-13 22:02:52 +00:00