summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2010-02-13 14:04:46 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2010-02-13 14:04:46 +0000
commite124446575d590a7ba2232d8ad8f2cbd1be155ca (patch)
tree02c08ef9f5d5419fc9d1885bd01d43ce39364d84
parent7fa4446c2d24f0600f5f7f084fee267111adee30 (diff)
Since we don't use the saved ipl in pcb anymore, remove it from the struct
layout.
-rw-r--r--sys/arch/mips64/include/pcb.h5
-rw-r--r--sys/arch/mips64/mips64/context.S7
-rw-r--r--sys/arch/mips64/mips64/interrupt.c3
-rw-r--r--sys/arch/mips64/mips64/vm_machdep.c8
4 files changed, 7 insertions, 16 deletions
diff --git a/sys/arch/mips64/include/pcb.h b/sys/arch/mips64/include/pcb.h
index e959c672ec6..18bc0dfbad7 100644
--- a/sys/arch/mips64/include/pcb.h
+++ b/sys/arch/mips64/include/pcb.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: pcb.h,v 1.3 2005/12/16 03:55:46 deraadt Exp $ */
+/* $OpenBSD: pcb.h,v 1.4 2010/02/13 14:04:45 miod Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@@ -48,10 +48,9 @@
struct pcb {
struct trap_frame pcb_regs; /* saved CPU and registers */
struct {
- register_t val[14];
+ register_t val[13];
} pcb_context; /* kernel context for resume */
int pcb_onfault; /* for copyin/copyout faults */
- int pcb_kernel;
void *pcb_segtab; /* copy of pmap pm_segtab */
};
diff --git a/sys/arch/mips64/mips64/context.S b/sys/arch/mips64/mips64/context.S
index 5cbd5dbb299..ae0e3ae7b11 100644
--- a/sys/arch/mips64/mips64/context.S
+++ b/sys/arch/mips64/mips64/context.S
@@ -1,4 +1,4 @@
-/* $OpenBSD: context.S,v 1.43 2010/01/28 21:24:08 miod Exp $ */
+/* $OpenBSD: context.S,v 1.44 2010/02/13 14:04:45 miod Exp $ */
/*
* Copyright (c) 2002-2003 Opsycon AB (www.opsycon.se / www.opsycon.com)
@@ -60,13 +60,10 @@ LEAF(savectx, 0)
REG_S s8, PCB_CONTEXT+9*REGSZ(a0)
REG_S ra, PCB_CONTEXT+10*REGSZ(a0)
REG_S v0, PCB_CONTEXT+11*REGSZ(a0)
- GET_CPU_INFO(t0, t1)
- lw t0, CI_IPL(t0)
#ifdef RM7000_ICR
cfc0 t1, COP_0_ICR
REG_S t1, PCB_CONTEXT+12*REGSZ(a0) # save status register
#endif
- REG_S t0, PCB_CONTEXT+13*REGSZ(a0)
j ra
move v0, zero
END(savectx)
@@ -101,7 +98,6 @@ NON_LEAF(cpu_switchto_asm, FRAMESZ(CF_SZ), ra)
beqz a0, 1f
mfc0 v0, COP_0_STATUS_REG
- lw t0, CI_IPL(t1)
REG_S s0, PCB_CONTEXT+0*REGSZ(t3) # do a 'savectx()'
REG_S s1, PCB_CONTEXT+1*REGSZ(t3)
REG_S s2, PCB_CONTEXT+2*REGSZ(t3)
@@ -117,7 +113,6 @@ NON_LEAF(cpu_switchto_asm, FRAMESZ(CF_SZ), ra)
cfc0 t1, COP_0_ICR
REG_S t1, PCB_CONTEXT+12*REGSZ(t3)
#endif
- REG_S t0, PCB_CONTEXT+13*REGSZ(t3)
1:
/*
diff --git a/sys/arch/mips64/mips64/interrupt.c b/sys/arch/mips64/mips64/interrupt.c
index 588fad00961..2c0030d7cf7 100644
--- a/sys/arch/mips64/mips64/interrupt.c
+++ b/sys/arch/mips64/mips64/interrupt.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: interrupt.c,v 1.57 2010/01/18 16:57:46 miod Exp $ */
+/* $OpenBSD: interrupt.c,v 1.58 2010/02/13 14:04:45 miod Exp $ */
/*
* Copyright (c) 2001-2004 Opsycon AB (www.opsycon.se / www.opsycon.com)
@@ -207,7 +207,6 @@ splinit()
/*
* Update proc0 pcb to contain proper values.
*/
- pcb->pcb_context.val[13] = IPL_NONE;
#ifdef RM7000_ICR
pcb->pcb_context.val[12] = (idle_mask << 8) & IC_INT_MASK;
#endif
diff --git a/sys/arch/mips64/mips64/vm_machdep.c b/sys/arch/mips64/mips64/vm_machdep.c
index 06ee454cb67..eedf19fc2e2 100644
--- a/sys/arch/mips64/mips64/vm_machdep.c
+++ b/sys/arch/mips64/mips64/vm_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: vm_machdep.c,v 1.22 2010/01/08 01:35:52 syuu Exp $ */
+/* $OpenBSD: vm_machdep.c,v 1.23 2010/02/13 14:04:45 miod Exp $ */
/*
* Copyright (c) 1988 University of Utah.
* Copyright (c) 1992, 1993
@@ -109,11 +109,9 @@ cpu_fork(p1, p2, stack, stacksize, func, arg)
/*
* Copy the process control block to the new proc and
* create a clean stack for exit through trampoline.
- * pcb_context has s0-s7, sp, s8, ra, sr, icr, ipl.
+ * pcb_context has s0-s7, sp, s8, ra, sr, icr.
*/
-
if (p1 != curproc) {
- pcb->pcb_context.val[13] = IPL_NONE;
#ifdef RM7000_ICR
pcb->pcb_context.val[12] = (idle_mask << 8) & IC_INT_MASK;
#endif
@@ -123,8 +121,8 @@ cpu_fork(p1, p2, stack, stacksize, func, arg)
pcb->pcb_context.val[10] = (register_t)proc_trampoline;
pcb->pcb_context.val[8] = (register_t)pcb +
USPACE - sizeof(struct trap_frame);
- pcb->pcb_context.val[0] = (register_t)func;
pcb->pcb_context.val[1] = (register_t)arg;
+ pcb->pcb_context.val[0] = (register_t)func;
}
/*