add forgotten tp.h and tp.c
authorPierre-Marc Fournier <pierre-marc.fournier@polymtl.ca>
Sun, 22 Mar 2009 15:28:49 +0000 (11:28 -0400)
committerPierre-Marc Fournier <pierre-marc.fournier@polymtl.ca>
Sun, 22 Mar 2009 15:28:49 +0000 (11:28 -0400)
hello/tp.c [new file with mode: 0644]
hello/tp.h [new file with mode: 0644]

diff --git a/hello/tp.c b/hello/tp.c
new file mode 100644 (file)
index 0000000..2ee7392
--- /dev/null
@@ -0,0 +1,17 @@
+#include "tp.h"
+#include "marker.h"
+#include "usterr.h"
+
+DEFINE_TRACE(hello_tptest);
+
+void tptest_probe(int anint)
+{
+       DBG("in tracepoint probe...");
+       trace_mark(ust, tptest, "anint %d", anint);
+}
+
+static void __attribute__((constructor)) init()
+{
+       DBG("connecting tracepoint...");
+       register_trace_hello_tptest(tptest_probe);
+}
diff --git a/hello/tp.h b/hello/tp.h
new file mode 100644 (file)
index 0000000..6064283
--- /dev/null
@@ -0,0 +1,5 @@
+#include "tracepoint.h"
+
+DECLARE_TRACE(hello_tptest,
+             TPPROTO(int anint),
+             TPARGS(anint));
This page took 0.030203 seconds and 4 git commands to generate.