Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/mips/mips On exception return, use k1 to restore th...



details:   https://anonhg.NetBSD.org/src/rev/a879fc9d206d
branches:  trunk
changeset: 482656:a879fc9d206d
user:      thorpej <thorpej%NetBSD.org@localhost>
date:      Fri Feb 18 18:36:41 2000 +0000

description:
On exception return, use k1 to restore the saved registers, so that we
don't stomp on the return address in k0.  Also, don't need to account
for any load delays, as the last register restored (gp) isn't used in
the subsequent instruction.

diffstat:

 sys/arch/mips/mips/locore_mips1.S |  27 +++++++++++++--------------
 1 files changed, 13 insertions(+), 14 deletions(-)

diffs (41 lines):

diff -r e5617b9232f3 -r a879fc9d206d sys/arch/mips/mips/locore_mips1.S
--- a/sys/arch/mips/mips/locore_mips1.S Fri Feb 18 10:18:12 2000 +0000
+++ b/sys/arch/mips/mips/locore_mips1.S Fri Feb 18 18:36:41 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: locore_mips1.S,v 1.19 2000/02/18 03:46:43 mycroft Exp $        */
+/*     $NetBSD: locore_mips1.S,v 1.20 2000/02/18 18:36:41 thorpej Exp $        */
 
 /*
  * Copyright (c) 1992, 1993
@@ -268,19 +268,18 @@
        lw      ra, TF_BASE+TF_REG_RA(sp)
        addu    sp, sp, KERNFRAME_SIZ
 #ifdef DDB
-       la      k0, _C_LABEL(kdbaux)
-       lw      s0, SF_REG_S0(k0)
-       lw      s1, SF_REG_S1(k0)
-       lw      s2, SF_REG_S2(k0)
-       lw      s3, SF_REG_S3(k0)
-       lw      s4, SF_REG_S4(k0)
-       lw      s5, SF_REG_S5(k0)
-       lw      s6, SF_REG_S6(k0)
-       lw      s7, SF_REG_S7(k0)
-       lw      sp, SF_REG_SP(k0)
-       lw      s8, SF_REG_S8(k0)
-       lw      gp, SF_REG_RA(k0)
-       nop                                     # R3000 load delay slot
+       la      k1, _C_LABEL(kdbaux)
+       lw      s0, SF_REG_S0(k1)
+       lw      s1, SF_REG_S1(k1)
+       lw      s2, SF_REG_S2(k1)
+       lw      s3, SF_REG_S3(k1)
+       lw      s4, SF_REG_S4(k1)
+       lw      s5, SF_REG_S5(k1)
+       lw      s6, SF_REG_S6(k1)
+       lw      s7, SF_REG_S7(k1)
+       lw      sp, SF_REG_SP(k1)
+       lw      s8, SF_REG_S8(k1)
+       lw      gp, SF_REG_RA(k1)
 #endif
        j       k0                              # return to interrupted point
        rfe



Home | Main Index | Thread Index | Old Index