diff options
author | Ingo Molnar | 2013-02-03 11:14:06 +0100 |
---|---|---|
committer | Ingo Molnar | 2013-02-03 11:14:06 +0100 |
commit | f7355a5e7c722452e2cd80d6b83acb2f4423c4a2 (patch) | |
tree | 2ee172a5607de2baf25b8e9b99acd181a34676a6 /samples/tracepoints/tracepoint-probe-sample2.c | |
parent | Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/... (diff) | |
parent | tracing: Init current_trace to nop_trace and remove NULL checks (diff) | |
download | kernel-qcow2-linux-f7355a5e7c722452e2cd80d6b83acb2f4423c4a2.tar.gz kernel-qcow2-linux-f7355a5e7c722452e2cd80d6b83acb2f4423c4a2.tar.xz kernel-qcow2-linux-f7355a5e7c722452e2cd80d6b83acb2f4423c4a2.zip |
Merge branch 'tip/perf/core' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace into perf/core
Pull tracing updated from Steve Rostedt.
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'samples/tracepoints/tracepoint-probe-sample2.c')
-rw-r--r-- | samples/tracepoints/tracepoint-probe-sample2.c | 44 |
1 files changed, 0 insertions, 44 deletions
diff --git a/samples/tracepoints/tracepoint-probe-sample2.c b/samples/tracepoints/tracepoint-probe-sample2.c deleted file mode 100644 index 9fcf990e5d4b..000000000000 --- a/samples/tracepoints/tracepoint-probe-sample2.c +++ /dev/null @@ -1,44 +0,0 @@ -/* - * tracepoint-probe-sample2.c - * - * 2nd sample tracepoint probes. - */ - -#include <linux/module.h> -#include <linux/fs.h> -#include "tp-samples-trace.h" - -/* - * Here the caller only guarantees locking for struct file and struct inode. - * Locking must therefore be done in the probe to use the dentry. - */ -static void probe_subsys_event(void *ignore, - struct inode *inode, struct file *file) -{ - printk(KERN_INFO "Event is encountered with inode number %lu\n", - inode->i_ino); -} - -static int __init tp_sample_trace_init(void) -{ - int ret; - - ret = register_trace_subsys_event(probe_subsys_event, NULL); - WARN_ON(ret); - - return 0; -} - -module_init(tp_sample_trace_init); - -static void __exit tp_sample_trace_exit(void) -{ - unregister_trace_subsys_event(probe_subsys_event, NULL); - tracepoint_synchronize_unregister(); -} - -module_exit(tp_sample_trace_exit); - -MODULE_LICENSE("GPL"); -MODULE_AUTHOR("Mathieu Desnoyers"); -MODULE_DESCRIPTION("Tracepoint Probes Samples"); |