Commit Graph

1002 Commits

Author SHA1 Message Date
Chalard Jean
fc758be231 Merge changes from topic "IPMS1" am: 3627deac88 am: 54d91e605c
am: 2304c7c508

Change-Id: I6908f68b1b9e7079384c4cc9f11c4e46cce694ce
2019-01-11 04:13:38 -08:00
Chalard Jean
2304c7c508 Merge changes from topic "IPMS1" am: 3627deac88
am: 54d91e605c

Change-Id: I2541996b9bfe338acabac858fdea0ad89d55df5b
2019-01-11 03:53:57 -08:00
Chalard Jean
8c141bdb8f [MS01] Add the IP memory store service.
Bug: 116512211
Test: Added initial tests
Change-Id: I9d9af4097e3e2d7afd9956b9cbfa29a9f9558ae0
2019-01-11 15:00:36 +09:00
TreeHugger Robot
94672acc5e Merge "Enable airplane mode when booting in safe mode" 2019-01-11 00:58:02 +00:00
Igor Murashkin
4de1e16570 services: Add iorap forwarding service
Add a new service to system_server. It purely forwards
data from internal APIs to iorapd over binder, it is not a binder
service itself.

Currently forwards ActivityMetricsLaunchObserver APIs from
ActivityTaskManagerInternal.

Bug: 72170747
Change-Id: Ic4fa283df1c16660099030c74a0039ef24866819
2019-01-07 13:46:47 -08:00
Richard Uhler
e95d055c5c Move rollback manager implementation to RollbackManagerServiceImpl
So that RollbackManagerService extends SystemService as per convention
and RollbackManagerServiceImpl need not be made public.

Bug: 112431924
Test: atest RollbackTest
Change-Id: I85d2fd27e4705637d5fb7342d9389ef12f869fc9
2019-01-02 10:35:57 +00:00
Richard Uhler
474dffd225 Merge "Add RollbackManagerService" 2018-12-31 18:43:21 +00:00
Richard Uhler
b29f145505 Add RollbackManagerService
This change adds RollbackManagerService as a new system service for
managing apk level rollbacks.

To work properly this requires additional selinux policy changes. Fails
gracefully in case of selinux denials, until we have a chance to sort
out the proper selinux policy.

Bug: 112431924
Bug: 116512606
Test: atest RollbackTest, with selinux enforcement off.
Test: atest CtsPermission2TestCases:PermissionPolicyTest
Change-Id: Id72aae9c4d8da9aaab3922ec9233ba335bc0198f
2018-12-31 12:38:07 +00:00
Rene Mayrhofer
7d6c8e5ec9 Enable airplane mode when booting in safe mode
Make it possible to boot in airplane mode when it was not turned on
before shutdown/reboot, either for situations where this is required by
regulation or to work around problems in normal boot. When safe mode is
engaged (Vol-Down), disable in two stages:
1. Set Settings.Global.AIRPLANE_MODE_ON as early as possible for
   subsystems to react to it during their initialization.
2. Trigger the public ConnectiviyService API to enable airplane mode. This
   has to be done during later stages in initialization because it requires
   sending broadcasts, so some RF leakage may still happen before airplane
   mode is enabled (time window of a few seconds).

Bluetooth is not currently disabled and needs to be fixed by another
change. WiFi and NFC are turned off alongside cellular modems.

Test: manual
Bug: 120145930
Change-Id: I1d61990a9d6f7cd046d28b3e49ecf402dd485063
2018-12-27 23:33:29 +00:00
Remi NGUYEN VAN
46d40a2b83 Merge "Start NetworkStack on system server start" am: 394b0d1a04 am: d69c3d4193
am: 8d73c6ec16

Change-Id: I0c116a73bfb8ab82c798ebdf0ab587f00be031ed
2018-12-25 23:53:40 -08:00
Remi NGUYEN VAN
8d73c6ec16 Merge "Start NetworkStack on system server start" am: 394b0d1a04
am: d69c3d4193

Change-Id: I00ce231850d69e32f836d8f508e28a4dc741226f
2018-12-25 23:43:25 -08:00
Remi NGUYEN VAN
9ed654ffab Start NetworkStack on system server start
The network stack will host updatable network components that are being
moved from the system server.

Test: flashed, booted
Bug: b/112869080
Change-Id: I63f98405b69615e7077aed374b8f34a84fb1e4b2
2018-12-26 12:10:17 +09:00
Yohei Yukawa
6048d89453 Temporarily move MULTI_CLIENT_IME_ENABLED to frameworks.jar
This is a preparation to implement per-profile IME in
InputMethodManagerService (IMMS).

Multi-client IME is designed and implemented to be able to deal with
multiple profiles at the same time from its beginning [1].  This means
that when multi-client IME is enabled with system properties, it also
means that per-profile IME is enabled.

At the same time, the following classes need to change its behavior
whether per-profile IME is enabled or not.

 * android.provider.Setings
 * com.android.server.inputmethod.InputMethodManagerService
 * com.android.server.textservices.TextServicesManagerService
 * com.android.server.devicepolicy.DevicePolicyManagerService
 * com.android.server.devicepolicy.OverlayPackagesProvider

The problem is that android.provider.Setings lives in the
frameworks.jar.  Hence if we want to expose something like
PER_PROFILE_IME_ENABLED to android.provider.Setings, then such a flag
needs to live in frameworks.jar.

Note that this is expected to be a temporary change.  Once per-profile
IME becomes always enabled in IMMS, we can safely roll back this
change.

Note also that static initializer of InputMethodSystemProperty is
expected to be evaluated only once as long as
InputMethodSystemProperty is loaded before Zygote.

 [1]: I41dfe854557b178d8af740bc2869c936fc88608b
      bae5bea23c

Bug: 120709962
Test: prebuilts/checkstyle/checkstyle.py -f \
        frameworks/base/core/java/android/view/inputmethod/InputMethodSystemProperty.java
Test: Manually verified as follows:
  1. make -j MultiClientInputMethod
  2. adb install -r $OUT/system/priv-app/MultiClientInputMethod/MultiClientInputMethod.apk
  3. adb root
  4. adb shell setprop persist.debug.multi_client_ime \
       com.example.android.multiclientinputmethod/.MultiClientInputMethod
  5. adb reboot
  6. Make sure that multi-client IME is enabled
Change-Id: Iad8aba7edb1e60ccc1ce5192a11e01b6aa8d00a0
2018-12-25 09:57:31 -08:00
Felipe Leme
6bb8a96683 Inline some Settings constants so they don't break the SettingsBackupTest.
Test: echo 'In TreeHugger we trust!'
Bug: 121153631

Change-Id: I7a1180a3446ba6a5aabb76fbe87113bf0e3096c6
2018-12-19 21:04:28 -08:00
Felipe Leme
d264c7284b Fixed how ContentCapture is kill-switched.
We provide a way for OEMs to kill-switch Content Capture, but it currently
does not work in the first boot (which uses default settings).

This CL changes the mechanism:

- If the property is not set, it assumes it's disabled (before it was only
  disabled when explicitly set to "false").
- To always enable it, it must be set to "always" (before it was "true").
- To check for the overlaid resource, it must be set to "default" (before it
  had to be unset).

Test: manual verification

Fixes: 121144410
Bug: 121153631

Change-Id: Ie669e43d9dce947a7bb31bc3b1768774f724675f
2018-12-19 14:20:29 -08:00
Chad Brubaker
90f391fe87 Prototype Spaceship mode qstile
Initial prototype disabling location/sensors and enabling airplane mode.
Camera/Mic will come in a followup.

Test: manual
Bug: 110842805
Change-Id: I26132fcc9ffea83e3e78a0e54882d23c99ee590c
2018-12-14 20:46:04 +00:00
Inseob Kim
ccc7473fb5 Schematize vold system properties
am: 0a91222c83

Change-Id: I3462d493bf88d7a435573659af9d8fa2062723b0
2018-12-13 16:14:18 -08:00
Inseob Kim
0a91222c83 Schematize vold system properties
Properties accessed across partitions are now schematized and will
become APIs to make explicit interfaces among partitions.

Bug: 117924132
Test: m -j
Change-Id: I8e04f643197b6c8a60cc38c6979e41c5de3469f5
Merged-In: Iedfd3c1dda665006ea5410ee787c3ca447ac7db1
(cherry picked from commit c1246e6c36)
2018-12-13 15:35:34 -08:00
Alan Stokes
be9ec976c5 Separate job service for dynamic code logging.
Decouple logging of dynamic code loading from background DEX
optimisation/reconciliation (BackgroundDexOptService).

Add DynamicCodeLoggingService to run DCL logging daily while idle and
charging.

Update DexLoggerIntegrationTests to use the new job, and to verify
that we now handle unknown class loaders.

Bug: 111336847
Test: atest -p services/core/java/com/android/server/pm/dex
Change-Id: Id688a7eef5976120be12606e726830ce32451a1e
2018-12-13 10:30:02 +00:00
Xin Li
15b123ef45 DO NOT MERGE - Merge pie-platform-release (PPRL.181205.001) into master
Bug: 120502534
Change-Id: Idc8bfb6d97a869b76cfb87ca1a494201baf9e8bd
2018-12-11 14:13:44 -08:00
Treehugger Robot
9dfd13e7ea Merge "Revert "Revert "Schematize vold system properties""" 2018-12-11 11:04:01 +00:00
Inseob Kim
5b1cc27cee Revert "Revert "Schematize vold system properties""
This reverts commit 2473b08b07.

Reason for revert: Fixed build breakage
sysprop_cpp and sysprop_java directly have been linking against
libprotobuf-cpp-full and do not set proto.type field, which could
cause ASAN error due to linking against both libproto version of full
and lite.

Change-Id: I96eb47444d7b6f6b5fef092efc1514fcdd6f33b6
Merged-In: I8e04f643197b6c8a60cc38c6979e41c5de3469f5
2018-12-11 00:23:07 +00:00
Christine Franks
6230c94e4c Merge "ColorDisplayService should always be started" 2018-12-10 21:01:25 +00:00
Xin Li
75f75c18cc DO NOT MERGE - Merge pie-platform-release (PPRL.181205.001) into stage-aosp-master
Bug: 120502534
Change-Id: I7351a1832c4bd2fd86324183ab83e9088d716822
2018-12-10 12:30:19 -08:00
Christine Franks
17a9bc82b4 ColorDisplayService should always be started
Even if no color transforms are available, for requesting whether
color modes or configurations are available.

Bug: 111215474
Test: atest FrameworksServicesTest:ColorDisplayServiceTest

Change-Id: I10a4b3b1214920117312e752ba5ea0033ff70293
2018-12-10 10:21:25 -08:00
Anthony Stange
d2ca6c6dfe Merge "Revert "Schematize vold system properties"" am: 6ee45c6f14
am: 510c8c463f

Change-Id: If137d417a8f042e8cbde842578caaa3e54bb8c6d
2018-12-07 04:37:45 -08:00
Anthony Stange
6ee45c6f14 Merge "Revert "Schematize vold system properties"" 2018-12-07 12:04:56 +00:00
Anthony Stange
2473b08b07 Revert "Schematize vold system properties"
This reverts commit 7bc31dc162.

Reason for revert: Breaking aosp_master build.

Change-Id: I34a5e9889c17e3454a0a86deabcec3c192a3da52
2018-12-07 11:43:03 +00:00
Felipe Leme
132b1c6002 Merge "Yet another (major) refactoring on Content Capture and Augmented Autofill." 2018-12-07 04:18:44 +00:00
Kenny Root
b24545385b Merge "SystemServer: initialize ADB before USB" 2018-12-07 03:36:20 +00:00
Inseob Kim
1a7cad6b1a Merge "Schematize vold system properties" am: 095d0f640e
am: 73694f8faa

Change-Id: If420ffa861d9d85f2baca9224b96f2716965f4b5
2018-12-06 18:42:29 -08:00
Treehugger Robot
095d0f640e Merge "Schematize vold system properties" 2018-12-07 01:46:45 +00:00
Felipe Leme
749b889889 Yet another (major) refactoring on Content Capture and Augmented Autofill.
Bunch of changes:

- Split public SmartSuggestionsService info ContentCaptureService and
  AugmentedAutofillService
- Renamed 'intelligence' packages to either 'contentcapture' or
  'autofil.augmented'
- Renamed internal packages and classes.
- Changed permissions, resource names, etc...
- Moved Augmented Autofill logic from IntelligeceManagerService (R.I.P.) to
  Autofill.
- Optimized IPCs by passing a String instead of the InteractionSessionId
  (that also solves the view -> service dependency).

Test: atest CtsContentCaptureServiceTestCases \
            CtsAutoFillServiceTestCases \
            FrameworksCoreTests:SettingsBackupTest
Test: manual verification with Augmented Autofill Service

Bug: 119638877
Bug: 117944706

Change-Id: I787fc2a0dbd9ad53e4d5edb0d2a9242346e4652d
2018-12-06 16:56:39 -08:00
Yunfan Chen
f963216094 Merge "Use WindowProcessController configuration for process" 2018-12-05 21:12:18 +00:00
TreeHugger Robot
0492440cd9 Merge "Changed how the Smart Suggestions service is defined." 2018-12-05 16:15:50 +00:00
Mathew Inwood
9f7fcda6c4 Merge "New receiver for signed config." 2018-12-05 12:46:12 +00:00
Mathew Inwood
4e2ed6a90b New receiver for signed config.
A new receiver is added when the system server is created. It receives
broadcasts and pulls out the config & signature, but doesn't yet do
anything with it.

go/serverless-config-design
Test: Manual
Bug: 110509075

Change-Id: Ie369e198de5e830253b17e964afb67c76735909c
2018-12-05 11:00:26 +00:00
Yunfan Chen
c2ff6cf1c5 Use WindowProcessController configuration for process
This patch is to replace the process configuration map in
WindowManagerService with the map in ActivityTaskManagerService. To do
so, we pass the ActivityTaskManagerService instance to
WindowManaserService. Adjust test base accordingly.

Test: WmTests
Test: go/wm-smoke
Bug: 117877476
Bug: 113253755
Change-Id: Ica93c3ad402e1cab682466fd16a8226176f9bae8
2018-12-04 23:00:05 -08:00
Kenny Root
4673a1d1e4 SystemServer: initialize ADB before USB
USB depends on ADB to hold the state for ADB debugging enabled, so move it
to initialize before USB attempts to initialize. This removes a race
condition introduced by moving the source of truth for ADB debugging enabled
to the AdbService instead of UsbService.

Bug: 119765805
Test: boot emulator several times
Change-Id: Ib1f5ae0ceab5abe64e2d14b9e2b3a55c9919ad2f
2018-12-05 12:20:02 +09:00
Felipe Leme
658c8e423f Changed how the Smart Suggestions service is defined.
Initially it was defined as secure Settings, but the proper way is to let the
OEMs set it by overlaying a framework resources, which an option to temporarily
override that setting using a Shell cmd (so it can be changed on CTS tests).

This CL also changes how the service can be explicitly enabled / disabled at
the time the system starts, so it can be disabled by a server-push in case of
emergencies (and also manually enable by developers when running the CTS tests
on AOSP builds).

Bug: 119776618
Bug: 111276913
Bug: 117779333

Test: adb shell settings put global \
   smart_suggestions_service_explicitly_enabled true && \
   sleep 10s && \ adb shell stop && adb shell start \
   atest CtsContentCaptureServiceTestCases
Test: atest FrameworksCoreTests:SettingsBackupTest
Test: atest CtsAutoFillServiceTestCases # to make sure it didn't break
Test: m -j SettingsProvider

Change-Id: Ibd1bba0c0d534b4b6344516d8ff893142785a57a
2018-12-04 17:46:49 -08:00
Inseob Kim
7bc31dc162 Schematize vold system properties
Properties accessed across partitions are now schematized and will
become APIs to make explicit interfaces among partitions.

Bug: 117924132
Test: m -j
Change-Id: I8e04f643197b6c8a60cc38c6979e41c5de3469f5
Merged-In: I8e04f643197b6c8a60cc38c6979e41c5de3469f5
2018-12-05 00:04:24 +00:00
TreeHugger Robot
6220baa36e Merge "Schematize vold system properties" 2018-12-05 00:00:42 +00:00
Neil Fuller
269be44f8f Merge "Add a service for reporting runtime debug info" am: 08cbafefdc am: 20547cf20d
am: b5354b7ca9

Change-Id: I2395418164f3dbcb04bc18647c6cccf7a025c1b4
2018-12-04 00:56:36 -08:00
Neil Fuller
b5354b7ca9 Merge "Add a service for reporting runtime debug info" am: 08cbafefdc
am: 20547cf20d

Change-Id: I29e7fe0355c7461ca6b939c669b9e4f3d471c4b6
2018-12-04 00:36:09 -08:00
Neil Fuller
ab0b81e921 Add a service for reporting runtime debug info
Add a service for reporting runtime debug info via dumpsys.

With expected OEM customization / module versions in play
it makes sense to have runtime and associated "core library"
information in bug reports. The dumpsys information can also
be used from from host-side tests.

Bug: 119026403
Bug: 118242715
Test: adb shell dumpsys runtimeinfo
Change-Id: I62637a1c8bfd65d5de9b3e47b8700ead4bc314f2
2018-12-03 15:41:50 +00:00
Annie Meng
8c0d41ac2d Merge "[Multi-user] Rename GlobalBackupManagerService -> BackupManagerService" 2018-11-29 13:36:57 +00:00
Annie Meng
384230f9e0 [Multi-user] Rename GlobalBackupManagerService -> BackupManagerService
Restore original naming since UserBackupManagerService is now merged.

Just find and replace, no functionality changes in this CL.

Bug: 118520567
Test: 1) atest RunFrameworksServicesRoboTests
2) atest $(find \
frameworks/base/services/tests/servicestests/src/com/android/server/backup \
-name '*Test.java')
3) adb shell bmgr flows
Change-Id: Ia37997cec93fac9ebb5102edfff9000c9cff4eb1
2018-11-28 12:30:21 +00:00
Annie Meng
178828f259 Merge "[Multi-user] Extract BackupManagerService to UserBackupManagerService" 2018-11-28 10:37:18 +00:00
Annie Meng
813716b199 [Multi-user] Extract BackupManagerService to UserBackupManagerService
BMS is split into GlobalBMS and UserBMS.
UserBMS:
- Core backup/restore implementations and bookkeeping.
- Will be per user in a future CL (only one instance in this CL to limit
scope of changes).

GlobalBMS:
- System service definition, interaction with Trampoline, user-aware
operations.
- Will be renamed back to BMS in a future CL (so BMS history can follow
UserBMS in this CL).

*** Reviewers, please pay attention to the patchset breakdown to better
understand what is a rename/move vs. new changes ***

* Base -> Patchset 2: BMS splits into GlobalBMS and UserBMS (MOVE ONLY)

Patchset 1: Rename BMS -> UserBMS
Patchset 2: Move parts of UserBMS to GlobalBMS
No new functionality, only moving existing code.

* Patchset 2 -> Patchset 3: New functionality for GlobalBMS

- Switch references from BMS to GlobalBMS in Trampoline.java.
- Change the definition of the system service in SystemServer.java to
GlobalBMS.
- Instantiate one instance of UserBMS in GlobalBMS constructor.
- Add all IBackupManager methods, which for now just directly calls the
corresponding method in UserBMS.

* Patchset 3 -> Patchset 4: Migrate usages of BMS in code (RENAME ONLY)

Find and replace, no new functionality.

* Patchset 4 -> Patchset 5: Migrate usages of BMS in tests (RENAME ONLY)

Find and replace, no new functionality.

* Patchset 5 -> Patchset 6: New tests for GlobalBMS

Add tests for all the new IBackupManager methods added (just tests
straight redirection for now).

* Overall: View Patchset 2 -> [Latest Patchset] for new code.

TODO: Modify art-profile with rename

Bug: 118520567
Test: 1) atest RunFrameworksServicesRoboTests
2) atest $(find
frameworks/base/services/tests/servicestests/src/com/android/server/backup
-name '*Test.java')
3) atest GtsBackupHostTestCases
4) atest CtsBackupTestCases
5) atest CtsBackupHostTestCases
6) atest DeviceOwnerTest
7) 'Backup Now' in Settings
8) Cloud and d2d restore in SUW; deferred restore
9) All 'adb shell bmgr' flows
10) adb backup; adb restore
Change-Id: Ib5a5837375fe950bc7d33a5e31cca16b605541f9
2018-11-27 14:23:30 +00:00
TreeHugger Robot
50f27c4a60 Merge changes from topic "revert-to-single-threaded-oms-init"
* changes:
  Decouple the display manager from the overlay manager
  Revert: "Init of OverlayManagerService on a parallel thread"
2018-11-26 16:30:24 +00:00