From 5ee97e8ec04ca4de6e00279638ffc18d2878dbce Mon Sep 17 00:00:00 2001 From: Elliott Hughes Date: Fri, 28 Oct 2016 12:30:32 -0700 Subject: [PATCH] Log when bootcharting ends. Bug: http://b/26863004 Test: bootcharted N9 Change-Id: Ie91a4342d05ac5e7b6a8d37fa729edf36c38912b --- init/bootchart.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/init/bootchart.cpp b/init/bootchart.cpp index 467a83801..8fb55f03f 100644 --- a/init/bootchart.cpp +++ b/init/bootchart.cpp @@ -241,6 +241,7 @@ static void bootchart_finish() { fclose(log_disks); fclose(log_procs); acct(NULL); + LOG(INFO) << "Bootcharting finished"; } void bootchart_sample(int* timeout) { @@ -253,12 +254,12 @@ void bootchart_sample(int* timeout) { int elapsed_time = current_time - g_last_bootchart_time; if (elapsed_time >= BOOTCHART_POLLING_MS) { - /* count missed samples */ + // Count missed samples. while (elapsed_time >= BOOTCHART_POLLING_MS) { elapsed_time -= BOOTCHART_POLLING_MS; g_remaining_samples--; } - /* count may be negative, take a sample anyway */ + // Count may be negative, take a sample anyway. g_last_bootchart_time = current_time; if (bootchart_step() < 0 || g_remaining_samples <= 0) { bootchart_finish();