summaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorAbel Vesa <abelvesa@linux.com>2015-12-02 15:39:57 +0100
committerSteven Rostedt <rostedt@goodmis.org>2015-12-23 14:27:22 -0500
commitb6b71f66a16a9212b853c168f6ec1f303c5c7a7d (patch)
tree6861e9f11c1f1c1c1dd07582bfe5ac63fe92447d /kernel
parent2701121b8f4db4d69c327c0d8f8694ff2ce30ef7 (diff)
downloadop-kernel-dev-b6b71f66a16a9212b853c168f6ec1f303c5c7a7d.zip
op-kernel-dev-b6b71f66a16a9212b853c168f6ec1f303c5c7a7d.tar.gz
ftrace: Join functions ftrace_module_init() and ftrace_init_module()
Simple cleanup. No need for two functions here. The whole work can simply be done inside 'ftrace_module_init'. Link: http://lkml.kernel.org/r/1449067197-5718-1-git-send-email-abelvesa@linux.com Signed-off-by: Abel Vesa <abelvesa@linux.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/trace/ftrace.c15
1 files changed, 6 insertions, 9 deletions
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
index e290a30..29fcc2c 100644
--- a/kernel/trace/ftrace.c
+++ b/kernel/trace/ftrace.c
@@ -4980,19 +4980,16 @@ void ftrace_release_mod(struct module *mod)
mutex_unlock(&ftrace_lock);
}
-static void ftrace_init_module(struct module *mod,
- unsigned long *start, unsigned long *end)
+void ftrace_module_init(struct module *mod)
{
+ unsigned long *start = mod->ftrace_callsites;
+ unsigned long *end = mod->ftrace_callsites +
+ mod->num_ftrace_callsites;
+
if (ftrace_disabled || start == end)
return;
- ftrace_process_locs(mod, start, end);
-}
-void ftrace_module_init(struct module *mod)
-{
- ftrace_init_module(mod, mod->ftrace_callsites,
- mod->ftrace_callsites +
- mod->num_ftrace_callsites);
+ ftrace_process_locs(mod, start, end);
}
static int ftrace_module_notify_exit(struct notifier_block *self,
OpenPOWER on IntegriCloud