I'm trying to test some basic signal handling on a ppc970, but I'm
running into some strange Segmentation Faults.

I'm trying to run the code in "Listing 7" from the following page at
ibm.

http://www.ibm.com/developerworks/li...w09SignalDebug

The code runs as advertised on any 32-bit ppc, such as my 7447A. But
attempting to run it on my ppc970 gives me Segmentation Faults when
the code tries to de-reference any under:

((&(sc->uc_mcontext))->regs)

I looked at asm/ptrace.h and asm/sigcontext.h (I'm running 2.6.21-7
and verified it's using powerpc64 definitions) and everything seems
ok, but

obiwan:~/Code/Signal# ./sih

sn 4,
si.si_signo = 4095
si.si_errno = -5999992
si.si_code = 4095 (Unknown SI Code)
sc->uc_flags: 0xffa46e90

Op-Code [nip - 5] = 0l at address = 0xfffffa46c9c
Op-Code [nip - 4] = 4095l at address = 0xfffffa46ca0
Op-Code [nip - 3] = 4288966400l at address = 0xfffffa46ca4
Op-Code [nip - 2] = 1024l at address = 0xfffffa46ca8
Op-Code [nip - 1] = 154864l at address = 0xfffffa46cac
Failed Op-code = 0 at address = 0xfffffa46cb0
Op-Code [nip + 1] = 0x0 at address = 0xfffffa46cb4
&sc->uc_mcontext = 0xfffffa46d98
((&(sc->uc_mcontext))->regs) = 0xfffffa44cf9

Is there something esoteric I'm missing?

Thanks,

Matt