diff options
author | Ingo Molnar <mingo@elte.hu> | 2008-07-10 11:43:06 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-07-10 11:43:06 +0200 |
commit | 5373fdbdc1dba69aa956098650f71b731d471885 (patch) | |
tree | 8d9f07539896a696352818820c9c5f6612370882 /kernel/trace/trace.c | |
parent | Merge branch 'tracing/ftrace' into auto-ftrace-next (diff) | |
parent | Merge branch 'tracing/mmiotrace-mergefixups' into tracing/mmiotrace (diff) | |
download | linux-5373fdbdc1dba69aa956098650f71b731d471885.tar.xz linux-5373fdbdc1dba69aa956098650f71b731d471885.zip |
Merge branch 'tracing/mmiotrace' into auto-ftrace-next
Diffstat (limited to 'kernel/trace/trace.c')
-rw-r--r-- | kernel/trace/trace.c | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c index 9ade79369bfb..4a875600733b 100644 --- a/kernel/trace/trace.c +++ b/kernel/trace/trace.c @@ -848,6 +848,48 @@ ftrace(struct trace_array *tr, struct trace_array_cpu *data, trace_function(tr, data, ip, parent_ip, flags); } +#ifdef CONFIG_MMIOTRACE +void __trace_mmiotrace_rw(struct trace_array *tr, struct trace_array_cpu *data, + struct mmiotrace_rw *rw) +{ + struct trace_entry *entry; + unsigned long irq_flags; + + raw_local_irq_save(irq_flags); + __raw_spin_lock(&data->lock); + + entry = tracing_get_trace_entry(tr, data); + tracing_generic_entry_update(entry, 0); + entry->type = TRACE_MMIO_RW; + entry->mmiorw = *rw; + + __raw_spin_unlock(&data->lock); + raw_local_irq_restore(irq_flags); + + trace_wake_up(); +} + +void __trace_mmiotrace_map(struct trace_array *tr, struct trace_array_cpu *data, + struct mmiotrace_map *map) +{ + struct trace_entry *entry; + unsigned long irq_flags; + + raw_local_irq_save(irq_flags); + __raw_spin_lock(&data->lock); + + entry = tracing_get_trace_entry(tr, data); + tracing_generic_entry_update(entry, 0); + entry->type = TRACE_MMIO_MAP; + entry->mmiomap = *map; + + __raw_spin_unlock(&data->lock); + raw_local_irq_restore(irq_flags); + + trace_wake_up(); +} +#endif + void __trace_stack(struct trace_array *tr, struct trace_array_cpu *data, unsigned long flags, |