Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1473912
| From | John Stultz <john.stultz@linaro.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH 3/6] timekeeping: Prints the amounts of time spent during suspend |
| Date | 2016-09-01 00:00 +0200 |
| Message-ID | <sclI6-7NG-37@gated-at.bofh.it> (permalink) |
| References | <sclI6-7NG-19@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
From: Ruchi Kandoi <kandoiruchi@google.com>
In addition to keeping a histogram of suspend times, also
print out the time spent in suspend to dmesg.
This helps to keep track of suspend time while debugging using
kernel logs.
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Richard Cochran <richardcochran@gmail.com>
Cc: Prarit Bhargava <prarit@redhat.com>
Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com>
[jstultz: Tweaked commit message]
Signed-off-by: John Stultz <john.stultz@linaro.org>
---
kernel/time/timekeeping_debug.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/kernel/time/timekeeping_debug.c b/kernel/time/timekeeping_debug.c
index 107310a6..ca9fb80 100644
--- a/kernel/time/timekeeping_debug.c
+++ b/kernel/time/timekeeping_debug.c
@@ -75,5 +75,7 @@ void tk_debug_account_sleep_time(struct timespec64 *t)
int bin = min(fls(t->tv_sec), NUM_BINS-1);
sleep_time_bin[bin]++;
+ pr_info("Suspended for %lld.%03lu seconds\n", (s64)t->tv_sec,
+ t->tv_nsec / NSEC_PER_MSEC);
}
--
1.9.1
Back to linux.kernel | Previous | Next | Find similar | Unroll thread
[PATCH 3/6] timekeeping: Prints the amounts of time spent during suspend John Stultz <john.stultz@linaro.org> - 2016-09-01 00:00 +0200
csiph-web