[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <159887797965.1330989.8398347951884039748.stgit@devnote2>
Date: Mon, 31 Aug 2020 21:46:19 +0900
From: Masami Hiramatsu <mhiramat@...nel.org>
To: Steven Rostedt <rostedt@...dmis.org>,
Jonathan Corbet <corbet@....net>
Cc: mhiramat@...nel.org, linux-kernel@...r.kernel.org,
linux-doc@...r.kernel.org
Subject: [PATCH 6/6] Documentation: tracing: boot: Add an example of tracing function-calls
Add an example of tracing function calls on a specific function.
Signed-off-by: Masami Hiramatsu <mhiramat@...nel.org>
---
Documentation/trace/boottime-trace.rst | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/Documentation/trace/boottime-trace.rst b/Documentation/trace/boottime-trace.rst
index 1341b449acaa..c216f5695ae2 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::
Powered by blists - more mailing lists