livepatch: use FTRACE_OPS_FL_IPMODIFY

Use the FTRACE_OPS_FL_IPMODIFY flag to prevent conflicts with other
ftrace users who also modify regs->ip.

Signed-off-by: Josh Poimboeuf <[email protected]>
Reviewed-by: Petr Mladek <[email protected]>
Acked-by: Masami Hiramatsu <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
This commit is contained in:
Josh Poimboeuf authored and Jiri Kosina committed 2014-12-22 20:05:59 +01:00
1 parent b5bfc51707
commit 33e8612f64
1 file changed
+2 -1
+2 -1
View File
@@ -641,7 +641,8 @@ static int klp_init_func(struct klp_object *obj, struct klp_func *func)
ops->private = func;
ops->func = klp_ftrace_handler;
ops->flags = FTRACE_OPS_FL_SAVE_REGS | FTRACE_OPS_FL_DYNAMIC;
ops->flags = FTRACE_OPS_FL_SAVE_REGS | FTRACE_OPS_FL_DYNAMIC |
FTRACE_OPS_FL_IPMODIFY;
func->fops = ops;
func->state = KLP_DISABLED;