mirror of
https://github.com/reactos/reactos.git
synced 2024-12-27 09:34:43 +00:00
[NTOS:KE/X64] Fix KiInterruptDispatch
- Enable interrupts - Acquire the spinlock on SMP builds
This commit is contained in:
parent
29721ac552
commit
67231bd69a
1 changed files with 11 additions and 6 deletions
|
@ -23,8 +23,9 @@ EXTERN KiDpcInterruptHandler:PROC
|
||||||
EXTERN PsConvertToGuiThread:PROC
|
EXTERN PsConvertToGuiThread:PROC
|
||||||
EXTERN MmCreateKernelStack:PROC
|
EXTERN MmCreateKernelStack:PROC
|
||||||
EXTERN MmDeleteKernelStack:PROC
|
EXTERN MmDeleteKernelStack:PROC
|
||||||
|
|
||||||
EXTERN KdSetOwedBreakpoints:PROC
|
EXTERN KdSetOwedBreakpoints:PROC
|
||||||
|
EXTERN KeAcquireSpinLockAtDpcLevel:PROC
|
||||||
|
EXTERN KeReleaseSpinLockFromDpcLevel:PROC
|
||||||
|
|
||||||
|
|
||||||
/* Helper Macros *************************************************************/
|
/* Helper Macros *************************************************************/
|
||||||
|
@ -744,11 +745,13 @@ FUNC KiInterruptDispatch
|
||||||
movzx rax, byte ptr [rbx + KINTERRUPT_SynchronizeIrql]
|
movzx rax, byte ptr [rbx + KINTERRUPT_SynchronizeIrql]
|
||||||
mov cr8, rax
|
mov cr8, rax
|
||||||
|
|
||||||
|
/* Enable interrupts */
|
||||||
|
sti
|
||||||
|
|
||||||
#ifdef CONFIG_SMP
|
#ifdef CONFIG_SMP
|
||||||
/* Acquire interrupt lock */
|
/* Acquire interrupt lock */
|
||||||
mov r8, [rbx + KINTERRUPT_ActualLock]
|
mov rcx, [rbx + KINTERRUPT_ActualLock]
|
||||||
|
call KeAcquireSpinLockAtDpcLevel
|
||||||
//KxAcquireSpinLock(Interrupt->ActualLock);
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Call the ISR */
|
/* Call the ISR */
|
||||||
|
@ -758,10 +761,12 @@ FUNC KiInterruptDispatch
|
||||||
|
|
||||||
#ifdef CONFIG_SMP
|
#ifdef CONFIG_SMP
|
||||||
/* Release interrupt lock */
|
/* Release interrupt lock */
|
||||||
//KxReleaseSpinLock(Interrupt->ActualLock);
|
mov rcx, [rbx + KINTERRUPT_ActualLock]
|
||||||
|
call KeReleaseSpinLockFromDpcLevel
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Go back to old irql */
|
/* Disable interrupts and go back to old irql */
|
||||||
|
cli
|
||||||
movzx rax, byte ptr [rbp + KTRAP_FRAME_PreviousIrql]
|
movzx rax, byte ptr [rbp + KTRAP_FRAME_PreviousIrql]
|
||||||
mov cr8, rax
|
mov cr8, rax
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue