All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: linux-kernel@vger.kernel.org, Ingo Molnar <mingo@kernel.org>,
	Frederic Weisbecker <fweisbec@gmail.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	"Frank Ch. Eigler" <fche@redhat.com>,
	Johannes Berg <johannes.berg@intel.com>
Subject: Re: [PATCH v9 1/1] Tracepoint: register/unregister struct tracepoint
Date: Fri, 4 Apr 2014 13:19:10 +0000 (UTC)	[thread overview]
Message-ID: <20367690.6153.1396617550266.JavaMail.zimbra@efficios.com> (raw)
In-Reply-To: <1275825820.6059.1396582817493.JavaMail.zimbra@efficios.com>

----- Original Message -----
> From: "Mathieu Desnoyers" <mathieu.desnoyers@efficios.com>
> To: "Steven Rostedt" <rostedt@goodmis.org>
> Cc: linux-kernel@vger.kernel.org, "Ingo Molnar" <mingo@kernel.org>, "Frederic Weisbecker" <fweisbec@gmail.com>,
> "Andrew Morton" <akpm@linux-foundation.org>, "Frank Ch. Eigler" <fche@redhat.com>, "Johannes Berg"
> <johannes.berg@intel.com>
> Sent: Thursday, April 3, 2014 11:40:17 PM
> Subject: Re: [PATCH v9 1/1] Tracepoint: register/unregister struct tracepoint
> 
> ----- Original Message -----
> > From: "Steven Rostedt" <rostedt@goodmis.org>
> > To: "Mathieu Desnoyers" <mathieu.desnoyers@efficios.com>
> > Cc: linux-kernel@vger.kernel.org, "Ingo Molnar" <mingo@kernel.org>,
> > "Frederic Weisbecker" <fweisbec@gmail.com>,
> > "Andrew Morton" <akpm@linux-foundation.org>, "Frank Ch. Eigler"
> > <fche@redhat.com>, "Johannes Berg"
> > <johannes.berg@intel.com>
> > Sent: Thursday, April 3, 2014 2:54:41 PM
> > Subject: Re: [PATCH v9 1/1] Tracepoint: register/unregister struct
> > tracepoint
> > 
> > On Thu, 3 Apr 2014 17:49:54 +0000 (UTC)
> > Mathieu Desnoyers <mathieu.desnoyers@efficios.com> wrote:
> > 
> > 
> > > So my current thinking is that the pre-existing code was erroneously
> > > enabling tracepoints with the name of every event enabled (including
> > > e.g. function tracer, kprobes, etc). It was not failing because
> > > tracepoint.c silently accepted to enable tracepoints were not loaded
> > > yet.
> > > 
> > 
> > If that was true, than wouldn't the error code I added have returned an
> > error?
> 
> Good point.
> 
> I found the culprit:
> 
> [    0.560002] event_trace_enable: �GT����� call ffffffff81613930 (core)
> [    0.564001] event_trace_enable: �GTȁ���� call ffffffff816139c0 (core)
> 
> compudj@ok:~/git/rostedt/linux-trace$ objdump -t vmlinux |grep
> ffffffff81613930
> ffffffff81613930 l     O .data	0000000000000090 event_sys_exit
> compudj@ok:~/git/rostedt/linux-trace$ objdump -t vmlinux |grep
> ffffffff816139c0
> ffffffff816139c0 l     O .data	0000000000000090 event_sys_enter
> 
> I'll look into those two sites tomorrow morning.

And here is the fix:

diff --git a/include/linux/ftrace_event.h b/include/linux/ftrace_event.h
index 7538389..75e64e8 100644
--- a/include/linux/ftrace_event.h
+++ b/include/linux/ftrace_event.h
@@ -371,7 +371,7 @@ struct ftrace_event_file {
 #define __TRACE_EVENT_FLAGS(name, value)                               \
        static int __init trace_init_flags_##name(void)                 \
        {                                                               \
-               event_##name.flags = value;                             \
+               event_##name.flags |= value;                            \
                return 0;                                               \
        }                                                               \
        early_initcall(trace_init_flags_##name);

I will respin a new version after some extra testing.

Thanks!

Mathieu


> 
> Thanks,
> 
> Mathieu
> 
> > 
> > -- Steve
> > 
> 
> --
> Mathieu Desnoyers
> EfficiOS Inc.
> http://www.efficios.com
> 

-- 
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com

      reply	other threads:[~2014-04-04 13:19 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-01 22:31 [PATCH v9 0/1] Tracepoint API simplification, text size shrink Mathieu Desnoyers
2014-04-01 22:31 ` [PATCH v9 1/1] Tracepoint: register/unregister struct tracepoint Mathieu Desnoyers
2014-04-03 17:15   ` Steven Rostedt
2014-04-03 17:49     ` Mathieu Desnoyers
2014-04-03 18:54       ` Steven Rostedt
2014-04-04  3:40         ` Mathieu Desnoyers
2014-04-04 13:19           ` Mathieu Desnoyers [this message]

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=20367690.6153.1396617550266.JavaMail.zimbra@efficios.com \
    --to=mathieu.desnoyers@efficios.com \
    --cc=akpm@linux-foundation.org \
    --cc=fche@redhat.com \
    --cc=fweisbec@gmail.com \
    --cc=johannes.berg@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=rostedt@goodmis.org \
    /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.