[PATCH 3/6] tracing/branch-profiler: do not profile managers

From: Steven Rostedt
Date: Thu Jun 04 2009 - 01:27:01 EST


From: Steven Rostedt <srostedt@xxxxxxxxxx>

Currently the branch profiler does not handle modules. Do not bother
processing the code for them.

Signed-off-by: Steven Rostedt <rostedt@xxxxxxxxxxx>
---
include/linux/compiler.h | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/include/linux/compiler.h b/include/linux/compiler.h
index 37bcb50..dd42294 100644
--- a/include/linux/compiler.h
+++ b/include/linux/compiler.h
@@ -75,9 +75,11 @@ struct ftrace_branch_data {
/*
* Note: DISABLE_BRANCH_PROFILING can be used by special lowlevel code
* to disable branch tracing on a per file basis.
+ * We currently do not profile modules.
*/
-#if defined(CONFIG_TRACE_BRANCH_PROFILING) \
- && !defined(DISABLE_BRANCH_PROFILING) && !defined(__CHECKER__)
+#if defined(CONFIG_TRACE_BRANCH_PROFILING) \
+ && !defined(DISABLE_BRANCH_PROFILING) && !defined(__CHECKER__) \
+ && !defined(MODULE)
void ftrace_likely_update(struct ftrace_branch_data *f, int val, int expect);

#define likely_notrace(x) __builtin_expect(!!(x), 1)
--
1.6.3.1

--
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/