Re: [PATCH 06/11 v3] livepatch/ftrace: Add recursion protection to the ftrace callback
From: Miroslav Benes
Date: Fri Nov 06 2020 - 05:05:21 EST
On Thu, 5 Nov 2020, Steven Rostedt wrote:
> From: "Steven Rostedt (VMware)" <rostedt@xxxxxxxxxxx>
>
> If a ftrace callback does not supply its own recursion protection and
> does not set the RECURSION_SAFE flag in its ftrace_ops, then ftrace will
> make a helper trampoline to do so before calling the callback instead of
> just calling the callback directly.
>
> The default for ftrace_ops is going to change. It will expect that handlers
> provide their own recursion protection, unless its ftrace_ops states
> otherwise.
>
> Link: https://lkml.kernel.org/r/20201028115613.291169246@xxxxxxxxxxx
>
> Cc: Masami Hiramatsu <mhiramat@xxxxxxxxxx>
> Cc: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
> Cc: Josh Poimboeuf <jpoimboe@xxxxxxxxxx>
> Cc: Jiri Kosina <jikos@xxxxxxxxxx>
> Cc: Miroslav Benes <mbenes@xxxxxxx>
> Cc: Joe Lawrence <joe.lawrence@xxxxxxxxxx>
> Cc: live-patching@xxxxxxxxxxxxxxx
> Reviewed-by: Petr Mladek <pmladek@xxxxxxxx>
> Signed-off-by: Steven Rostedt (VMware) <rostedt@xxxxxxxxxxx>
Acked-by: Miroslav Benes <mbenes@xxxxxxx>
M