Date: Wed, 07 Oct 1998 15:54:16 +0200 From: Stefan Eggers <seggers@semyam.dinoco.de> To: Mike Smith <mike@smith.net.au> Cc: freebsd-current@FreeBSD.ORG, seggers@semyam.dinoco.de Subject: Re: Boot loader's autoload bug fix (was: Re: Two /boot/loader anomalies ) Message-ID: <199810071354.PAA00618@semyam.dinoco.de> In-Reply-To: Your message of "Tue, 06 Oct 1998 18:32:46 PDT." <199810070132.SAA02472@dingo.cdrom.com>
next in thread | previous in thread | raw e-mail | index | archive | help
> Bleagh. Maybe I should clear the keyboard buffer first? Nothing of this kind necessary at all! I found the problem with this and have it working now. A mere oversight in the VM86 usage. It was just the mistake of not setting V86_FLAGS in the control entry of the VM86 interrupt and thus it didn't pass flags back and what we don't get we hardly can check with a reliable result. I didn't notice this when testing because I never bothered with the VM86 mechanism in BTX (and even in general) before and your suggested fix didn't include it. This is *the* fix I hope: Index: i386/libi386/vidconsole.c =================================================================== RCS file: /usr2/FreeBSD/CVSROOT/src/sys/boot/i386/libi386/vidconsole.c,v retrieving revision 1.3 diff -u -r1.3 vidconsole.c --- vidconsole.c 1998/10/02 16:32:45 1.3 +++ vidconsole.c 1998/10/07 13:49:07 @@ -32,6 +32,7 @@ #include <stand.h> #include <bootstrap.h> #include <btxv86.h> +#include <machine/psl.h> #include "libi386.h" #if KEYBOARD_PROBE @@ -106,11 +107,11 @@ static int vidc_ischar(void) { - v86.ctl = 0; + v86.ctl = V86_FLAGS; v86.addr = 0x16; v86.eax = 0x100; v86int(); - return(v86.eax); + return((v86.efl & PSL_Z) == 0); } #if KEYBOARD_PROBE Stefan. -- Stefan Eggers Lu4 yao2 zhi1 ma3 li4, Max-Slevogt-Str. 1 ri4 jiu3 jian4 ren2 xin1. 51109 Koeln Federal Republic of Germany To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199810071354.PAA00618>