From: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
To: Zoltan Kiss <zoltan.kiss@citrix.com>
Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>,
Rob Landley <rob@landley.net>, Jiri Kosina <jkosina@suse.cz>,
Steven Rostedt <rostedt@goodmis.org>,
Paul Bolle <pebolle@tiscali.nl>,
linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Documentation/trace: Correcting and extending tracepoint documentation
Date: Sat, 24 Aug 2013 14:53:09 -0400 [thread overview]
Message-ID: <20130824185309.GA13216@Krystal> (raw)
In-Reply-To: <1377208171-9004-1-git-send-email-zoltan.kiss@citrix.com>
* Zoltan Kiss (zoltan.kiss@citrix.com) wrote:
> The sample missed the moving of the header files into the events subdirectory.
> I've also extended it based on the existing headers, and mentioned the tiny
> but important role of CREATE_TRACE_POINTS.
Given that we expect tracepoints to be used though the TRACE_EVENT
wrapper, it makes sense indeed. A small nit below:
>
> Signed-off-by: Zoltan Kiss <zoltan.kiss@citrix.com>
> ---
> Documentation/trace/tracepoints.txt | 19 +++++++++++++++++--
> 1 file changed, 17 insertions(+), 2 deletions(-)
>
> diff --git a/Documentation/trace/tracepoints.txt b/Documentation/trace/tracepoints.txt
> index da49437..e8e3c4b 100644
> --- a/Documentation/trace/tracepoints.txt
> +++ b/Documentation/trace/tracepoints.txt
> @@ -40,7 +40,13 @@ Two elements are required for tracepoints :
>
> In order to use tracepoints, you should include linux/tracepoint.h.
>
> -In include/trace/subsys.h :
> +In include/trace/events/subsys.h :
> +
> +#undef TRACE_SYSTEM
> +#define TRACE_SYSTEM subsys
> +
> +#if !defined(_TRACE_SUBSYS_H) || defined(TRACE_HEADER_MULTI_READ)
> +#define _TRACE_SUBSYS_H
>
> #include <linux/tracepoint.h>
>
> @@ -48,10 +54,16 @@ DECLARE_TRACE(subsys_eventname,
> TP_PROTO(int firstarg, struct task_struct *p),
> TP_ARGS(firstarg, p));
>
> +#endif /* _TRACE_SUBSYS_H */
> +
> +/* This part must be outside protection */
> +#include <trace/define_trace.h>
> +
> In subsys/file.c (where the tracing statement must be added) :
>
> -#include <trace/subsys.h>
> +#include <trace/events/subsys.h>
>
> +#define CREATE_TRACE_POINTS
> DEFINE_TRACE(subsys_eventname);
>
> void somefct(void)
> @@ -72,6 +84,9 @@ Where :
> - TP_ARGS(firstarg, p) are the parameters names, same as found in the
> prototype.
>
> +- if you use the header in multiple source files, #define CREATE_TRACE_POINTS
> + should appear only in one source file
Missing dot at the end of the sentence above.
Other than that,
Acked-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Thanks!
Mathieu
> +
> Connecting a function (probe) to a tracepoint is done by providing a
> probe (function to call) for the specific tracepoint through
> register_trace_subsys_eventname(). Removing a probe is done through
> --
> 1.7.9.5
>
--
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com
next prev parent reply other threads:[~2013-08-24 18:53 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-08-22 21:49 Zoltan Kiss
2013-08-24 18:53 ` Mathieu Desnoyers [this message]
2013-08-27 8:57 ` Jiri Kosina
2013-08-25 8:59 ` Rob Landley
2013-09-02 17:02 ` Zoltan Kiss
2013-09-02 17:33 ` Steven Rostedt
2014-11-07 2:44 ` Steven Rostedt
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=20130824185309.GA13216@Krystal \
--to=mathieu.desnoyers@efficios.com \
--cc=jkosina@suse.cz \
--cc=konrad.wilk@oracle.com \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=pebolle@tiscali.nl \
--cc=rob@landley.net \
--cc=rostedt@goodmis.org \
--cc=zoltan.kiss@citrix.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome