From: Brian Hall <brianw.hall@compaq.com>
To: axp-list@redhat.com
Subject: Retrieving PC from (traversing) the stack on Alpha
Date: Sun, 19 Dec 1999 09:41:06 -0700 (MST) [thread overview]
Message-ID: <XFMail.19991219094106.brianw.hall@compaq.com> (raw)
In-Reply-To: <Pine.SGI.3.94.991213130230.334794A-100000@awesome.engr.sgi.com>
Okay, after some research, I think I figured out how to get at the needed
Alpha registers:
register unsigned long fptr __asm__("$15"); /* get frame pointer? */
register unsigned long sptr __asm__("$30"); /* get stack pointer? */
Now, my understanding of the problem is that I need to go back two frames on
the stack to get the PC of interest, and three for the RA of interest. How do I
do this? I haven't had much luck yet trying to figure out how to navigate the
kernel stack. I see the pt_regs structure, but I'm not exactly sure how to
figure the frame size, since that can vary with each frame.
On 13-Dec-1999 Matt Robinson wrote:
> The problem is from panic(), you don't have the registers, so you
> need to grab them. That way the 'lcrash' code has a point to start
> with as far as the failing process is concerned. Hence the "if (regs)"
> stuff.
--
Brian Hall <brianw.hall@compaq.com>
Linux Consultant
next parent reply other threads:[~1999-12-17 16:42 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <Pine.SGI.3.94.991213130230.334794A-100000@awesome.engr.sgi.com>
1999-12-19 16:41 ` Brian Hall [this message]
1999-12-17 17:51 ` Retrieving PC from (traversing) the stack on Alpha Joseph A. Martin
[not found] <XFMail.19991218145151.brianw.hall@compaq.com>
1999-12-23 19:55 ` Brian Hall
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox