aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/trace/trace.h
diff options
context:
space:
mode:
authorPekka Paalanen <pq@iki.fi>2008-09-16 15:02:27 -0400
committerIngo Molnar <mingo@elte.hu>2008-10-14 04:37:14 -0400
commitfc5e27ae4b45a0619701a83f30d9b7fad7ed9400 (patch)
tree236b53e76430aae9f6b1abc37de9259ba95c38c6 /kernel/trace/trace.h
parent9e57fb35d711331a9b1410c5c56ebeb3733428a0 (diff)
mmiotrace: handle TRACE_PRINT entries
Also make trace_seq_print_cont() non-static, and add a newline if the seq buffer can't hold all data. Signed-off-by: Pekka Paalanen <pq@iki.fi> Acked-by: Steven Rostedt <rostedt@goodmis.org> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/trace/trace.h')
-rw-r--r--kernel/trace/trace.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/kernel/trace/trace.h b/kernel/trace/trace.h
index be3b3cf95f4b..648433d18ccb 100644
--- a/kernel/trace/trace.h
+++ b/kernel/trace/trace.h
@@ -72,6 +72,23 @@ struct print_entry {
72}; 72};
73 73
74/* 74/*
75 * trace_flag_type is an enumeration that holds different
76 * states when a trace occurs. These are:
77 * IRQS_OFF - interrupts were disabled
78 * NEED_RESCED - reschedule is requested
79 * HARDIRQ - inside an interrupt handler
80 * SOFTIRQ - inside a softirq handler
81 * CONT - multiple entries hold the trace item
82 */
83enum trace_flag_type {
84 TRACE_FLAG_IRQS_OFF = 0x01,
85 TRACE_FLAG_NEED_RESCHED = 0x02,
86 TRACE_FLAG_HARDIRQ = 0x04,
87 TRACE_FLAG_SOFTIRQ = 0x08,
88 TRACE_FLAG_CONT = 0x10,
89};
90
91/*
75 * The trace field - the most basic unit of tracing. This is what 92 * The trace field - the most basic unit of tracing. This is what
76 * is printed in the end as a single line in the trace output, such as: 93 * is printed in the end as a single line in the trace output, such as:
77 * 94 *
@@ -330,6 +347,8 @@ extern int trace_selftest_startup_sysprof(struct tracer *trace,
330 347
331extern void *head_page(struct trace_array_cpu *data); 348extern void *head_page(struct trace_array_cpu *data);
332extern int trace_seq_printf(struct trace_seq *s, const char *fmt, ...); 349extern int trace_seq_printf(struct trace_seq *s, const char *fmt, ...);
350extern void trace_seq_print_cont(struct trace_seq *s,
351 struct trace_iterator *iter);
333extern ssize_t trace_seq_to_user(struct trace_seq *s, char __user *ubuf, 352extern ssize_t trace_seq_to_user(struct trace_seq *s, char __user *ubuf,
334 size_t cnt); 353 size_t cnt);
335extern long ns2usecs(cycle_t nsec); 354extern long ns2usecs(cycle_t nsec);