Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 68cc7b8e authored by Amos Bianchi's avatar Amos Bianchi Committed by Android (Google) Code Review
Browse files

Merge "Explicitly start device lock system service." into udc-qpr-dev

parents d2b57db8 3ee07a73
Loading
Loading
Loading
Loading
+11 −0
Original line number Diff line number Diff line
@@ -434,6 +434,10 @@ public final class SystemServer implements Dumpable {
                    + "OnDevicePersonalizationSystemService$Lifecycle";
    private static final String UPDATABLE_DEVICE_CONFIG_SERVICE_CLASS =
            "com.android.server.deviceconfig.DeviceConfigInit$Lifecycle";
    private static final String DEVICE_LOCK_SERVICE_CLASS =
            "com.android.server.devicelock.DeviceLockService";
    private static final String DEVICE_LOCK_APEX_PATH =
            "/apex/com.android.devicelock/javalib/service-devicelock.jar";

    private static final String TETHERING_CONNECTOR_CLASS = "android.net.ITetheringConnector";

@@ -2864,6 +2868,13 @@ public final class SystemServer implements Dumpable {
        mSystemServiceManager.startService(HEALTHCONNECT_MANAGER_SERVICE_CLASS);
        t.traceEnd();

        if (mPackageManager.hasSystemFeature(PackageManager.FEATURE_DEVICE_LOCK)) {
            t.traceBegin("DeviceLockService");
            mSystemServiceManager.startServiceFromJar(DEVICE_LOCK_SERVICE_CLASS,
                    DEVICE_LOCK_APEX_PATH);
            t.traceEnd();
        }

        // These are needed to propagate to the runnable below.
        final NetworkManagementService networkManagementF = networkManagement;
        final NetworkPolicyManagerService networkPolicyF = networkPolicy;