Merge "Revert "Revert "Revert "Introduce initOrder for apex-system-services.""""
This commit is contained in:
committed by
Android (Google) Code Review
commit
aea37f3fb3
@@ -154,7 +154,6 @@ import com.android.server.os.NativeTombstoneManagerService;
|
||||
import com.android.server.os.SchedulingPolicyService;
|
||||
import com.android.server.people.PeopleService;
|
||||
import com.android.server.pm.ApexManager;
|
||||
import com.android.server.pm.ApexSystemServiceInfo;
|
||||
import com.android.server.pm.CrossProfileAppsService;
|
||||
import com.android.server.pm.DataLoaderManagerService;
|
||||
import com.android.server.pm.DynamicCodeLoggingService;
|
||||
@@ -225,8 +224,8 @@ import java.text.SimpleDateFormat;
|
||||
import java.util.Arrays;
|
||||
import java.util.Date;
|
||||
import java.util.LinkedList;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Map;
|
||||
import java.util.Timer;
|
||||
import java.util.TreeSet;
|
||||
import java.util.concurrent.CountDownLatch;
|
||||
@@ -1473,7 +1472,7 @@ public final class SystemServer implements Dumpable {
|
||||
// TelecomLoader hooks into classes with defined HFP logic,
|
||||
// so check for either telephony or microphone.
|
||||
if (mPackageManager.hasSystemFeature(PackageManager.FEATURE_MICROPHONE) ||
|
||||
mPackageManager.hasSystemFeature(PackageManager.FEATURE_TELEPHONY)) {
|
||||
mPackageManager.hasSystemFeature(PackageManager.FEATURE_TELEPHONY)) {
|
||||
t.traceBegin("StartTelecomLoaderService");
|
||||
mSystemServiceManager.startService(TelecomLoaderService.class);
|
||||
t.traceEnd();
|
||||
@@ -1481,7 +1480,7 @@ public final class SystemServer implements Dumpable {
|
||||
|
||||
t.traceBegin("StartTelephonyRegistry");
|
||||
telephonyRegistry = new TelephonyRegistry(
|
||||
context, new TelephonyRegistry.ConfigurationProvider());
|
||||
context, new TelephonyRegistry.ConfigurationProvider());
|
||||
ServiceManager.addService("telephony.registry", telephonyRegistry);
|
||||
t.traceEnd();
|
||||
|
||||
@@ -3018,9 +3017,7 @@ public final class SystemServer implements Dumpable {
|
||||
t.traceEnd();
|
||||
t.traceBegin("MakeTelephonyRegistryReady");
|
||||
try {
|
||||
if (telephonyRegistryF != null) {
|
||||
telephonyRegistryF.systemRunning();
|
||||
}
|
||||
if (telephonyRegistryF != null) telephonyRegistryF.systemRunning();
|
||||
} catch (Throwable e) {
|
||||
reportWtf("Notifying TelephonyRegistry running", e);
|
||||
}
|
||||
@@ -3085,12 +3082,10 @@ public final class SystemServer implements Dumpable {
|
||||
*/
|
||||
private void startApexServices(@NonNull TimingsTraceAndSlog t) {
|
||||
t.traceBegin("startApexServices");
|
||||
// TODO(b/192880996): get the list from "android" package, once the manifest entries
|
||||
// are migrated to system manifest.
|
||||
List<ApexSystemServiceInfo> services = ApexManager.getInstance().getApexSystemServices();
|
||||
for (ApexSystemServiceInfo info : services) {
|
||||
String name = info.getName();
|
||||
String jarPath = info.getJarPath();
|
||||
Map<String, String> services = ApexManager.getInstance().getApexSystemServices();
|
||||
// TODO(satayev): introduce android:order for services coming the same apexes
|
||||
for (String name : new TreeSet<>(services.keySet())) {
|
||||
String jarPath = services.get(name);
|
||||
t.traceBegin("starting " + name);
|
||||
if (TextUtils.isEmpty(jarPath)) {
|
||||
mSystemServiceManager.startService(name);
|
||||
|
||||
Reference in New Issue
Block a user