kprobes: support per-kprobe disabling
authorMasami Hiramatsu <mhiramat@redhat.com>
Tue, 7 Apr 2009 02:01:02 +0000 (19:01 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 7 Apr 2009 15:31:08 +0000 (08:31 -0700)
commitde5bd88d5a5cce3cacea904d3503e5ebdb3852a2
treeda24ac8b38d371ee03a21ed0f3647c518689ebd3
parente579abeb58eb4b8d7321c6eb44dd9e2d0cbaebaa
kprobes: support per-kprobe disabling

Add disable_kprobe() and enable_kprobe() to disable/enable kprobes
temporarily.

disable_kprobe() asynchronously disables probe handlers of specified
kprobe.  So, after calling it, some handlers can be called at a while.
enable_kprobe() enables specified kprobe.

aggr_pre_handler and aggr_post_handler check disabled probes.  On the
other hand aggr_break_handler and aggr_fault_handler don't check it
because these handlers will be called while executing pre or post handlers
and usually those help error handling.

Signed-off-by: Masami Hiramatsu <mhiramat@redhat.com>
Acked-by: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
Cc: Anil S Keshavamurthy <anil.s.keshavamurthy@intel.com>
Cc: David S. Miller <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Documentation/kprobes.txt
include/linux/kprobes.h
kernel/kprobes.c