diff options
author | Tom Zanussi <tom.zanussi@linux.intel.com> | 2016-03-03 12:54:46 -0600 |
---|---|---|
committer | Steven Rostedt <rostedt@goodmis.org> | 2016-04-19 12:17:29 -0400 |
commit | 83e99914c9e2677d8a80f2a23eca0d215d5bfb0f (patch) | |
tree | ba0ee01482e4a2e5319bd10641441ee1ae63c9f8 /kernel/trace/trace.c | |
parent | e62347d2453474fa514fbbbc4636313d34d3c850 (diff) | |
download | linux-stable-83e99914c9e2677d8a80f2a23eca0d215d5bfb0f.tar.gz linux-stable-83e99914c9e2677d8a80f2a23eca0d215d5bfb0f.tar.bz2 linux-stable-83e99914c9e2677d8a80f2a23eca0d215d5bfb0f.zip |
tracing: Add hist trigger support for pausing and continuing a trace
Allow users to append 'pause' or 'continue' to an existing trigger in
order to have it paused or to have a paused trace continue.
This expands the hist trigger syntax from this:
# echo hist:keys=xxx:vals=yyy:sort=zzz.descending \
[ if filter] >> event/trigger
to this:
# echo hist:keys=xxx:vals=yyy:sort=zzz.descending:pause or cont \
[ if filter] >> event/trigger
Link: http://lkml.kernel.org/r/b672a92c14702cb924cdf6fc27ea1809bed04907.1457029949.git.tom.zanussi@linux.intel.com
Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com>
Tested-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Reviewed-by: Namhyung Kim <namhyung@kernel.org>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'kernel/trace/trace.c')
-rw-r--r-- | kernel/trace/trace.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c index d16fa8e1cdbf..7d5c63dd410a 100644 --- a/kernel/trace/trace.c +++ b/kernel/trace/trace.c @@ -3837,6 +3837,7 @@ static const char readme_msg[] = "\t [:values=<field1[,field2,...]>]\n" "\t [:sort=<field1[,field2,...]>]\n" "\t [:size=#entries]\n" + "\t [:pause][:continue]\n" "\t [if <filter>]\n\n" "\t When a matching event is hit, an entry is added to a hash\n" "\t table using the key(s) and value(s) named, and the value of a\n" @@ -3851,7 +3852,11 @@ static const char readme_msg[] = "\t used to specify more or fewer than the default 2048 entries\n" "\t for the hashtable size.\n\n" "\t Reading the 'hist' file for the event will dump the hash\n" - "\t table in its entirety to stdout." + "\t table in its entirety to stdout.\n\n" + "\t The 'pause' parameter can be used to pause an existing hist\n" + "\t trigger or to start a hist trigger but not log any events\n" + "\t until told to do so. 'continue' can be used to start or\n" + "\t restart a paused hist trigger.\n\n" #endif ; |