]> git.baikalelectronics.ru Git - kernel.git/commit
ftrace: perform an initialization for ftrace to enable it
authorFrederic Weisbecker <fweisbec@gmail.com>
Tue, 28 Oct 2008 19:17:38 +0000 (20:17 +0100)
committerIngo Molnar <mingo@elte.hu>
Tue, 28 Oct 2008 18:15:58 +0000 (19:15 +0100)
commit467633c12ea1dca4771da1935f74ed0e53b2da0b
treeabda53ec941c887283d496abf5d364ba80f72d5e
parente91fe3450e2c3476f2e638f5284b9532182d1de8
ftrace: perform an initialization for ftrace to enable it

Impact: corrects a bug which made the non-dyn function tracer not functional

With latest git, the non-dynamic function tracer didn't get any trace.

The problem was the fact that ftrace_enabled wasn't initialized to 1
because ftrace hasn't any init function when DYNAMIC_FTRACE is disabled.

So when a tracer tries to register an ftrace_ops struct,
__register_ftrace_function failed to set the hook.

This patch corrects it by setting an init function to initialize
ftrace during the boot.

Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
kernel/trace/ftrace.c