aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Documentation/trace
diff options
context:
space:
mode:
authorMasami Hiramatsu <mhiramat@kernel.org>2020-09-10 17:56:06 +0900
committerSteven Rostedt (VMware) <rostedt@goodmis.org>2020-09-21 21:06:03 -0400
commit19c311ae7c0f4f2475617a8acb7ba7b7b4575f0e (patch)
treea6791fb460ac2803d5e6590485847ea40a21413b /Documentation/trace
parentDocumentation: tracing: Add %return suffix description (diff)
downloadwireguard-linux-19c311ae7c0f4f2475617a8acb7ba7b7b4575f0e.tar.xz
wireguard-linux-19c311ae7c0f4f2475617a8acb7ba7b7b4575f0e.zip
Documentation: tracing: boot: Add an example of tracing function-calls
Add an example of tracing function calls on a specific function. Link: https://lkml.kernel.org/r/159972816669.428528.12390560334549382316.stgit@devnote2 Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Diffstat (limited to 'Documentation/trace')
-rw-r--r--Documentation/trace/boottime-trace.rst20
1 files changed, 20 insertions, 0 deletions
diff --git a/Documentation/trace/boottime-trace.rst b/Documentation/trace/boottime-trace.rst
index 9bc8aceb8c0a..ab3bfd67197c 100644
--- a/Documentation/trace/boottime-trace.rst
+++ b/Documentation/trace/boottime-trace.rst
@@ -168,6 +168,26 @@ is for tracing functions starting with "user\_", and others tracing
The instance node also accepts event nodes so that each instance
can customize its event tracing.
+With the trigger action and kprobes, you can trace function-graph while
+a function is called. For example, this will trace all function calls in
+the pci_proc_init()::
+
+ ftrace {
+ tracing_on = 0
+ tracer = function_graph
+ event.kprobes {
+ start_event {
+ probes = "pci_proc_init"
+ actions = "traceon"
+ }
+ end_event {
+ probes = "pci_proc_init%return"
+ actions = "traceoff"
+ }
+ }
+ }
+
+
This boot-time tracing also supports ftrace kernel parameters via boot
config.
For example, following kernel parameters::