From: Steven Rostedt <rostedt@goodmis.org>
To: Josef Bacik <josef@redhat.com>
Cc: linux-kernel@vger.kernel.org, Frederic Weisbecker <fweisbec@gmail.com>
Subject: Re: trace_printk is doing weird things with my arguments
Date: Mon, 12 Dec 2011 15:44:59 -0500 [thread overview]
Message-ID: <1323722699.1377.9.camel@gandalf.stny.rr.com> (raw)
In-Reply-To: <20111212203214.GB3603@localhost.localdomain>
On Mon, 2011-12-12 at 15:32 -0500, Josef Bacik wrote:
>
> That worked perfectly. So will I have this problem when I got to turn these
> things into tracepoints or will those work out right? Thanks,
The TP_fast_assign() is exactly how things are copied into the ring
buffer. If you have all the necessary data copied then, and don't
dereference it in TP_printk(), then you are fine.
IOW,
TP_fast_assign( entry->id = ptr->id),
TP_printk ("id: %lx", entry->id)
will work, but
TP_fast_assign(entry->ptr = ptr),
TP_printk("id: %lx", entry->ptr->id)
will not.
-- Steve
prev parent reply other threads:[~2011-12-12 20:45 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-12-12 18:59 Josef Bacik
2011-12-12 19:57 ` Steven Rostedt
2011-12-12 20:32 ` Josef Bacik
2011-12-12 20:44 ` Steven Rostedt [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=1323722699.1377.9.camel@gandalf.stny.rr.com \
--to=rostedt@goodmis.org \
--cc=fweisbec@gmail.com \
--cc=josef@redhat.com \
--cc=linux-kernel@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®