Set Process' start times for SystemServer.

They're currently 0, because Process.setStartTimes() is only called by
AM when binding to apps.

Test: manual verification
Bug: 141388849

Change-Id: I53fb4d62db06f6758c0e73138993e7d1230ea136
This commit is contained in:
Felipe Leme
2020-02-25 09:28:01 -08:00
parent ba58fd615f
commit 6cc15f0468

View File

@@ -394,6 +394,7 @@ public final class SystemServer {
mStartCount = SystemProperties.getInt(SYSPROP_START_COUNT, 0) + 1;
mRuntimeStartElapsedTime = SystemClock.elapsedRealtime();
mRuntimeStartUptime = SystemClock.uptimeMillis();
Process.setStartTimes(mRuntimeStartElapsedTime, mRuntimeStartUptime);
// Remember if it's runtime restart(when sys.boot_completed is already set) or reboot
// We don't use "mStartCount > 1" here because it'll be wrong on a FDE device.