diff options
author | Steven Rostedt <srostedt@redhat.com> | 2010-05-21 11:49:57 -0400 |
---|---|---|
committer | Steven Rostedt <rostedt@goodmis.org> | 2010-05-21 11:49:57 -0400 |
commit | ff5f149b6aec8edbfa3698721667acd043009a33 (patch) | |
tree | d052553eb296dfee3f01b1cb2b717cb7ccf3127a /include/trace | |
parent | f0218b3e9974f06014b61be8987159f4a20e011e (diff) | |
parent | 580d607cd666dfabfc1c7b0fb08c8ac690c7c87f (diff) |
Merge branch 'perf/core' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip into trace/tip/tracing/core-7
Conflicts:
include/linux/ftrace_event.h
include/trace/ftrace.h
kernel/trace/trace_event_perf.c
kernel/trace/trace_kprobe.c
kernel/trace/trace_syscalls.c
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'include/trace')
-rw-r--r-- | include/trace/ftrace.h | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/include/trace/ftrace.h b/include/trace/ftrace.h index e0e8daa6767e..0152b8673bd7 100644 --- a/include/trace/ftrace.h +++ b/include/trace/ftrace.h | |||
@@ -695,14 +695,14 @@ perf_trace_##call(void *__data, proto) \ | |||
695 | struct ftrace_event_call *event_call = __data; \ | 695 | struct ftrace_event_call *event_call = __data; \ |
696 | struct ftrace_data_offsets_##call __maybe_unused __data_offsets;\ | 696 | struct ftrace_data_offsets_##call __maybe_unused __data_offsets;\ |
697 | struct ftrace_raw_##call *entry; \ | 697 | struct ftrace_raw_##call *entry; \ |
698 | struct pt_regs *__regs = &get_cpu_var(perf_trace_regs); \ | 698 | struct pt_regs __regs; \ |
699 | u64 __addr = 0, __count = 1; \ | 699 | u64 __addr = 0, __count = 1; \ |
700 | unsigned long irq_flags; \ | 700 | struct hlist_head *head; \ |
701 | int __entry_size; \ | 701 | int __entry_size; \ |
702 | int __data_size; \ | 702 | int __data_size; \ |
703 | int rctx; \ | 703 | int rctx; \ |
704 | \ | 704 | \ |
705 | perf_fetch_caller_regs(__regs, 1); \ | 705 | perf_fetch_caller_regs(&__regs, 1); \ |
706 | \ | 706 | \ |
707 | __data_size = ftrace_get_offsets_##call(&__data_offsets, args); \ | 707 | __data_size = ftrace_get_offsets_##call(&__data_offsets, args); \ |
708 | __entry_size = ALIGN(__data_size + sizeof(*entry) + sizeof(u32),\ | 708 | __entry_size = ALIGN(__data_size + sizeof(*entry) + sizeof(u32),\ |
@@ -711,19 +711,20 @@ perf_trace_##call(void *__data, proto) \ | |||
711 | \ | 711 | \ |
712 | if (WARN_ONCE(__entry_size > PERF_MAX_TRACE_SIZE, \ | 712 | if (WARN_ONCE(__entry_size > PERF_MAX_TRACE_SIZE, \ |
713 | "profile buffer not large enough")) \ | 713 | "profile buffer not large enough")) \ |
714 | goto out; \ | 714 | return; \ |
715 | \ | ||
715 | entry = (struct ftrace_raw_##call *)perf_trace_buf_prepare( \ | 716 | entry = (struct ftrace_raw_##call *)perf_trace_buf_prepare( \ |
716 | __entry_size, event_call->event.type, &rctx, &irq_flags); \ | 717 | __entry_size, event_call->event.type, &__regs, &rctx); \ |
717 | if (!entry) \ | 718 | if (!entry) \ |
718 | goto out; \ | 719 | return; \ |
720 | \ | ||
719 | tstruct \ | 721 | tstruct \ |
720 | \ | 722 | \ |
721 | { assign; } \ | 723 | { assign; } \ |
722 | \ | 724 | \ |
725 | head = per_cpu_ptr(event_call->perf_events, smp_processor_id());\ | ||
723 | perf_trace_buf_submit(entry, __entry_size, rctx, __addr, \ | 726 | perf_trace_buf_submit(entry, __entry_size, rctx, __addr, \ |
724 | __count, irq_flags, __regs); \ | 727 | __count, &__regs, head); \ |
725 | out: \ | ||
726 | put_cpu_var(perf_trace_regs); \ | ||
727 | } | 728 | } |
728 | 729 | ||
729 | /* | 730 | /* |
@@ -736,7 +737,6 @@ perf_trace_##call(void *__data, proto) \ | |||
736 | static inline void perf_test_probe_##call(void) \ | 737 | static inline void perf_test_probe_##call(void) \ |
737 | { \ | 738 | { \ |
738 | check_trace_callback_type_##call(perf_trace_##template); \ | 739 | check_trace_callback_type_##call(perf_trace_##template); \ |
739 | \ | ||
740 | } | 740 | } |
741 | 741 | ||
742 | 742 | ||