public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 07/13] tracing/kdb: remove redundant checking
@ 2013-03-11  7:13 zhangwei(Jovi)
  2013-03-11 14:09 ` Steven Rostedt
  0 siblings, 1 reply; 4+ messages in thread
From: zhangwei(Jovi) @ 2013-03-11  7:13 UTC (permalink / raw)
  To: linux-kernel@vger.kernel.org, Steven Rostedt, Frederic Weisbecker,
	Ingo Molnar

trace_empty is checking in while-loop, so the previous checking
is totally redundant, and more worse, the first trace entry is losted.

so remove it.

Signed-off-by: zhangwei(Jovi) <jovi.zhangwei@huawei.com>
---
 kernel/trace/trace_kdb.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/kernel/trace/trace_kdb.c b/kernel/trace/trace_kdb.c
index 3c5c5df..6489b2e 100644
--- a/kernel/trace/trace_kdb.c
+++ b/kernel/trace/trace_kdb.c
@@ -57,8 +57,7 @@ static void ftrace_dump_buf(int skip_lines, long cpu_file)
 		ring_buffer_read_start(iter.buffer_iter[cpu_file]);
 		tracing_iter_reset(&iter, cpu_file);
 	}
-	if (!trace_empty(&iter))
-		trace_find_next_entry_inc(&iter);
+
 	while (!trace_empty(&iter)) {
 		if (!cnt)
 			kdb_printf("---------------------------------\n");
-- 
1.7.9.7



^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-03-11 15:54 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-11  7:13 [PATCH 07/13] tracing/kdb: remove redundant checking zhangwei(Jovi)
2013-03-11 14:09 ` Steven Rostedt
2013-03-11 14:46   ` Jason Wessel
2013-03-11 15:54     ` Jovi Zhang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox