Re: [PATCH 02/11] [BUGFIX] ftrace, kprobes: Fix a deadlock onftrace_regex_lock

From: Steven Rostedt
Date: Fri May 10 2013 - 09:38:08 EST


On Fri, 2013-05-10 at 10:40 +0900, Masami Hiramatsu wrote:

> Hmm, would we really need to have the additional flag?
> I mean, do we better force ftrace user to use ftrace_ops_init before
> calling such functions as mutex itself does?

It will be hard to get right, and I don't like the macro to initialize
it all over the place. Having the check before its used contained just
in ftrace.c seems to work. None of the functions are hot paths so it's
not like its slowing anything down.

Here's what I did: