From owner-freebsd-current Mon Oct 26 15:20:21 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id PAA06079 for freebsd-current-outgoing; Mon, 26 Oct 1998 15:20:21 -0800 (PST) (envelope-from owner-freebsd-current@FreeBSD.ORG) Received: from ceia.nordier.com (m1-57-dbn.dial-up.net [196.34.155.57]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id PAA06058 for ; Mon, 26 Oct 1998 15:20:13 -0800 (PST) (envelope-from rnordier@nordier.com) Received: (from rnordier@localhost) by ceia.nordier.com (8.8.7/8.6.12) id BAA02936; Tue, 27 Oct 1998 01:16:39 +0200 (SAT) From: Robert Nordier Message-Id: <199810262316.BAA02936@ceia.nordier.com> Subject: Re: /boot/loader hangs after arrow/function key pressed at prompt In-Reply-To: <199810262154.XAA01438@ceia.nordier.com> from Robert Nordier at "Oct 26, 98 11:54:26 pm" To: freebsd-current@FreeBSD.ORG Date: Tue, 27 Oct 1998 01:16:14 +0200 (SAT) Cc: abial@nask.pl, rnordier@nordier.com, mike@smith.net.au, Jos.Backus@nl.origin-it.com X-Mailer: ELM [version 2.4ME+ PL31 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG I wrote: > Andrzej Bialecki wrote: > > On Mon, 26 Oct 1998, Robert Nordier wrote: > > > > > > I also encountered another problem: /boot/loader sometimes ignores > > > > all keypresses (I wasn't able even to break the countdown), but I'm not > > > > sure in what circumstances it happens - it sometimes happens, when I type > > > > something on the boot: prompt, then delete it. > > > > > > If this happened with the new boot1/boot2, can you confirm this is > > > still a problem? Your original report of this was some time ago, and > > > various changes have been made, including to the input routine. > > > > I just checked it with the newest sources - I built the binaries, and > > installed them, and rebooted... Well, after several times I kind of see a > > pattern. /boot/loader seems to choke when I press Enter _twice_ very > > quickly at the boot: prompt (but again, not always..). Seems to me that > > some junk left in some buffer confuses it... > > That's great, thanks. I've managed to get it happening fairly > reproducibly. FWIW, it needs Enter three times at the boot manager > prompt here. > > I think I may have found the problem: anyway, I found something. I'll > just have to work on my keyboard technique to test it. :-) There following patch makes a difference here, though I'm not sure this is necessarily the only problem. Index: vidconsole.c =================================================================== RCS file: /home/ncvs/src/sys/boot/i386/libi386/vidconsole.c,v retrieving revision 1.6 diff -u -r1.6 vidconsole.c --- vidconsole.c 1998/10/11 10:07:52 1.6 +++ vidconsole.c 1998/10/26 23:07:53 @@ -120,9 +120,7 @@ v86.addr = 0x16; v86.eax = 0x100; v86int(); - if (!(v86.efl & PSL_Z)) - return(v86.eax & 0xff); - return(0); + return(!(v86.efl & PSL_Z)); } #if KEYBOARD_PROBE The function vidc_ischar() was attempting to return the ASCII code of the key pressed, even though several PC keys don't have an ASCII representation. The corresponding serial function comc_ischar() is less ambitious, so the patch reduces the behavior to the lower common denominator. -- Robert Nordier To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message