* Applied patch by VinDuv/Jonas to use the existing check_for_key() that fixes

a problem on the Mac which obviously messed up its BIOS.
* This busy loops, but CPU utilization should be a maxed out in the boot loader
  anyway - we could add a pause, though.
* This closes bug #2654.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41117 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler 2011-03-26 20:01:37 +00:00
parent eeb259b94e
commit 2545ff58c1

View File

@ -1,5 +1,5 @@
/*
* Copyright 2004-2010, Axel Dörfler, axeld@pinc-software.de.
* Copyright 2004-2011, Axel Dörfler, axeld@pinc-software.de.
* Distributed under the terms of the MIT License.
*/
@ -43,12 +43,10 @@ clear_key_buffer(void)
extern "C" union key
wait_for_key(void)
{
bios_regs regs;
regs.eax = 0;
call_bios(0x16, &regs);
union key key;
key.ax = regs.eax & 0xffff;
do {
key.ax = check_for_key();
} while (key.ax == 0);
return key;
}