Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 10 Nov 1998 17:18:14 -0500 (EST)
From:      Andrew Gallatin <gallatin@cs.duke.edu>
To:        Mike Smith <mike@smith.net.au>
Cc:        Mike Haertel <mike@ducky.net>, freebsd-alpha@FreeBSD.ORG
Subject:   Re: another small observation 
Message-ID:  <13896.47289.309597.453451@grasshopper.cs.duke.edu>
In-Reply-To: <199811071958.LAA05807@dingo.cdrom.com>
References:  <199811071822.KAA00792@ducky.net> <199811071958.LAA05807@dingo.cdrom.com>

next in thread | previous in thread | raw e-mail | index | archive | help

Mike Smith writes:
 > > On x86's this concept of "halt" makes sense, since PC BIOSes
 > > typically do not have a halted state.  But on Alphas it's a
 > > real misfeature.  The SRM console is a lot more useful than
 > > a PC BIOS, in fact it's the nicest console I've seen, and it
 > > would be good to be able to get back to it.
 > 
 > This is a consequence of my unifying the "halt" and "reboot" behaviour -
 > the Alpha was doing it's own thing rather than the standard MI
 > behaviour.
 > 
 > It would be relatively trivial to move the "what to do when halting"
 > behaviour into the MD code; you're welcome to submit diffs, and I'd be 
 > happy to talk you through what would need to be done.

I'm bothered by this behaviour as well.  

All you need to do to get the old behaviour back is to call
cpu_halt().  Is the following patch acceptable?  I realize there are a
lot of #ifdefs..  

Index: sys/kern/kern_shutdown.c
===================================================================
RCS file: /scratch/freebsd-cvs/src/sys/kern/kern_shutdown.c,v
retrieving revision 1.41
diff -u -r1.41 kern_shutdown.c
--- kern_shutdown.c	1998/10/30 05:41:15	1.41
+++ kern_shutdown.c	1998/11/10 21:41:42
@@ -278,8 +278,19 @@
 	if (howto & RB_HALT) {
 		printf("\n");
 		printf("The operating system has halted.\n");
+#ifdef __alpha__
+		printf("Please press 's' to drop into the SRM console, "
+		       "or any other key to reboot\n\n");
+#endif
+#ifdef __i386__
 		printf("Please press any key to reboot.\n\n");
+#endif
 		switch (cngetc()) {
+#ifdef __alpha__
+	        case 's' :
+		case 'S' :	
+			printf("returning to the SRM console\n");
+#endif
 		case -1:		/* No console, just die */
 			cpu_halt();
 			/* NOTREACHED */



Cheers,

Drew

------------------------------------------------------------------------------
Andrew Gallatin, Sr Systems Programmer	http://www.cs.duke.edu/~gallatin
Duke University				Email: gallatin@cs.duke.edu
Department of Computer Science		Phone: (919) 660-6590


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-alpha" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?13896.47289.309597.453451>