summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/mips64/mips64/sendsig.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/sys/arch/mips64/mips64/sendsig.c b/sys/arch/mips64/mips64/sendsig.c
index bb904f60d5c..d8e6284fe70 100644
--- a/sys/arch/mips64/mips64/sendsig.c
+++ b/sys/arch/mips64/mips64/sendsig.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sendsig.c,v 1.5 2004/09/17 13:31:22 miod Exp $ */
+/* $OpenBSD: sendsig.c,v 1.6 2004/11/02 21:05:34 pefo Exp $ */
/*
* Copyright (c) 1990 The Regents of the University of California.
@@ -72,6 +72,8 @@
#include <machine/regnum.h>
+struct proc *machFPCurProcPtr; /* pointer to last proc to use FP */
+
/*
* WARNING: code in locore.s assumes the layout shown for sf_signum
* thru sf_handler so... don't screw with them!
@@ -263,6 +265,9 @@ sys_sigreturn(p, v, retval)
regs->pc = scp->sc_pc;
regs->mullo = scp->mullo;
regs->mulhi = scp->mulhi;
+ regs->sr &= ~SR_COP_1_BIT; /* Zap current FP state */
+ if (p == machFPCurProcPtr)
+ machFPCurProcPtr = NULL;
bcopy((caddr_t)&scp->sc_regs[1], (caddr_t)&regs->ast,
sizeof(scp->sc_regs) - sizeof(register_t));
if (scp->sc_fpused)