summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Neil Fuller <nfuller@google.com> 2021-03-08 10:07:35 +0000
committer Neil Fuller <nfuller@google.com> 2021-03-08 10:07:35 +0000
commitfadb4127bceff0c3894cda9256936c3a8d74eea7 (patch)
tree66a907c989f924d3e9695a9879546acd29c25bf2
parent66a4de0653a8ca2ae3343c5ffa8efb2c2caf38a9 (diff)
Add more information to time detection logs
When receiving only dumpsys from time_detector, it can be useful to know what the system clock time was before it was changed. The logging takes place after the clock has been changed so this is currently missing. Bug: 176316840 Test: build / treehugger only Change-Id: I7441706cf5daaec5377289f215b15cad1d6de4f9
-rw-r--r--services/core/java/com/android/server/timedetector/TimeDetectorStrategyImpl.java1
1 files changed, 1 insertions, 0 deletions
diff --git a/services/core/java/com/android/server/timedetector/TimeDetectorStrategyImpl.java b/services/core/java/com/android/server/timedetector/TimeDetectorStrategyImpl.java
index c4c620c41918..16e8632c6e40 100644
--- a/services/core/java/com/android/server/timedetector/TimeDetectorStrategyImpl.java
+++ b/services/core/java/com/android/server/timedetector/TimeDetectorStrategyImpl.java
@@ -720,6 +720,7 @@ public final class TimeDetectorStrategyImpl implements TimeDetectorStrategy {
String logMsg = "Set system clock using time=" + newTime
+ " cause=" + cause
+ " elapsedRealtimeMillis=" + elapsedRealtimeMillis
+ + " (old) actualSystemClockMillis=" + actualSystemClockMillis
+ " newSystemClockMillis=" + newSystemClockMillis;
if (DBG) {
Slog.d(LOG_TAG, logMsg);