summaryrefslogtreecommitdiff
path: root/services/java/com/android/server/SystemServer.java
diff options
context:
space:
mode:
authorDamien Bargiacchi <drb@google.com>2018-05-30 13:28:15 -0700
committerDamien Bargiacchi <drb@google.com>2018-06-07 16:11:34 -0700
commitae4cb673430bfb88eb6bee5f35653a496ebac4e4 (patch)
tree133611c2a6b7075588cbae582d1a22a280e18b33 /services/java/com/android/server/SystemServer.java
parent2e9b8c37532c53a1f2d9a29c8630794302b1b26d (diff)
Start the WearPowerService with the other Wear system services
The WearPowerService is in charge of coordinating and keeping track of devices and state concerned with power. Bug: 77293569 Change-Id: Ia40ad44a53ef6872dd7ebefd58e17179126dde92
Diffstat (limited to 'services/java/com/android/server/SystemServer.java')
-rw-r--r--services/java/com/android/server/SystemServer.java12
1 files changed, 11 insertions, 1 deletions
diff --git a/services/java/com/android/server/SystemServer.java b/services/java/com/android/server/SystemServer.java
index c864190bb34b..dc6a613c08df 100644
--- a/services/java/com/android/server/SystemServer.java
+++ b/services/java/com/android/server/SystemServer.java
@@ -201,6 +201,8 @@ public final class SystemServer {
"com.google.android.clockwork.ThermalObserver";
private static final String WEAR_CONNECTIVITY_SERVICE_CLASS =
"com.android.clockwork.connectivity.WearConnectivityService";
+ private static final String WEAR_POWER_SERVICE_CLASS =
+ "com.android.clockwork.power.WearPowerService";
private static final String WEAR_SIDEKICK_SERVICE_CLASS =
"com.google.android.clockwork.sidekick.SidekickService";
private static final String WEAR_DISPLAY_SERVICE_CLASS =
@@ -1549,12 +1551,20 @@ public final class SystemServer {
}
if (isWatch) {
+ // Must be started before services that depend it, e.g. WearConnectivityService
+ traceBeginAndSlog("StartWearPowerService");
+ mSystemServiceManager.startService(WEAR_POWER_SERVICE_CLASS);
+ traceEnd();
+
traceBeginAndSlog("StartWearConnectivityService");
mSystemServiceManager.startService(WEAR_CONNECTIVITY_SERVICE_CLASS);
traceEnd();
- traceBeginAndSlog("StartWearTimeService");
+ traceBeginAndSlog("StartWearDisplayService");
mSystemServiceManager.startService(WEAR_DISPLAY_SERVICE_CLASS);
+ traceEnd();
+
+ traceBeginAndSlog("StartWearTimeService");
mSystemServiceManager.startService(WEAR_TIME_SERVICE_CLASS);
traceEnd();