summaryrefslogtreecommitdiff
path: root/include/trace
diff options
context:
space:
mode:
authorMathieu Desnoyers <mathieu.desnoyers@efficios.com>2011-03-16 19:04:38 -0400
committerMathieu Desnoyers <mathieu.desnoyers@polymtl.ca>2011-03-16 19:04:38 -0400
commitaa619d07067ee4fe4891f166fe25adb0d3dfdb8d (patch)
treea3267fab6589f44072214d0e8c5ee34db2529f09 /include/trace
parent16fd1036d0559f80b8c726bac4a1dc4fe296141a (diff)
lttng-instrumentation/lttng-instrumentation-lockdep
LTTng instrumentation lockdep tracepoints lockdep_hardirqs_off lockdep_hardirqs_on lockdep_lock_acquire lockdep_lock_release lockdep_softirqs_off lockdep_softirqs_on Update for 2.6.37 to remove dependency on immediate values and play nicely with trace event lockdep instrumentation. Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Diffstat (limited to 'include/trace')
-rw-r--r--include/trace/lockdep.h37
1 files changed, 37 insertions, 0 deletions
diff --git a/include/trace/lockdep.h b/include/trace/lockdep.h
new file mode 100644
index 00000000000..dbd4629d0f8
--- /dev/null
+++ b/include/trace/lockdep.h
@@ -0,0 +1,37 @@
+#ifndef _LTTNG_TRACE_LOCKDEP_H
+#define _LTTNG_TRACE_LOCKDEP_H
+
+#include <linux/lockdep.h>
+#include <linux/tracepoint.h>
+
+/*
+ * lockdep tracing must be very careful with respect to reentrancy.
+ *
+ * It should not use immediate values for activation because it involves
+ * traps called when the code patching is done.
+ */
+DECLARE_TRACE(lockdep_hardirqs_on,
+ TP_PROTO(unsigned long retaddr),
+ TP_ARGS(retaddr));
+DECLARE_TRACE(lockdep_hardirqs_off,
+ TP_PROTO(unsigned long retaddr),
+ TP_ARGS(retaddr));
+DECLARE_TRACE(lockdep_softirqs_on,
+ TP_PROTO(unsigned long retaddr),
+ TP_ARGS(retaddr));
+DECLARE_TRACE(lockdep_softirqs_off,
+ TP_PROTO(unsigned long retaddr),
+ TP_ARGS(retaddr));
+
+/* FIXME : some duplication with lockdep TRACE EVENTs */
+DECLARE_TRACE(lockdep_lock_acquire,
+ TP_PROTO(unsigned long retaddr, unsigned int subclass,
+ struct lockdep_map *lock, int trylock, int read,
+ int hardirqs_off),
+ TP_ARGS(retaddr, subclass, lock, trylock, read, hardirqs_off));
+DECLARE_TRACE(lockdep_lock_release,
+ TP_PROTO(unsigned long retaddr, struct lockdep_map *lock, int nested),
+ TP_ARGS(retaddr, lock, nested));
+
+
+#endif /* _LTTNG_TRACE_LOCKDEP_H */