aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation
diff options
context:
space:
mode:
authorIngo Molnar <mingo@kernel.org>2014-06-05 05:18:34 -0400
committerIngo Molnar <mingo@kernel.org>2014-06-05 06:26:50 -0400
commit10b0256496fd6c162478547f7c6df1e052e87644 (patch)
tree7037905737ae83a86a5cdb376cd1d66f7f407e2e /Documentation
parentc56d34064b6eb9f9cde9e35bbfe16eedf3d81f94 (diff)
parent69902c718c0b476e94ed7fccd3cf29ca39fe433a (diff)
Merge branch 'perf/kprobes' into perf/core
Conflicts: arch/x86/kernel/traps.c The kprobes enhancements are fully cooked, ship them upstream. Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/kprobes.txt16
1 files changed, 15 insertions, 1 deletions
diff --git a/Documentation/kprobes.txt b/Documentation/kprobes.txt
index 0cfb00fd86ff..4bbeca8483ed 100644
--- a/Documentation/kprobes.txt
+++ b/Documentation/kprobes.txt
@@ -22,8 +22,9 @@ Appendix B: The kprobes sysctl interface
22 22
23Kprobes enables you to dynamically break into any kernel routine and 23Kprobes enables you to dynamically break into any kernel routine and
24collect debugging and performance information non-disruptively. You 24collect debugging and performance information non-disruptively. You
25can trap at almost any kernel code address, specifying a handler 25can trap at almost any kernel code address(*), specifying a handler
26routine to be invoked when the breakpoint is hit. 26routine to be invoked when the breakpoint is hit.
27(*: some parts of the kernel code can not be trapped, see 1.5 Blacklist)
27 28
28There are currently three types of probes: kprobes, jprobes, and 29There are currently three types of probes: kprobes, jprobes, and
29kretprobes (also called return probes). A kprobe can be inserted 30kretprobes (also called return probes). A kprobe can be inserted
@@ -273,6 +274,19 @@ using one of the following techniques:
273 or 274 or
274- Execute 'sysctl -w debug.kprobes_optimization=n' 275- Execute 'sysctl -w debug.kprobes_optimization=n'
275 276
2771.5 Blacklist
278
279Kprobes can probe most of the kernel except itself. This means
280that there are some functions where kprobes cannot probe. Probing
281(trapping) such functions can cause a recursive trap (e.g. double
282fault) or the nested probe handler may never be called.
283Kprobes manages such functions as a blacklist.
284If you want to add a function into the blacklist, you just need
285to (1) include linux/kprobes.h and (2) use NOKPROBE_SYMBOL() macro
286to specify a blacklisted function.
287Kprobes checks the given probe address against the blacklist and
288rejects registering it, if the given address is in the blacklist.
289
2762. Architectures Supported 2902. Architectures Supported
277 291
278Kprobes, jprobes, and return probes are implemented on the following 292Kprobes, jprobes, and return probes are implemented on the following