summaryrefslogtreecommitdiff
path: root/sys/arch
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2007-11-15 21:24:15 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2007-11-15 21:24:15 +0000
commitfbd8ea8c9ce67a08fe73a578538fdb7f7467c80e (patch)
tree5e82eabb38d6912e418c22944679917b9381e7c8 /sys/arch
parent8ca8bc22d3b776d69bd7ce8622136de5cb8ee376 (diff)
Resolve the struct trapframe tf_mode/tf_flags duality by getting rid of
the tf_mode name. This field only contains flags used internally by the exception processing code.
Diffstat (limited to 'sys/arch')
-rw-r--r--sys/arch/m88k/include/frame.h4
-rw-r--r--sys/arch/m88k/m88k/eh_common.S12
-rw-r--r--sys/arch/m88k/m88k/genassym.cf6
-rw-r--r--sys/arch/m88k/m88k/m88k_machdep.c10
4 files changed, 14 insertions, 18 deletions
diff --git a/sys/arch/m88k/include/frame.h b/sys/arch/m88k/include/frame.h
index d935b052180..cf11fb2cd1d 100644
--- a/sys/arch/m88k/include/frame.h
+++ b/sys/arch/m88k/include/frame.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: frame.h,v 1.3 2007/01/13 22:00:56 miod Exp $ */
+/* $OpenBSD: frame.h,v 1.4 2007/11/15 21:24:12 miod Exp $ */
/*
* Copyright (c) 1996 Nivas Madhur
* Mach Operating System
@@ -40,7 +40,7 @@ struct trapframe {
struct reg tf_regs;
register_t tf_vector; /* exception vector number */
register_t tf_mask; /* interrupt mask level */
- register_t tf_mode; /* interrupt mode */
+ register_t tf_flags; /* exception handling flags */
register_t tf_scratch1; /* reserved for use by locore */
register_t tf_ipfsr; /* P BUS status */
register_t tf_dpfsr; /* P BUS status */
diff --git a/sys/arch/m88k/m88k/eh_common.S b/sys/arch/m88k/m88k/eh_common.S
index 98897a9c358..c8a85f93077 100644
--- a/sys/arch/m88k/m88k/eh_common.S
+++ b/sys/arch/m88k/m88k/eh_common.S
@@ -1,4 +1,4 @@
-/* $OpenBSD: eh_common.S,v 1.29 2007/11/15 21:23:16 miod Exp $ */
+/* $OpenBSD: eh_common.S,v 1.30 2007/11/15 21:24:14 miod Exp $ */
/*
* Mach Operating System
* Copyright (c) 1993-1991 Carnegie Mellon University
@@ -264,12 +264,8 @@
* has been restarted. This does not necessarly conflict with
* the general registers (though it can if you're not careful)
* and so we can use a spot later used to save a general register.
- *
- * EF_FLAGS
- * This is just the old EF_MODE. "EF_MODE" isn't a very good name.
*/
#define EF_SR3 (EF_R0 + 5)
-#define EF_FLAGS EF_MODE
text
align 8
@@ -646,7 +642,7 @@ GLOBAL(reset_handler)
ldcr r10, SNIP
st r10, r31, REG_OFF(EF_SNIP)
ldcr r10, SR1
- st r10, r31, REG_OFF(EF_MODE)
+ st r10, r31, REG_OFF(EF_FLAGS)
ldcr r10, SFIP
st r10, r31, REG_OFF(EF_SFIP)
ldcr r10, SSBR
@@ -1828,7 +1824,7 @@ GLOBAL(m88110_reset_handler)
st r10, r31, REG_OFF(EF_IPAR)
ldcr r10, SR1
br.n 2f
- st r10, r31, REG_OFF(EF_MODE)
+ st r10, r31, REG_OFF(EF_FLAGS)
1:
/* retrieve saved shadow registers for error_handler */
@@ -1861,7 +1857,7 @@ GLOBAL(m88110_reset_handler)
ld r10, r30, REG_OFF(EF_DUAP)
st r10, r31, REG_OFF(EF_DUAP)
ldcr r10, SR1
- st r10, r31, REG_OFF(EF_MODE)
+ st r10, r31, REG_OFF(EF_FLAGS)
2:
/* shove sr2 into EF_FPLS1 */
ldcr r10, SR2
diff --git a/sys/arch/m88k/m88k/genassym.cf b/sys/arch/m88k/m88k/genassym.cf
index 054e1787493..4b915cf0607 100644
--- a/sys/arch/m88k/m88k/genassym.cf
+++ b/sys/arch/m88k/m88k/genassym.cf
@@ -1,4 +1,4 @@
-# $OpenBSD: genassym.cf,v 1.12 2007/11/15 21:23:16 miod Exp $
+# $OpenBSD: genassym.cf,v 1.13 2007/11/15 21:24:14 miod Exp $
#
# Copyright (c) 1982, 1990 The Regents of the University of California.
# All rights reserved.
@@ -28,7 +28,7 @@
# SUCH DAMAGE.
#
# @(#)genassym.c 7.8 (Berkeley) 5/7/91
-# $Id: genassym.cf,v 1.12 2007/11/15 21:23:16 miod Exp $
+# $Id: genassym.cf,v 1.13 2007/11/15 21:24:14 miod Exp $
#
include <sys/param.h>
@@ -110,7 +110,7 @@ define EF_FPRL offsetof(struct trapframe, tf_fprl) / sizeof(int)
define EF_FPIT offsetof(struct trapframe, tf_fpit) / sizeof(int)
define EF_VECTOR offsetof(struct trapframe, tf_vector) / sizeof(int)
define EF_MASK offsetof(struct trapframe, tf_mask) / sizeof(int)
-define EF_MODE offsetof(struct trapframe, tf_mode) / sizeof(int)
+define EF_FLAGS offsetof(struct trapframe, tf_flags) / sizeof(int)
define EF_RET offsetof(struct trapframe, tf_scratch1) / sizeof(int)
define EF_IPFSR offsetof(struct trapframe, tf_ipfsr) / sizeof(int)
define EF_DPFSR offsetof(struct trapframe, tf_dpfsr) / sizeof(int)
diff --git a/sys/arch/m88k/m88k/m88k_machdep.c b/sys/arch/m88k/m88k/m88k_machdep.c
index 70fbdff129f..481fbbe8ce1 100644
--- a/sys/arch/m88k/m88k/m88k_machdep.c
+++ b/sys/arch/m88k/m88k/m88k_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: m88k_machdep.c,v 1.29 2007/11/14 23:12:46 miod Exp $ */
+/* $OpenBSD: m88k_machdep.c,v 1.30 2007/11/15 21:24:14 miod Exp $ */
/*
* Copyright (c) 1998, 1999, 2000, 2001 Steve Murphree, Jr.
* Copyright (c) 1996 Nivas Madhur
@@ -247,8 +247,8 @@ regdump(struct trapframe *f)
f->tf_fphs2, f->tf_fpls2);
printf("fppt %x fprh %x fprl %x fpit %x\n",
f->tf_fppt, f->tf_fprh, f->tf_fprl, f->tf_fpit);
- printf("vector %d mask %x mode %x scratch1 %x cpu %p\n",
- f->tf_vector, f->tf_mask, f->tf_mode,
+ printf("vector %d mask %x flags %x scratch1 %x cpu %p\n",
+ f->tf_vector, f->tf_mask, f->tf_flags,
f->tf_scratch1, f->tf_cpu);
}
#endif
@@ -260,8 +260,8 @@ regdump(struct trapframe *f)
f->tf_dsap, f->tf_duap, f->tf_dsr, f->tf_dlar, f->tf_dpar);
printf("isap %x iuap %x isr %x ilar %x ipar %x\n",
f->tf_isap, f->tf_iuap, f->tf_isr, f->tf_ilar, f->tf_ipar);
- printf("vector %d mask %x mode %x scratch1 %x cpu %p\n",
- f->tf_vector, f->tf_mask, f->tf_mode,
+ printf("vector %d mask %x flags %x scratch1 %x cpu %p\n",
+ f->tf_vector, f->tf_mask, f->tf_flags,
f->tf_scratch1, f->tf_cpu);
}
#endif