All of lore.kernel.org
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: linux-kernel@vger.kernel.org
Cc: Ingo Molnar <mingo@elte.hu>,
	Andrew Morton <akpm@linux-foundation.org>,
	Frederic Weisbecker <fweisbec@gmail.com>,
	Chase Douglas <chase.douglas@canonical.com>
Subject: [PATCH 6/8] tracing: Add documentation for trace commands mod, traceon/traceoff
Date: Tue, 27 Apr 2010 21:27:29 -0400	[thread overview]
Message-ID: <20100428013806.994023607@goodmis.org> (raw)
In-Reply-To: 20100428012723.119106602@goodmis.org

[-- Attachment #1: 0006-tracing-Add-documentation-for-trace-commands-mod-tra.patch --]
[-- Type: text/plain, Size: 2567 bytes --]

From: Chase Douglas <chase.douglas@canonical.com>

The mod command went in as commit
64e7c440618998fd69eee6ab490b042d12248021

The traceon/traceoff commands went in as commit
23b4ff3aa479c9e3bb23cb6b2d0a97878399784a

Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
LKML-Reference: <1272045759-32018-1-git-send-email-chase.douglas@canonical.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
 Documentation/trace/ftrace.txt |   44 ++++++++++++++++++++++++++++++++++++++++
 1 files changed, 44 insertions(+), 0 deletions(-)

diff --git a/Documentation/trace/ftrace.txt b/Documentation/trace/ftrace.txt
index 5201181..557c1ed 100644
--- a/Documentation/trace/ftrace.txt
+++ b/Documentation/trace/ftrace.txt
@@ -155,6 +155,9 @@ of ftrace. Here is a list of some of the key files:
 	to be traced. Echoing names of functions into this file
 	will limit the trace to only those functions.
 
+	This interface also allows for commands to be used. See the
+	"Filter commands" section for more details.
+
   set_ftrace_notrace:
 
 	This has an effect opposite to that of
@@ -1824,6 +1827,47 @@ this special filter via:
  echo > set_graph_function
 
 
+Filter commands
+---------------
+
+A few commands are supported by the set_ftrace_filter interface.
+Trace commands have the following format:
+
+<function>:<command>:<parameter>
+
+The following commands are supported:
+
+- mod
+  This command enables function filtering per module. The
+  parameter defines the module. For example, if only the write*
+  functions in the ext3 module are desired, run:
+
+   echo 'write*:mod:ext3' > set_ftrace_filter
+
+  This command interacts with the filter in the same way as
+  filtering based on function names. Thus, adding more functions
+  in a different module is accomplished by appending (>>) to the
+  filter file. Remove specific module functions by prepending
+  '!':
+
+   echo '!writeback*:mod:ext3' >> set_ftrace_filter
+
+- traceon/traceoff
+  These commands turn tracing on and off when the specified
+  functions are hit. The parameter determines how many times the
+  tracing system is turned on and off. If unspecified, there is
+  no limit. For example, to disable tracing when a schedule bug
+  is hit the first 5 times, run:
+
+   echo '__schedule_bug:traceoff:5' > set_ftrace_filter
+
+  These commands are cumulative whether or not they are appended
+  to set_ftrace_filter. To remove a command, prepend it by '!'
+  and drop the parameter:
+
+   echo '!__schedule_bug:traceoff' > set_ftrace_filter
+
+
 trace_pipe
 ----------
 
-- 
1.7.0



  parent reply	other threads:[~2010-04-28  1:38 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-28  1:27 [PATCH 0/8] [GIT PULL] tracing: various updates Steven Rostedt
2010-04-28  1:27 ` [PATCH 1/8] tracing: Add ftrace events for graph tracer Steven Rostedt
2010-04-28  1:27 ` [PATCH 2/8] tracing: Have graph flags passed in to ouput functions Steven Rostedt
2010-04-28  1:27 ` [PATCH 3/8] tracing: Add graph output support for irqsoff tracer Steven Rostedt
2010-04-28  1:27 ` [PATCH 4/8] ring-buffer: Make non-consuming read less expensive with lots of cpus Steven Rostedt
2010-04-28  1:27 ` [PATCH 5/8] ring-buffer: Make benchmark handle missed events Steven Rostedt
2010-04-28  1:27 ` Steven Rostedt [this message]
2010-04-28  1:27 ` [PATCH 7/8] tracing: Show sample std dev in function profiling Steven Rostedt
2010-04-28  1:27 ` [PATCH 8/8] tracing: Fix sleep time " Steven Rostedt
2010-04-30  8:00 ` [PATCH 0/8] [GIT PULL] tracing: various updates Ingo Molnar
2010-04-30  9:47   ` Ingo Molnar

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100428013806.994023607@goodmis.org \
    --to=rostedt@goodmis.org \
    --cc=akpm@linux-foundation.org \
    --cc=chase.douglas@canonical.com \
    --cc=fweisbec@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.