patch-2.3.48 linux/arch/mips/kernel/r2300_fpu.S

Next file: linux/arch/mips/kernel/r2300_misc.S
Previous file: linux/arch/mips/kernel/ptrace.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.47/linux/arch/mips/kernel/r2300_fpu.S linux/arch/mips/kernel/r2300_fpu.S
@@ -1,4 +1,5 @@
-/* $Id: r2300_fpu.S,v 1.5 1999/05/01 22:40:36 ralf Exp $
+/* $Id: r2300_fpu.S,v 1.7 1999/09/28 22:25:47 ralf Exp $
+ *
  * r2300_fpu.S: Save/restore floating point context for signal handlers.
  *
  * This file is subject to the terms and conditions of the GNU General Public
@@ -14,6 +15,7 @@
  * Copyright (c) 1998 Harald Koerfgen
  */
 #include <asm/asm.h>
+#include <asm/errno.h>
 #include <asm/fpregdef.h>
 #include <asm/mipsregs.h>
 #include <asm/offset.h>
@@ -28,8 +30,8 @@
 	.set	noreorder
 	.set	mips1
 	/* Save floating point context */
-LEAF(r2300_save_fp_context)
-
+LEAF(save_fp_context)
+	li	v0, 0					# assume success
 	cfc1	t1,fcr31
 	EX(swc1	$f0,(SC_FPREGS+0)(a0))
 	EX(swc1	$f1,(SC_FPREGS+8)(a0))
@@ -69,7 +71,7 @@
 	.set	nomacro
 	 EX(sw	t0,SC_FPC_EIR(a0))
 	.set	macro
-	END(r2300_save_fp_context)
+	END(save_fp_context)
 
 /*
  * Restore FPU state:
@@ -80,7 +82,8 @@
  * frame on the current content of c0_status, not on the content of the
  * stack frame which might have been changed by the user.
  */
-LEAF(r2300_restore_fp_context)
+LEAF(restore_fp_context)
+	li	v0, 0					# assume success
 	EX(lw t0,SC_FPC_CSR(a0))
 	EX(lwc1	$f0,(SC_FPREGS+0)(a0))
 	EX(lwc1	$f1,(SC_FPREGS+8)(a0))
@@ -116,4 +119,10 @@
 	EX(lwc1	$f31,(SC_FPREGS+248)(a0))
 	jr	ra
 	 ctc1	t0,fcr31
-	END(r2300_restore_fp_context)
+	END(restore_fp_context)
+
+	.type	fault@function
+	.ent	fault
+fault:	li	v0, -EFAULT
+	jr	ra
+	.end	fault

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)