aboutsummaryrefslogtreecommitdiffstats
path: root/fs/gfs2/trace_gfs2.h
diff options
context:
space:
mode:
authorLi Zefan <lizf@cn.fujitsu.com>2009-07-12 22:33:21 -0400
committerIngo Molnar <mingo@elte.hu>2009-07-13 04:59:55 -0400
commitd0b6e04a4cd8360e3c9c419f7c30a3081a0c142a (patch)
tree621a99cac5fdc0c90a3bcdab60d5896daba04a00 /fs/gfs2/trace_gfs2.h
parent7638d5322bd89d49e013a03fe2afaeb6d214fabd (diff)
tracing/events: Move TRACE_SYSTEM outside of include guard
If TRACE_INCLDUE_FILE is defined, <trace/events/TRACE_INCLUDE_FILE.h> will be included and compiled, otherwise it will be <trace/events/TRACE_SYSTEM.h> So TRACE_SYSTEM should be defined outside of #if proctection, just like TRACE_INCLUDE_FILE. Imaging this scenario: #include <trace/events/foo.h> -> TRACE_SYSTEM == foo ... #include <trace/events/bar.h> -> TRACE_SYSTEM == bar ... #define CREATE_TRACE_POINTS #include <trace/events/foo.h> -> TRACE_SYSTEM == bar !!! and then bar.h will be included and compiled. Signed-off-by: Li Zefan <lizf@cn.fujitsu.com> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Frederic Weisbecker <fweisbec@gmail.com> LKML-Reference: <4A5A9CF1.2010007@cn.fujitsu.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'fs/gfs2/trace_gfs2.h')
-rw-r--r--fs/gfs2/trace_gfs2.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/gfs2/trace_gfs2.h b/fs/gfs2/trace_gfs2.h
index 98d6ef1c1dc0..148d55c14171 100644
--- a/fs/gfs2/trace_gfs2.h
+++ b/fs/gfs2/trace_gfs2.h
@@ -1,12 +1,11 @@
1#undef TRACE_SYSTEM
2#define TRACE_SYSTEM gfs2
3
1#if !defined(_TRACE_GFS2_H) || defined(TRACE_HEADER_MULTI_READ) 4#if !defined(_TRACE_GFS2_H) || defined(TRACE_HEADER_MULTI_READ)
2#define _TRACE_GFS2_H 5#define _TRACE_GFS2_H
3 6
4#include <linux/tracepoint.h> 7#include <linux/tracepoint.h>
5 8
6#undef TRACE_SYSTEM
7#define TRACE_SYSTEM gfs2
8#define TRACE_INCLUDE_FILE trace_gfs2
9
10#include <linux/fs.h> 9#include <linux/fs.h>
11#include <linux/buffer_head.h> 10#include <linux/buffer_head.h>
12#include <linux/dlmconstants.h> 11#include <linux/dlmconstants.h>
@@ -403,5 +402,6 @@ TRACE_EVENT(gfs2_block_alloc,
403/* This part must be outside protection */ 402/* This part must be outside protection */
404#undef TRACE_INCLUDE_PATH 403#undef TRACE_INCLUDE_PATH
405#define TRACE_INCLUDE_PATH . 404#define TRACE_INCLUDE_PATH .
405#define TRACE_INCLUDE_FILE trace_gfs2
406#include <trace/define_trace.h> 406#include <trace/define_trace.h>
407 407