Source-Changes-HG archive

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

[src/netbsd-1-6]: src/sys/arch/sparc64/sparc64 Pull up revision 1.44 (request...



details:   https://anonhg.NetBSD.org/src/rev/1452cb89423b
branches:  netbsd-1-6
changeset: 529064:1452cb89423b
user:      lukem <lukem%NetBSD.org@localhost>
date:      Wed Sep 04 13:57:34 2002 +0000

description:
Pull up revision 1.44 (requested by chuq in ticket #760):
cpu_fork: clear PSTATE_PEF for a child process, reviewed by thorpej

diffstat:

 sys/arch/sparc64/sparc64/vm_machdep.c |  14 ++++----------
 1 files changed, 4 insertions(+), 10 deletions(-)

diffs (46 lines):

diff -r b63b9d417534 -r 1452cb89423b sys/arch/sparc64/sparc64/vm_machdep.c
--- a/sys/arch/sparc64/sparc64/vm_machdep.c     Wed Sep 04 13:56:14 2002 +0000
+++ b/sys/arch/sparc64/sparc64/vm_machdep.c     Wed Sep 04 13:57:34 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: vm_machdep.c,v 1.42 2002/05/14 02:34:15 eeh Exp $ */
+/*     $NetBSD: vm_machdep.c,v 1.42.4.1 2002/09/04 13:57:34 lukem Exp $ */
 
 /*
  * Copyright (c) 1996-2002 Eduardo Horvath.  All rights reserved.
@@ -69,11 +69,6 @@
 
 #include <sparc64/sparc64/cache.h>
 
-/* XXX These are in sbusvar.h, but including that would be problematical */
-struct sbus_softc *sbus0;
-void    sbus_enter __P((struct sbus_softc *, vaddr_t va, int64_t pa, int flags));
-void    sbus_remove __P((struct sbus_softc *, vaddr_t va, int len));
-
 /*
  * Move pages from one kernel virtual address to another.
  */
@@ -245,9 +240,6 @@
         * the FPU user, we must save the FPU state first.
         */
 
-#ifdef NOTDEF_DEBUG
-       printf("cpu_fork()\n");
-#endif
        if (p1 == curproc) {
                write_user_windows();
 
@@ -323,11 +315,13 @@
 
        npcb->pcb_pc = (long)proc_trampoline - 8;
        npcb->pcb_sp = (long)rp - STACK_OFFSET;
+
        /* Need to create a %tstate if we're forking from proc0 */
        if (p1 == &proc0)
                tf2->tf_tstate = (ASI_PRIMARY_NO_FAULT<<TSTATE_ASI_SHIFT) |
                        ((PSTATE_USER)<<TSTATE_PSTATE_SHIFT);
-
+       else
+               tf2->tf_tstate &= ~(PSTATE_PEF<<TSTATE_PSTATE_SHIFT);
 
 #ifdef NOTDEF_DEBUG
        printf("cpu_fork: Copying over trapframe: otf=%p ntf=%p sp=%p opcb=%p npcb=%p\n", 



Home | Main Index | Thread Index | Old Index