From 6e71f8c9d4f91119a1531be68356ebfd1b8a1969 Mon Sep 17 00:00:00 2001 From: Pierre-Marc Fournier Date: Sun, 22 Mar 2009 11:28:49 -0400 Subject: [PATCH] add forgotten tp.h and tp.c --- hello/tp.c | 17 +++++++++++++++++ hello/tp.h | 5 +++++ 2 files changed, 22 insertions(+) create mode 100644 hello/tp.c create mode 100644 hello/tp.h diff --git a/hello/tp.c b/hello/tp.c new file mode 100644 index 0000000..2ee7392 --- /dev/null +++ b/hello/tp.c @@ -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 index 0000000..6064283 --- /dev/null +++ b/hello/tp.h @@ -0,0 +1,5 @@ +#include "tracepoint.h" + +DECLARE_TRACE(hello_tptest, + TPPROTO(int anint), + TPARGS(anint)); -- 2.34.1