From ec566e808204f18dae17e20d8cc774ca24791c28 Mon Sep 17 00:00:00 2001 From: Stefan Ginsberg Date: Sun, 6 Sep 2015 22:29:10 +0000 Subject: [PATCH] - Fix the ASSERT in VdmSwapContext now that we are always setting up the trap frame correctly on debug build. - Fix the ASSERT in KeConnectInterrupt for debug single-processor builds (but keep the old one for multiprocessor build to make it less confusing if it is hit). svn path=/trunk/; revision=69075 --- reactos/ntoskrnl/ke/i386/irqobj.c | 12 ++++++++++-- reactos/ntoskrnl/vdm/vdmexec.c | 2 +- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/reactos/ntoskrnl/ke/i386/irqobj.c b/reactos/ntoskrnl/ke/i386/irqobj.c index 6a18fe1797f..ac05c748140 100644 --- a/reactos/ntoskrnl/ke/i386/irqobj.c +++ b/reactos/ntoskrnl/ke/i386/irqobj.c @@ -447,8 +447,16 @@ KeConnectInterrupt(IN PKINTERRUPT Interrupt) /* The vector is shared and the interrupts are compatible */ Interrupt->Connected = Connected = TRUE; - /* FIXME */ - // ASSERT(Irql <= SYNCH_LEVEL); + /* + * Verify the IRQL for chained connect, + */ +#if defined(CONFIG_SMP) + ASSERT(Irql <= SYNCH_LEVEL); +#elif (NTDDI_VERSION >= NTDDI_WS03) + ASSERT(Irql <= (IPI_LEVEL - 2)); +#else + ASSERT(Irql <= (IPI_LEVEL - 1)); +#endif /* Check if this is the first chain */ if (Dispatch.Type != ChainConnect) diff --git a/reactos/ntoskrnl/vdm/vdmexec.c b/reactos/ntoskrnl/vdm/vdmexec.c index d305b3d5f1d..cdcd31347c4 100644 --- a/reactos/ntoskrnl/vdm/vdmexec.c +++ b/reactos/ntoskrnl/vdm/vdmexec.c @@ -50,7 +50,7 @@ VdmSwapContext(IN PKTRAP_FRAME TrapFrame, /* Make sure that we're at APC_LEVEL and that this is a valid frame */ ASSERT(KeGetCurrentIrql() == APC_LEVEL); - //ASSERT(TrapFrame->DbgArgMark == 0xBADB0D00); + ASSERT(TrapFrame->DbgArgMark == 0xBADB0D00); /* Check if this is a V86 frame */ if (TrapFrame->EFlags & EFLAGS_V86_MASK)