- Add the code necessary in the C version of KeLowerIRql to properly mask the PIC, and enable #ifed code in ASM KeRaiseIrql to mask the PIC, since it now works.

svn path=/trunk/; revision=23654
This commit is contained in:
Alex Ionescu
2006-08-22 22:45:45 +00:00
parent fcdd76f501
commit 132b7c834f
2 changed files with 10 additions and 2 deletions
-2
View File
@@ -464,14 +464,12 @@ _@KfRaiseIrql@4:
/* Set the new IRQL */
mov [fs:KPCR_IRQL], cl
#if 0
/* Mask the interrupts in the PIC */
mov eax, _KiI8259MaskTable[ecx*4]
or eax, [fs:KPCR_IDR]
out 0x21, al
shr eax, 8
out 0xA1, al
#endif
/* Restore interrupts and return old IRQL */
popf
+10
View File
@@ -51,6 +51,15 @@ VOID HalpEndSystemInterrupt(KIRQL Irql)
VOID STATIC
HalpLowerIrql(KIRQL NewIrql)
{
ULONG Mask;
if (KeGetPcr()->Irql > DISPATCH_LEVEL)
{
Mask = KeGetPcr()->IDR | KiI8259MaskTable[NewIrql];
WRITE_PORT_UCHAR((PUCHAR)0x21, (UCHAR)Mask);
Mask >>= 8;
WRITE_PORT_UCHAR((PUCHAR)0xa1, (UCHAR)Mask);
}
if (NewIrql >= PROFILE_LEVEL)
{
KeGetPcr()->Irql = NewIrql;
@@ -112,6 +121,7 @@ KfLowerIrql (KIRQL NewIrql)
HalpLowerIrql(NewIrql);
}
VOID STDCALL HalEndSystemInterrupt (KIRQL Irql, ULONG Unknown2)
/*
* FUNCTION: Finish a system interrupt and restore the specified irq level.