Pending timer interrupts no longer deadlock DOSVM_Wait.

Restored interrupt priorities to correct values.
This commit is contained in:
Jukka Heinonen 2003-06-06 18:09:14 +00:00 committed by Alexandre Julliard
parent 068fa5d471
commit 7731c8e33e
2 changed files with 8 additions and 6 deletions

View File

@ -75,8 +75,8 @@ typedef void (*DOSRELAY)(CONTEXT86*,void*);
typedef void (WINAPI *RMCBPROC)(CONTEXT86*);
typedef void (WINAPI *INTPROC)(CONTEXT86*);
#define DOS_PRIORITY_REALTIME 1 /* IRQ0 - FIXME: should be 0 */
#define DOS_PRIORITY_KEYBOARD 0 /* IRQ1 - FIXME: should be 1 */
#define DOS_PRIORITY_REALTIME 0 /* IRQ0 */
#define DOS_PRIORITY_KEYBOARD 1 /* IRQ1 */
#define DOS_PRIORITY_VGA 2 /* IRQ9 */
#define DOS_PRIORITY_MOUSE 5 /* IRQ12 */
#define DOS_PRIORITY_SERIAL 10 /* IRQ4 */

View File

@ -272,16 +272,18 @@ void WINAPI DOSVM_Wait( CONTEXT86 *waitctx )
{
/*
* FIXME: This does not work in protected mode DOS programs.
* FIXME: If we have pending IRQ which has 16-bit handler,
* DOSVM_SendQueuedEvents may stuck in which case application
* deadlocks. This is why keyboard events must have top
* priority (default timer IRQ handler is 16-bit code).
* FIXME: Critical section locking is broken.
*/
CONTEXT86 context = *waitctx;
IF_SET(&context);
SET_PEND(&context);
context.SegCs = 0;
context.Eip = 0;
DOSVM_SendQueuedEvents(&context);
if(context.SegCs || context.Eip)
DPMI_CallRMProc( &context, NULL, 0, TRUE );
}
else
{