From: Arnd Bergmann <arnd@arndb•de>
To: Nathan Lynch <ntl@pobox•com>
Cc: linuxppc-dev@ozlabs•org
Subject: [PATCH] powerpc: fix support for latencytop
Date: Thu, 17 Jul 2008 00:12:25 +0200 [thread overview]
Message-ID: <200807170012.25859.arnd@arndb.de> (raw)
In-Reply-To: <20080716202236.GZ9594@localdomain>
We need to pass the kernel stack pointer instead of the user space
stack pointer in save_stack_trace_tsk().
Signed-off-by: Arnd Bergmann <arnd@arndb•de>
On Wednesday 16 July 2008, Nathan Lynch wrote:
> Arnd Bergmann wrote:
> > Implement save_stack_trace_tsk on powerpc, so that we can run with
> > latencytop.
>
> So I tried latencytop with linux-next and got the following oops, but
> I didn't really look into it yet.
Oh, I didn't even realize that benh had merged that patch of mine.
As I wrote in the description, it was entirely untested. You found
another obvious bug: The code was passing the user space stack
pointer instead of the kernel stack pointer.
Again, this patch is entirely untested, and I would not be at all
surprised to find other trivial bugs.
--- a/arch/powerpc/kernel/stacktrace.c
+++ b/arch/powerpc/kernel/stacktrace.c
@@ -59,6 +59,6 @@ EXPORT_SYMBOL_GPL(save_stack_trace);
void save_stack_trace_tsk(struct task_struct *tsk, struct stack_trace *trace)
{
- save_context_stack(trace, tsk->thread.regs->gpr[1], tsk, 0);
+ save_context_stack(trace, tsk->thread.ksp, tsk, 0);
}
EXPORT_SYMBOL_GPL(save_stack_trace_tsk);
next prev parent reply other threads:[~2008-07-16 22:12 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-07-10 0:05 latencytop support for powerpc? Chris Friesen
2008-07-10 13:57 ` Arnd Bergmann
2008-07-10 14:08 ` [PATCH] powerpc: support for latencytop Arnd Bergmann
2008-07-16 20:22 ` Nathan Lynch
2008-07-16 22:12 ` Arnd Bergmann [this message]
2008-07-16 22:28 ` [PATCH] powerpc: fix " Benjamin Herrenschmidt
2008-07-16 22:42 ` Nathan Lynch
2008-07-17 5:30 ` Chris Friesen
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=200807170012.25859.arnd@arndb.de \
--to=arnd@arndb$(echo .)de \
--cc=linuxppc-dev@ozlabs$(echo .)org \
--cc=ntl@pobox$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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