Messages in this thread | | | Subject | Re: [PATCH 6/9][RFC] kprobes: Allow probe on ftrace reserved text (but move it) | From | (Frank Ch. Eigler) | Date | Wed, 02 May 2012 16:40:15 -0400 |
| |
rostedt wrote:
> [...] Added KPROBE_FLAG_MOVED (as suggested by Masami) that is set > when the address is moved to get around an ftrace nop. [...]
Steve, perhaps my earlier comments on this got lost during the mailing list outage.
The gist is that a KPROBE_FLAG_MOVED being set this way accomplishes very little since nothing is looking for that flag. Instead, you should patch {arch/*}/kernel/kprobe.c kprobe_handler() to subtract MCOUNT_INSN_SIZE back out from pt_regs->ip if KPROBE_FLAG_MOVED was set. That way, kprobes clients need do not perceive the int3 movement.
- FChE
| |