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 Take a whack at allowing sN, sp and gp to...
details: https://anonhg.NetBSD.org/src/rev/6d1be63b096e
branches: trunk
changeset: 482635:6d1be63b096e
user: mycroft <mycroft%NetBSD.org@localhost>
date: Fri Feb 18 00:02:43 2000 +0000
description:
Take a whack at allowing sN, sp and gp to be set from DDB, too.
diffstat:
sys/arch/mips/mips/db_interface.c | 13 ++++++++++++-
sys/arch/mips/mips/locore_mips3.S | 21 +++++++++++++++++----
2 files changed, 29 insertions(+), 5 deletions(-)
diffs (85 lines):
diff -r 9e338a7ac18a -r 6d1be63b096e sys/arch/mips/mips/db_interface.c
--- a/sys/arch/mips/mips/db_interface.c Thu Feb 17 23:52:23 2000 +0000
+++ b/sys/arch/mips/mips/db_interface.c Fri Feb 18 00:02:43 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: db_interface.c,v 1.24 2000/02/17 23:52:23 mycroft Exp $ */
+/* $NetBSD: db_interface.c,v 1.25 2000/02/18 00:02:43 mycroft Exp $ */
/*
* Mach Operating System
@@ -204,6 +204,17 @@
tfp[19] = f->f_regs[MULLO];
tfp[20] = f->f_regs[MULHI];
tfp[21] = f->f_regs[PC];
+ kdbaux[0] = f->f_regs[S0];
+ kdbaux[1] = f->f_regs[S1];
+ kdbaux[2] = f->f_regs[S2];
+ kdbaux[3] = f->f_regs[S3];
+ kdbaux[4] = f->f_regs[S4];
+ kdbaux[5] = f->f_regs[S5];
+ kdbaux[6] = f->f_regs[S6];
+ kdbaux[7] = f->f_regs[S7];
+ kdbaux[8] = f->f_regs[SP];
+ kdbaux[9] = f->f_regs[S8];
+ kdbaux[10] = f->f_regs[GP];
}
return (1);
diff -r 9e338a7ac18a -r 6d1be63b096e sys/arch/mips/mips/locore_mips3.S
--- a/sys/arch/mips/mips/locore_mips3.S Thu Feb 17 23:52:23 2000 +0000
+++ b/sys/arch/mips/mips/locore_mips3.S Fri Feb 18 00:02:43 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: locore_mips3.S,v 1.14 1999/12/22 05:54:18 tsubai Exp $ */
+/* $NetBSD: locore_mips3.S,v 1.15 2000/02/18 00:02:43 mycroft Exp $ */
/*
* Copyright (c) 1997 Jonathan Stone (hereinafter referred to as the author)
@@ -362,10 +362,8 @@
NESTED_NOPROFILE(mips3_KernGenException, KERNFRAME_SIZ, ra)
.set noat
.mask 0x80000000, -4
- subu sp, sp, KERNFRAME_SIZ
#ifdef DDB
la k0, _C_LABEL(kdbaux)
- addu k1, sp, KERNFRAME_SIZ # Avoid violating conventions
REG_S s0, SF_REG_S0(k0)
REG_S s1, SF_REG_S1(k0)
REG_S s2, SF_REG_S2(k0)
@@ -374,7 +372,7 @@
REG_S s5, SF_REG_S5(k0)
REG_S s6, SF_REG_S6(k0)
REG_S s7, SF_REG_S7(k0)
- REG_S k1, SF_REG_SP(k0)
+ REG_S sp, SF_REG_SP(k0)
REG_S s8, SF_REG_S8(k0)
REG_S gp, SF_REG_RA(k0)
#endif
@@ -383,6 +381,7 @@
* We don't need to save s0 - s8, sp and gp because
* the compiler does it for us.
*/
+ subu sp, sp, KERNFRAME_SIZ
REG_S AT, TF_BASE+TF_REG_AST(sp)
REG_S v0, TF_BASE+TF_REG_V0(sp)
REG_S v1, TF_BASE+TF_REG_V1(sp)
@@ -461,6 +460,20 @@
REG_L t9, TF_BASE+TF_REG_T9(sp)
REG_L ra, TF_BASE+TF_REG_RA(sp)
addu sp, sp, KERNFRAME_SIZ
+#ifdef DDB
+ la k0, _C_LABEL(kdbaux)
+ REG_L s0, SF_REG_S0(k0)
+ REG_L s1, SF_REG_S1(k0)
+ REG_L s2, SF_REG_S2(k0)
+ REG_L s3, SF_REG_S3(k0)
+ REG_L s4, SF_REG_S4(k0)
+ REG_L s5, SF_REG_S5(k0)
+ REG_L s6, SF_REG_S6(k0)
+ REG_L s7, SF_REG_S7(k0)
+ REG_L sp, SF_REG_SP(k0)
+ REG_L s8, SF_REG_S8(k0)
+ REG_L gp, SF_REG_RA(k0)
+#endif
eret # return to interrupted point
.set at
END(mips3_KernGenException)
Home |
Main Index |
Thread Index |
Old Index