lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1283094309-6635-7-git-send-email-yong.zhang0@gmail.com>
Date:	Sun, 29 Aug 2010 23:05:09 +0800
From:	Yong Zhang <yong.zhang0@...il.com>
To:	linux-kernel@...r.kernel.org
Cc:	tglx@...utronix.de, akpm@...ux-foundation.org, mingo@...e.hu,
	arjan@...ux.intel.com, a.p.zijlstra@...llo.nl, tj@...nel.org,
	oleg@...hat.com
Subject: [RFC PATCH 6/6] timer_stats: make output more readable

From: Yong Zhang <yong.zhang@...driver.com>

When running timer_stats for a little long time, the output
will be not aligned anymore because the volume of sample count
and pid will expand.

Signed-off-by: Yong Zhang <yong.zhang0@...il.com>
Cc: Thomas Gleixner <tglx@...utronix.de>
Cc: Andrew Morton <akpm@...ux-foundation.org>
Cc: Ingo Molnar <mingo@...e.hu>
---
 kernel/time/timer_stats.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/kernel/time/timer_stats.c b/kernel/time/timer_stats.c
index 2f3b585..da85b3e 100644
--- a/kernel/time/timer_stats.c
+++ b/kernel/time/timer_stats.c
@@ -307,10 +307,10 @@ static int tstats_show(struct seq_file *m, void *v)
 	for (i = 0; i < nr_entries; i++) {
 		entry = entries + i;
  		if (entry->timer_flag & TIMER_STATS_FLAG_DEFERRABLE) {
-			seq_printf(m, "%4luD, %5d %-16s ",
+			seq_printf(m, "%10luD, %10d %-16s ",
 				entry->count, entry->pid, entry->comm);
 		} else {
-			seq_printf(m, " %4lu, %5d %-16s ",
+			seq_printf(m, " %10lu, %10d %-16s ",
 				entry->count, entry->pid, entry->comm);
 		}
 
-- 
1.7.0.4

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ