This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Re: Command line arg for kernel Tracepoints
- From: Mark Wielaard <mjw at redhat dot com>
- To: h patel <hpatel05 at gmail dot com>
- Cc: Adrien Kunysz <adrien at kunysz dot be>, systemtap at sources dot redhat dot com
- Date: Mon, 03 Jan 2011 13:44:26 +0100
- Subject: Re: Command line arg for kernel Tracepoints
- References: <AANLkTikvBKHHLgD1AqCEUYx98T9ucK=8CzdJWZ2Ci8WK@mail.gmail.com> <20101230092240.GB4390@baltika> <AANLkTinjLCVwnUXxFLV=xfCk698M=ZfO=RC7JM10mgMF@mail.gmail.com> <20101230093858.GC4390@baltika> <AANLkTimU7id3RD1ewhaZiLYJO6GNCUEVCvN91aFVuCxo@mail.gmail.com>
On Mon, 2011-01-03 at 17:39 +0530, h patel wrote:
> It didn't work. Script can take the argument but kernel.trace can not.
> Looks like kernel.trace only handles pattern, not argument.
> In that case, I will limit down the types of events.
>
> Error :
> parse error: expected literal string or number
> saw: identifier 'tpoint' at test.stp:9:20
> source: probe kernel.trace(tpoint) { printf("%s
> called\n",kernel_string($log)) }
Note that kernel.trace() takes a string.
So it would be kernel.trace("tpoint") in your case.
To use wildcards, embed * inside the string.
For example to get a list of all kernel trace points:
stap -l 'kernel.trace("*")'
Cheers,
Mark