2009-10-06 20:10:14

by Breno Leitao

[permalink] [raw]
Subject: [PATCH] Documentation: improving tracepoints.txt

After reading the tracepoints.txt documentation, I tried to
follow the instructions to run the sample, but just assigning
CONFIG_SAMPLE_TRACEPOINTS=m wasn't enough to generate the tracepoints
samples. I also need to set CONFIG_SAMPLES=y, otherwise nothing
happens.

So, this silly patch explicit says that CONFIG_SAMPLES should be set to
compile those files.

Signed-off-by: Breno Leitao <[email protected]>
---
Documentation/trace/tracepoints.txt | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/Documentation/trace/tracepoints.txt b/Documentation/trace/tracepoints.txt
index c0e1cee..d380250 100644
--- a/Documentation/trace/tracepoints.txt
+++ b/Documentation/trace/tracepoints.txt
@@ -106,7 +106,7 @@ used to export the defined tracepoints.
See the example provided in samples/tracepoints

Compile them with your kernel. They are built during 'make' (not
-'make modules') when CONFIG_SAMPLE_TRACEPOINTS=m.
+'make modules') when CONFIG_SAMPLE=y and CONFIG_SAMPLE_TRACEPOINTS=m.

Run, as root :
modprobe tracepoint-sample (insmod order is not important)
--
1.6.0.4


2009-10-06 20:13:00

by Mathieu Desnoyers

[permalink] [raw]
Subject: Re: [PATCH] Documentation: improving tracepoints.txt

* Breno Leitao ([email protected]) wrote:
> After reading the tracepoints.txt documentation, I tried to
> follow the instructions to run the sample, but just assigning
> CONFIG_SAMPLE_TRACEPOINTS=m wasn't enough to generate the tracepoints
> samples. I also need to set CONFIG_SAMPLES=y, otherwise nothing
> happens.
>
> So, this silly patch explicit says that CONFIG_SAMPLES should be set to
> compile those files.
>
> Signed-off-by: Breno Leitao <[email protected]>

Yep, good idea. Thanks !

Acked-by: Mathieu Desnoyers <[email protected]>

> ---
> Documentation/trace/tracepoints.txt | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/Documentation/trace/tracepoints.txt b/Documentation/trace/tracepoints.txt
> index c0e1cee..d380250 100644
> --- a/Documentation/trace/tracepoints.txt
> +++ b/Documentation/trace/tracepoints.txt
> @@ -106,7 +106,7 @@ used to export the defined tracepoints.
> See the example provided in samples/tracepoints
>
> Compile them with your kernel. They are built during 'make' (not
> -'make modules') when CONFIG_SAMPLE_TRACEPOINTS=m.
> +'make modules') when CONFIG_SAMPLE=y and CONFIG_SAMPLE_TRACEPOINTS=m.
>
> Run, as root :
> modprobe tracepoint-sample (insmod order is not important)
> --
> 1.6.0.4
>

--
Mathieu Desnoyers
OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F BA06 3F25 A8FE 3BAE 9A68

2009-10-06 20:27:58

by Christoph Hellwig

[permalink] [raw]
Subject: Re: [PATCH] Documentation: improving tracepoints.txt

On Tue, Oct 06, 2009 at 05:09:31PM -0300, Breno Leitao wrote:
> After reading the tracepoints.txt documentation, I tried to
> follow the instructions to run the sample, but just assigning
> CONFIG_SAMPLE_TRACEPOINTS=m wasn't enough to generate the tracepoints
> samples. I also need to set CONFIG_SAMPLES=y, otherwise nothing
> happens.
>
> So, this silly patch explicit says that CONFIG_SAMPLES should be set to
> compile those files.

Actually raw tracepoints are deprecated. Both the documentation and the
samples should be removed, with maybe a few tidbits about the consumer
side moved to the trace_event samples because they can still be used
with them.