Re: [PATCH 1/2] kprobes/x86: Use 5-byte NOP when the code might be modified by ftrace

From: Ingo Molnar
Date: Fri Feb 20 2015 - 05:26:33 EST

* Petr Mladek <pmladek@xxxxxxx> wrote:

> can_probe() checks if the given address points to the
> beginning of an instruction. It analyzes all the
> instructions from the beginning of the function until the
> given address. The code might be modified by another
> Kprobe. In this case, the current code is read into a
> buffer, int3 breakpoint is replaced by the saved opcode
> in the buffer, and can_probe() analyzes the buffer
> instead.
> [...]

Had to drop this patch due to build failures on 32-bit x86:

arch/x86/kernel/kprobes/core.c:258:40: error: âMCOUNT_INSN_SIZEâ undeclared (first use in this function)


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at
Please read the FAQ at