From: Russ Anderson <rja@sgi.com>
To: linux-ia64@vger.kernel.org
Subject: Re: [patch] fix per-CPU MCA mess and make UP kernels work again
Date: Sun, 06 Feb 2005 15:58:01 +0000 [thread overview]
Message-ID: <200502061558.j16Fw1qa20144733@clink.americas.sgi.com> (raw)
In-Reply-To: <16887.1203.470842.161249@napali.hpl.hp.com>
Tony Luck wrote:
>
> This patch helps some (all uses of ia64_mca_data in
> mca_asm.S need to deref the pointer to get at the
> actual space, instead of clobbering thigs in the
> percpu area).
That patch does not work on Altix (discontig & SMP).
The system wedges in the MCA code.
The patch (below) helps in that they system gets through the
MCA code and back to the error injection app, but then
the system dies.
I'm confused about how the offsets are now being computed.
Keith's explaination made sense. How does the current code
get the correct link time offsets?
Keith Owens wrote:
> Russ Anderson <rja@sgi.com> wrote:
> >OK, just to make sure I understand, it is not practical to have ar.k3
> >store a pointer to __per_cpu_start, due to the difficulty computing
> >the offset to per_cpu__cpu_info. So ar.k3 should point at the
> >the start of per_cpu__cpu_info (the cpuinfo_ia64 structure).
>
> Right. We can compute the offset from __per_cpu_start to
> per_cpu__cpu_info, but that offset can only be computed at link time.
> That rules out the use of asm-offsets, asm-offsets.h is built at
> compile time, not link time. The extra code required to compute the
> offset at link time and apply that offset to ar.k3 to get from
> __per_cpu_start to per_cpu__cpu_info is ugly and is not worth the
> effort.
>
> Put all the MCA related fields in struct cpuinfo_ia64, point ar.k3 at
> struct cpuinfo_ia64 and we can use compile time offsets for the fields
> that the MCA handler cares about. We just need to document that all
> MCA related fields must be in struct cpuinfo_ia64 or accessed via a
> pointer that is in struct cpuinfo_ia64.
-----------------------------------------------------
Index: linux/arch/ia64/kernel/mca_asm.S
=================================--- linux.orig/arch/ia64/kernel/mca_asm.S 2005-02-04 09:58:01.241029555 -0600
+++ linux/arch/ia64/kernel/mca_asm.S 2005-02-05 10:11:46.126571337 -0600
@@ -342,10 +342,10 @@
// restore the original stack frame here
GET_THIS_PADDR(r2, ia64_mca_data)
;;
- add r2 = IA64_MCA_CPU_STACKFRAME_OFFSET, r2
- ;;
ld8 r2 = [r2]
;;
+ add r2 = IA64_MCA_CPU_STACKFRAME_OFFSET, r2
+ ;;
movl r4=IA64_PSR_MC
;;
rse_return_context(r4,r3,r2) // switch from interrupt context for RSE
-----------------------------------------------------
--
Russ Anderson, OS RAS/Partitioning Project Lead
SGI - Silicon Graphics Inc rja@sgi.com
next prev parent reply other threads:[~2005-02-06 15:58 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-01-26 2:47 [patch] fix per-CPU MCA mess and make UP kernels work again David Mosberger
2005-01-26 16:25 ` Jesse Barnes
2005-01-26 17:13 ` Russ Anderson
2005-01-26 17:48 ` David Mosberger
2005-01-26 17:53 ` Jesse Barnes
2005-01-26 18:05 ` David Mosberger
2005-01-26 18:11 ` Jesse Barnes
2005-01-26 19:01 ` Russ Anderson
2005-01-26 19:23 ` Luck, Tony
2005-01-26 20:07 ` David Mosberger
2005-01-26 21:40 ` Russ Anderson
2005-01-26 21:50 ` David Mosberger
2005-01-26 22:13 ` Luck, Tony
2005-01-26 22:16 ` David Mosberger
2005-01-26 22:19 ` Jesse Barnes
2005-01-26 22:33 ` Luck, Tony
2005-01-27 0:40 ` David Mosberger
2005-01-27 0:55 ` Luck, Tony
2005-01-28 22:54 ` Russ Anderson
2005-02-02 1:04 ` Luck, Tony
2005-02-02 20:25 ` Russ Anderson
2005-02-03 22:48 ` Luck, Tony
2005-02-03 23:48 ` Russ Anderson
2005-02-04 2:09 ` Jack Steiner
2005-02-04 3:00 ` Keith Owens
2005-02-04 16:24 ` Jack Steiner
2005-02-04 16:34 ` Russ Anderson
2005-02-06 15:58 ` Russ Anderson [this message]
2005-02-07 22:58 ` Luck, Tony
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=200502061558.j16Fw1qa20144733@clink.americas.sgi.com \
--to=rja@sgi.com \
--cc=linux-ia64@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