[NTVDM]: Implement a basic BIOS Wait interrupt INT 15h, AH=86h.
authorHermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
Sat, 25 Jan 2014 22:29:54 +0000 (22:29 +0000)
committerHermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
Sat, 25 Jan 2014 22:29:54 +0000 (22:29 +0000)
svn path=/branches/ntvdm/; revision=61821

subsystems/ntvdm/bios/bios.c

index cad2c6c..8eca3d8 100644 (file)
@@ -49,6 +49,22 @@ static VOID WINAPI BiosMiscService(LPWORD Stack)
 {
     switch (getAH())
     {
+        /* Wait */
+        case 0x86:
+        {
+            /*
+             * Interval in microseconds CX:DX
+             * See Ralf Brown: http://www.ctyme.com/intr/rb-1525.htm
+             * for more information.
+             */
+            Sleep(MAKELONG(getDX(), getCX()));
+
+            /* Clear CF */
+            Stack[STACK_FLAGS] &= ~EMULATOR_FLAG_CF;
+
+            break;
+        }
+
         /* Copy Extended Memory */
         case 0x87:
         {