Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/alpha/alpha Remove the infamous "DANGER WILL ROBINS...



details:   https://anonhg.NetBSD.org/src/rev/b1e654a97e01
branches:  trunk
changeset: 514604:b1e654a97e01
user:      nathanw <nathanw%NetBSD.org@localhost>
date:      Thu Sep 06 21:20:43 2001 +0000

description:
Remove the infamous "DANGER WILL ROBINSON: FEN SET in cpu_fork!"
diagnostic. It's not indicative of an error condition.

The code sequence in question calls fpusave_proc(), which ultimately
calls alpha_pal_wrfen(0), which clears the FEN bit in the current
PCB. However, the diagnostic message is based on reading that bit from
the PCB representation in memory, which is not guaranteed to be kept
up-to-date with respect to the real PCB contents. According to the
AARM, third edition, II-B 4.2:

"If the PCB is read while ownership resides with the processor, it is
UNPREDICTABLE whether the original or an updated value of a field is
read."

The Alpha architecture does not provide a way to read the true value
of the FEN bit of the current PCB, so the test is simply removed.

diffstat:

 sys/arch/alpha/alpha/vm_machdep.c |  6 ++----
 1 files changed, 2 insertions(+), 4 deletions(-)

diffs (27 lines):

diff -r 66850637a2cc -r b1e654a97e01 sys/arch/alpha/alpha/vm_machdep.c
--- a/sys/arch/alpha/alpha/vm_machdep.c Thu Sep 06 21:07:07 2001 +0000
+++ b/sys/arch/alpha/alpha/vm_machdep.c Thu Sep 06 21:20:43 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vm_machdep.c,v 1.73 2001/08/19 17:34:01 chs Exp $ */
+/* $NetBSD: vm_machdep.c,v 1.74 2001/09/06 21:20:43 nathanw Exp $ */
 
 /*
  * Copyright (c) 1994, 1995, 1996 Carnegie-Mellon University.
@@ -29,7 +29,7 @@
 
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.73 2001/08/19 17:34:01 chs Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.74 2001/09/06 21:20:43 nathanw Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -181,8 +181,6 @@
         */
        if (p1 != curproc && p1 != &proc0)
                panic("cpu_fork: curproc");
-       if ((up->u_pcb.pcb_hw.apcb_flags & ALPHA_PCB_FLAGS_FEN) != 0)
-               printf("DANGER WILL ROBINSON: FEN SET IN cpu_fork!\n");
 #endif
 
        /*



Home | Main Index | Thread Index | Old Index