aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/trace
diff options
context:
space:
mode:
authorLi Zefan <lizf@cn.fujitsu.com>2009-12-21 01:27:35 -0500
committerIngo Molnar <mingo@elte.hu>2009-12-28 04:33:06 -0500
commit07b139c8c81b97bbe55c68daf0cbeca8b1c609ca (patch)
treeea410cac398bef3cc6cc7e2d2dc3527b50aac6d1 /kernel/trace
parent659d8cfbb225f1fa5a4f8671a847ef3ab5a89660 (diff)
perf events: Remove CONFIG_EVENT_PROFILE
Quoted from Ingo: | This reminds me - i think we should eliminate CONFIG_EVENT_PROFILE - | it's an unnecessary Kconfig complication. If both PERF_EVENTS and | EVENT_TRACING is enabled we should expose generic tracepoints. | | Nor is it limited to event 'profiling', so it has become a misnomer as | well. Signed-off-by: Li Zefan <lizf@cn.fujitsu.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Paul Mackerras <paulus@samba.org> LKML-Reference: <4B2F1557.2050705@cn.fujitsu.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/trace')
-rw-r--r--kernel/trace/Makefile4
-rw-r--r--kernel/trace/trace_events_filter.c4
-rw-r--r--kernel/trace/trace_kprobe.c14
-rw-r--r--kernel/trace/trace_syscalls.c5
4 files changed, 14 insertions, 13 deletions
diff --git a/kernel/trace/Makefile b/kernel/trace/Makefile
index cd9ecd89ec77..d00c6fe23f54 100644
--- a/kernel/trace/Makefile
+++ b/kernel/trace/Makefile
@@ -51,7 +51,9 @@ endif
51obj-$(CONFIG_EVENT_TRACING) += trace_events.o 51obj-$(CONFIG_EVENT_TRACING) += trace_events.o
52obj-$(CONFIG_EVENT_TRACING) += trace_export.o 52obj-$(CONFIG_EVENT_TRACING) += trace_export.o
53obj-$(CONFIG_FTRACE_SYSCALLS) += trace_syscalls.o 53obj-$(CONFIG_FTRACE_SYSCALLS) += trace_syscalls.o
54obj-$(CONFIG_EVENT_PROFILE) += trace_event_profile.o 54ifeq ($(CONFIG_PERF_EVENTS),y)
55obj-$(CONFIG_EVENT_TRACING) += trace_event_profile.o
56endif
55obj-$(CONFIG_EVENT_TRACING) += trace_events_filter.o 57obj-$(CONFIG_EVENT_TRACING) += trace_events_filter.o
56obj-$(CONFIG_KPROBE_EVENT) += trace_kprobe.o 58obj-$(CONFIG_KPROBE_EVENT) += trace_kprobe.o
57obj-$(CONFIG_KSYM_TRACER) += trace_ksym.o 59obj-$(CONFIG_KSYM_TRACER) += trace_ksym.o
diff --git a/kernel/trace/trace_events_filter.c b/kernel/trace/trace_events_filter.c
index 50504cb228de..74563d7e102e 100644
--- a/kernel/trace/trace_events_filter.c
+++ b/kernel/trace/trace_events_filter.c
@@ -1360,7 +1360,7 @@ out_unlock:
1360 return err; 1360 return err;
1361} 1361}
1362 1362
1363#ifdef CONFIG_EVENT_PROFILE 1363#ifdef CONFIG_PERF_EVENTS
1364 1364
1365void ftrace_profile_free_filter(struct perf_event *event) 1365void ftrace_profile_free_filter(struct perf_event *event)
1366{ 1366{
@@ -1428,5 +1428,5 @@ out_unlock:
1428 return err; 1428 return err;
1429} 1429}
1430 1430
1431#endif /* CONFIG_EVENT_PROFILE */ 1431#endif /* CONFIG_PERF_EVENTS */
1432 1432
diff --git a/kernel/trace/trace_kprobe.c b/kernel/trace/trace_kprobe.c
index 375f81a568dc..75d75dec226a 100644
--- a/kernel/trace/trace_kprobe.c
+++ b/kernel/trace/trace_kprobe.c
@@ -1249,7 +1249,7 @@ static int kretprobe_event_show_format(struct ftrace_event_call *call,
1249 ", REC->" FIELD_STRING_RETIP); 1249 ", REC->" FIELD_STRING_RETIP);
1250} 1250}
1251 1251
1252#ifdef CONFIG_EVENT_PROFILE 1252#ifdef CONFIG_PERF_EVENTS
1253 1253
1254/* Kprobe profile handler */ 1254/* Kprobe profile handler */
1255static __kprobes int kprobe_profile_func(struct kprobe *kp, 1255static __kprobes int kprobe_profile_func(struct kprobe *kp,
@@ -1407,7 +1407,7 @@ static void probe_profile_disable(struct ftrace_event_call *call)
1407 disable_kprobe(&tp->rp.kp); 1407 disable_kprobe(&tp->rp.kp);
1408 } 1408 }
1409} 1409}
1410#endif /* CONFIG_EVENT_PROFILE */ 1410#endif /* CONFIG_PERF_EVENTS */
1411 1411
1412 1412
1413static __kprobes 1413static __kprobes
@@ -1417,10 +1417,10 @@ int kprobe_dispatcher(struct kprobe *kp, struct pt_regs *regs)
1417 1417
1418 if (tp->flags & TP_FLAG_TRACE) 1418 if (tp->flags & TP_FLAG_TRACE)
1419 kprobe_trace_func(kp, regs); 1419 kprobe_trace_func(kp, regs);
1420#ifdef CONFIG_EVENT_PROFILE 1420#ifdef CONFIG_PERF_EVENTS
1421 if (tp->flags & TP_FLAG_PROFILE) 1421 if (tp->flags & TP_FLAG_PROFILE)
1422 kprobe_profile_func(kp, regs); 1422 kprobe_profile_func(kp, regs);
1423#endif /* CONFIG_EVENT_PROFILE */ 1423#endif
1424 return 0; /* We don't tweek kernel, so just return 0 */ 1424 return 0; /* We don't tweek kernel, so just return 0 */
1425} 1425}
1426 1426
@@ -1431,10 +1431,10 @@ int kretprobe_dispatcher(struct kretprobe_instance *ri, struct pt_regs *regs)
1431 1431
1432 if (tp->flags & TP_FLAG_TRACE) 1432 if (tp->flags & TP_FLAG_TRACE)
1433 kretprobe_trace_func(ri, regs); 1433 kretprobe_trace_func(ri, regs);
1434#ifdef CONFIG_EVENT_PROFILE 1434#ifdef CONFIG_PERF_EVENTS
1435 if (tp->flags & TP_FLAG_PROFILE) 1435 if (tp->flags & TP_FLAG_PROFILE)
1436 kretprobe_profile_func(ri, regs); 1436 kretprobe_profile_func(ri, regs);
1437#endif /* CONFIG_EVENT_PROFILE */ 1437#endif
1438 return 0; /* We don't tweek kernel, so just return 0 */ 1438 return 0; /* We don't tweek kernel, so just return 0 */
1439} 1439}
1440 1440
@@ -1463,7 +1463,7 @@ static int register_probe_event(struct trace_probe *tp)
1463 call->regfunc = probe_event_enable; 1463 call->regfunc = probe_event_enable;
1464 call->unregfunc = probe_event_disable; 1464 call->unregfunc = probe_event_disable;
1465 1465
1466#ifdef CONFIG_EVENT_PROFILE 1466#ifdef CONFIG_PERF_EVENTS
1467 call->profile_enable = probe_profile_enable; 1467 call->profile_enable = probe_profile_enable;
1468 call->profile_disable = probe_profile_disable; 1468 call->profile_disable = probe_profile_disable;
1469#endif 1469#endif
diff --git a/kernel/trace/trace_syscalls.c b/kernel/trace/trace_syscalls.c
index 75289f372dd2..f694f66d75b0 100644
--- a/kernel/trace/trace_syscalls.c
+++ b/kernel/trace/trace_syscalls.c
@@ -421,7 +421,7 @@ int __init init_ftrace_syscalls(void)
421} 421}
422core_initcall(init_ftrace_syscalls); 422core_initcall(init_ftrace_syscalls);
423 423
424#ifdef CONFIG_EVENT_PROFILE 424#ifdef CONFIG_PERF_EVENTS
425 425
426static DECLARE_BITMAP(enabled_prof_enter_syscalls, NR_syscalls); 426static DECLARE_BITMAP(enabled_prof_enter_syscalls, NR_syscalls);
427static DECLARE_BITMAP(enabled_prof_exit_syscalls, NR_syscalls); 427static DECLARE_BITMAP(enabled_prof_exit_syscalls, NR_syscalls);
@@ -626,6 +626,5 @@ void prof_sysexit_disable(struct ftrace_event_call *call)
626 mutex_unlock(&syscall_trace_lock); 626 mutex_unlock(&syscall_trace_lock);
627} 627}
628 628
629#endif 629#endif /* CONFIG_PERF_EVENTS */
630
631 630