lkml.org 
[lkml]   [2011]   [May]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[RFC patch 11/32] trace event module remove semicolons
Part of the gradual TRACE_EVENT() semicolon removal. Enables creation of array
of events, thus saving space for trace event probes.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
CC: Steven Rostedt <rostedt@goodmis.org>
CC: Frederic Weisbecker <fweisbec@gmail.com>
CC: Ingo Molnar <mingo@elte.hu>
CC: Thomas Gleixner <tglx@linutronix.de>
CC: Li Zefan <lizf@cn.fujitsu.com>
CC: Rusty Russell <rusty@rustcorp.com.au>
---
include/trace/events/module.h | 17 +++++++++++------
1 file changed, 11 insertions(+), 6 deletions(-)
Index: linux-2.6-lttng/include/trace/events/module.h
===================================================================
--- linux-2.6-lttng.orig/include/trace/events/module.h
+++ linux-2.6-lttng/include/trace/events/module.h
@@ -18,6 +18,9 @@

#ifdef CONFIG_MODULES

+#ifndef _TRACE_MODULE_DEF_
+#define _TRACE_MODULE_DEF_
+
struct module;

#define show_module_flags(flags) __print_flags(flags, "", \
@@ -25,6 +28,8 @@ struct module;
{ (1UL << TAINT_FORCED_MODULE), "F" }, \
{ (1UL << TAINT_CRAP), "C" })

+#endif /* _TRACE_MODULE_DEF_ */
+
TRACE_EVENT(module_load,

TP_PROTO(struct module *mod),
@@ -42,7 +47,7 @@ TRACE_EVENT(module_load,
),

TP_printk("%s %s", __get_str(name), show_module_flags(__entry->taints))
-);
+)

TRACE_EVENT(module_free,

@@ -59,7 +64,7 @@ TRACE_EVENT(module_free,
),

TP_printk("%s", __get_str(name))
-);
+)

#ifdef CONFIG_MODULE_UNLOAD
/* trace_module_get/put are only used if CONFIG_MODULE_UNLOAD is defined */
@@ -84,21 +89,21 @@ DECLARE_EVENT_CLASS(module_refcnt,

TP_printk("%s call_site=%pf refcnt=%d",
__get_str(name), (void *)__entry->ip, __entry->refcnt)
-);
+)

DEFINE_EVENT(module_refcnt, module_get,

TP_PROTO(struct module *mod, unsigned long ip),

TP_ARGS(mod, ip)
-);
+)

DEFINE_EVENT(module_refcnt, module_put,

TP_PROTO(struct module *mod, unsigned long ip),

TP_ARGS(mod, ip)
-);
+)
#endif /* CONFIG_MODULE_UNLOAD */

TRACE_EVENT(module_request,
@@ -121,7 +126,7 @@ TRACE_EVENT(module_request,

TP_printk("%s wait=%d call_site=%pf",
__get_str(name), (int)__entry->wait, (void *)__entry->ip)
-);
+)

#endif /* CONFIG_MODULES */



\
 
 \ /
  Last update: 2011-05-03 00:07    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site