From: Ingo Molnar <mingo@elte.hu>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: Abhishek Sagar <sagar.abhishek@gmail.com>,
Andrew Morton <akpm@linux-foundation.org>,
Linus Torvalds <torvalds@linux-foundation.org>,
Thomas Gleixner <tglx@linutronix.de>,
LKML <linux-kernel@vger.kernel.org>,
Al Viro <viro@zeniv.linux.org.uk>,
ananth@in.ibm.com, jkenisto@us.ibm.com, mhiramat@redhat.com
Subject: Re: [PATCH] ftrace: use kretprobe trampoline name to test in output
Date: Mon, 3 Nov 2008 10:41:59 +0100 [thread overview]
Message-ID: <20081103094159.GA10400@elte.hu> (raw)
In-Reply-To: <alpine.DEB.1.10.0810311541280.28774@gandalf.stny.rr.com>
* Steven Rostedt <rostedt@goodmis.org> wrote:
> [
> Ingo,
>
> Can you get this ready for 2.6.28. Without this fix, tracing
> breaks the ia64 build.
> ]
>
> When a function is kprobed, the return address is set to the
> kprobe_trampoline, or something similar. This caused the output
> of the trace to look confusing when the parent seemed to be this
> "kprobe_trampoline" function.
>
> To fix this, Abhishek Sagar added a test of the instruction pointer
> of the parent to see if it matched the kprobe_trampoline. If it
> did, the output would print a "[unknown/kretprobe'd]" instead.
>
> Unfortunately, not all archs do this the same way, and the trampoline
> function may not be exported, which causes failures in builds.
>
> This patch will compare the name instead of the pointer to see
> if it matches. This prevents us from depending on a function from
> being exported, and should work on all archs. The worst that can
> happen is that an arch might use a different name and then we
> go back to the confusing output. At least the arch will still build.
>
> Signed-off-by: Steven Rostedt <srostedt@redhat.com>
> Tested-by: Abhishek Sagar <sagar.abhishek@gmail.com>
> Acked-by: Abhishek Sagar <sagar.abhishek@gmail.com>
> ---
> kernel/trace/trace.c | 39 +++++++++++++++++++++------------------
> 1 file changed, 21 insertions(+), 18 deletions(-)
applied to tip/tracing/urgent, thanks!
Ingo
prev parent reply other threads:[~2008-11-03 9:42 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-27 18:33 [PATCH] ftrace: distinguish kretprobe'd functions in trace logs Abhishek Sagar
2008-05-27 18:48 ` Steven Rostedt
2008-06-02 10:41 ` Ingo Molnar
2008-10-31 2:30 ` Steven Rostedt
2008-10-31 14:36 ` Steven Rostedt
2008-10-31 15:32 ` Abhishek Sagar
2008-10-31 15:50 ` Steven Rostedt
2008-10-31 19:33 ` Abhishek Sagar
2008-10-31 19:44 ` [PATCH] ftrace: use kretprobe trampoline name to test in output Steven Rostedt
2008-11-03 9:41 ` Ingo Molnar [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=20081103094159.GA10400@elte.hu \
--to=mingo@elte.hu \
--cc=akpm@linux-foundation.org \
--cc=ananth@in.ibm.com \
--cc=jkenisto@us.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mhiramat@redhat.com \
--cc=rostedt@goodmis.org \
--cc=sagar.abhishek@gmail.com \
--cc=tglx@linutronix.de \
--cc=torvalds@linux-foundation.org \
--cc=viro@zeniv.linux.org.uk \
/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®