Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/compat/linux/arch/powerpc Deal with changes in the trapf...
details: https://anonhg.NetBSD.org/src/rev/2445de079eeb
branches: trunk
changeset: 760978:2445de079eeb
user: matt <matt%NetBSD.org@localhost>
date: Tue Jan 18 01:13:03 2011 +0000
description:
Deal with changes in the trapframe.
diffstat:
sys/compat/linux/arch/powerpc/linux_machdep.c | 66 +++++++++++++-------------
1 files changed, 33 insertions(+), 33 deletions(-)
diffs (116 lines):
diff -r a2499bfb4c89 -r 2445de079eeb sys/compat/linux/arch/powerpc/linux_machdep.c
--- a/sys/compat/linux/arch/powerpc/linux_machdep.c Tue Jan 18 01:11:50 2011 +0000
+++ b/sys/compat/linux/arch/powerpc/linux_machdep.c Tue Jan 18 01:13:03 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: linux_machdep.c,v 1.43 2011/01/14 02:06:33 rmind Exp $ */
+/* $NetBSD: linux_machdep.c,v 1.44 2011/01/18 01:13:03 matt Exp $ */
/*-
* Copyright (c) 1995, 2000, 2001 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_machdep.c,v 1.43 2011/01/14 02:06:33 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_machdep.c,v 1.44 2011/01/18 01:13:03 matt Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -140,7 +140,7 @@
((char *)l->l_sigstk.ss_sp +
l->l_sigstk.ss_size);
} else {
- fp = tf->fixreg[1];
+ fp = tf->tf_fixreg[1];
}
#ifdef DEBUG_LINUX
printf("fp at start of linux_sendsig = %x\n", fp);
@@ -164,18 +164,18 @@
* Save register context.
*/
for (i = 0; i < 32; i++)
- linux_regs.lgpr[i] = tf->fixreg[i];
- linux_regs.lnip = tf->srr0;
- linux_regs.lmsr = tf->srr1 & PSL_USERSRR1;
- linux_regs.lorig_gpr3 = tf->fixreg[3]; /* XXX Is that right? */
- linux_regs.lctr = tf->ctr;
- linux_regs.llink = tf->lr;
- linux_regs.lxer = tf->xer;
- linux_regs.lccr = tf->cr;
+ linux_regs.lgpr[i] = tf->tf_fixreg[i];
+ linux_regs.lnip = tf->tf_srr0;
+ linux_regs.lmsr = tf->tf_srr1 & PSL_USERSRR1;
+ linux_regs.lorig_gpr3 = tf->tf_fixreg[3]; /* XXX Is that right? */
+ linux_regs.lctr = tf->tf_ctr;
+ linux_regs.llink = tf->tf_lr;
+ linux_regs.lxer = tf->tf_xer;
+ linux_regs.lccr = tf->tf_cr;
linux_regs.lmq = 0; /* Unused, 601 only */
- linux_regs.ltrap = tf->exc;
- linux_regs.ldar = tf->dar;
- linux_regs.ldsisr = tf->dsisr;
+ linux_regs.ltrap = tf->tf_exc;
+ linux_regs.ldar = tf->tf_dar;
+ linux_regs.ldsisr = tf->tf_dsisr;
linux_regs.lresult = 0;
memset(&frame, 0, sizeof(frame));
@@ -232,11 +232,11 @@
* Set the registers according to how the Linux process expects them.
* "Mind the gap" Linux expects a gap here.
*/
- tf->fixreg[1] = fp - LINUX__SIGNAL_FRAMESIZE;
- tf->lr = (int)catcher;
- tf->fixreg[3] = (int)native_to_linux_signo[sig];
- tf->fixreg[4] = fp;
- tf->srr0 = (int)p->p_sigctx.ps_sigcode;
+ tf->tf_fixreg[1] = fp - LINUX__SIGNAL_FRAMESIZE;
+ tf->tf_lr = (int)catcher;
+ tf->tf_fixreg[3] = (int)native_to_linux_signo[sig];
+ tf->tf_fixreg[4] = fp;
+ tf->tf_srr0 = (int)p->p_sigctx.ps_sigcode;
#ifdef DEBUG_LINUX
printf("fp at end of linux_sendsig = %x\n", fp);
@@ -308,13 +308,13 @@
return (EINVAL);
for (i = 0; i < 32; i++)
- tf->fixreg[i] = lregs->lgpr[i];
- tf->lr = lregs->llink;
- tf->cr = lregs->lccr;
- tf->xer = lregs->lxer;
- tf->ctr = lregs->lctr;
- tf->srr0 = lregs->lnip;
- tf->srr1 = lregs->lmsr;
+ tf->tf_fixreg[i] = lregs->lgpr[i];
+ tf->tf_lr = lregs->llink;
+ tf->tf_cr = lregs->lccr;
+ tf->tf_xer = lregs->lxer;
+ tf->tf_ctr = lregs->lctr;
+ tf->tf_srr0 = lregs->lnip;
+ tf->tf_srr1 = lregs->lmsr;
/*
* Make sure the fpu state is discarded
@@ -398,13 +398,13 @@
return (EINVAL);
for (i = 0; i < 32; i++)
- tf->fixreg[i] = lregs->lgpr[i];
- tf->lr = lregs->llink;
- tf->cr = lregs->lccr;
- tf->xer = lregs->lxer;
- tf->ctr = lregs->lctr;
- tf->srr0 = lregs->lnip;
- tf->srr1 = lregs->lmsr;
+ tf->tf_fixreg[i] = lregs->lgpr[i];
+ tf->tf_lr = lregs->llink;
+ tf->tf_cr = lregs->lccr;
+ tf->tf_xer = lregs->lxer;
+ tf->tf_ctr = lregs->lctr;
+ tf->tf_srr0 = lregs->lnip;
+ tf->tf_srr1 = lregs->lmsr;
/*
* Make sure the fpu state is discarded
Home |
Main Index |
Thread Index |
Old Index