diff options
author | Bharat Nihalani <bnihalani@nvidia.com> | 2013-10-25 18:24:15 +0530 |
---|---|---|
committer | Bharat Nihalani <bnihalani@nvidia.com> | 2013-10-27 23:15:25 -0700 |
commit | b064a16498e5b14fd3d99063b5d0488f258a19ce (patch) | |
tree | 4bcd79cf15da63f21625e5d48ed3c1b1f27ed857 /drivers/base | |
parent | f340cd6c954b831eb6de1585e49fe4c9a3c8e0ab (diff) |
base: power: reduce the default logs with wakeup_sources
/sys/kernel/debug/wakeup_sources by default gives information about
various fields. This causes the logs to be cluttered and un-readable.
Hence reduce the number of fields that get printed by default.
Change-Id: Id0ffa19a4060b9aa7afce33250ad687e0774f24d
Signed-off-by: Bharat Nihalani <bnihalani@nvidia.com>
Reviewed-on: http://git-master/r/303876
Reviewed-by: Shridhar Rasal <srasal@nvidia.com>
Reviewed-by: Sang-Hun Lee <sanlee@nvidia.com>
Reviewed-by: Deepak Nibade <dnibade@nvidia.com>
GVS: Gerrit_Virtual_Submit
Diffstat (limited to 'drivers/base')
-rw-r--r-- | drivers/base/power/wakeup.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/drivers/base/power/wakeup.c b/drivers/base/power/wakeup.c index ac3229cc2b02..a15db1f7af76 100644 --- a/drivers/base/power/wakeup.c +++ b/drivers/base/power/wakeup.c @@ -850,6 +850,7 @@ static int print_wakeup_source_stats(struct seq_file *m, active_time = ktime_set(0, 0); } +#ifdef CONFIG_PM_ADVANCED_DEBUG ret = seq_printf(m, "%-24s%lu\t\t%lu\t\t%lu\t\t%lu\t\t" "%lld\t\t%lld\t\t%lld\t\t%lld\t\t%lld\n", ws->name, active_count, ws->event_count, @@ -857,6 +858,11 @@ static int print_wakeup_source_stats(struct seq_file *m, ktime_to_ms(active_time), ktime_to_ms(total_time), ktime_to_ms(max_time), ktime_to_ms(ws->last_time), ktime_to_ms(prevent_sleep_time)); +#else + ret = seq_printf(m, "\t%lu\t\t%lu\t\t%lu\t\t%lu\t\t%lld\t\t" + "%-24s\n", active_count, ws->event_count, ws->wakeup_count, + ws->expire_count, ktime_to_ms(active_time), ws->name); +#endif spin_unlock_irqrestore(&ws->lock, flags); @@ -871,10 +877,14 @@ static int wakeup_sources_stats_show(struct seq_file *m, void *unused) { struct wakeup_source *ws; +#ifdef CONFIG_PM_ADVANCED_DEBUG seq_puts(m, "name\t\t\tactive_count\tevent_count\twakeup_count\t" "expire_count\tactive_since\ttotal_time\tmax_time\t" "last_change\tprevent_suspend_time\n"); - +#else + seq_puts(m, "active_count\tevent_count\twakeup_count\t" + "expire_count\tactive_since\t\tname\n"); +#endif rcu_read_lock(); list_for_each_entry_rcu(ws, &wakeup_sources, entry) print_wakeup_source_stats(m, ws); |