mirror of
https://github.com/reactos/reactos.git
synced 2024-11-24 12:03:31 +08:00
[NTOS:KE] KiTrap0EHandler(): Use MI_IS_WRITE_ACCESS()
This commit is contained in:
parent
0129de218b
commit
94b8095ba2
@ -1321,7 +1321,6 @@ FASTCALL
|
|||||||
KiTrap0EHandler(IN PKTRAP_FRAME TrapFrame)
|
KiTrap0EHandler(IN PKTRAP_FRAME TrapFrame)
|
||||||
{
|
{
|
||||||
PKTHREAD Thread;
|
PKTHREAD Thread;
|
||||||
BOOLEAN StoreInstruction;
|
|
||||||
ULONG_PTR Cr2;
|
ULONG_PTR Cr2;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
@ -1347,9 +1346,6 @@ KiTrap0EHandler(IN PKTRAP_FRAME TrapFrame)
|
|||||||
/* Enable interrupts */
|
/* Enable interrupts */
|
||||||
_enable();
|
_enable();
|
||||||
|
|
||||||
/* Interpret the error code */
|
|
||||||
StoreInstruction = (TrapFrame->ErrCode & 2) != 0;
|
|
||||||
|
|
||||||
/* Check if we came in with interrupts disabled */
|
/* Check if we came in with interrupts disabled */
|
||||||
if (!(TrapFrame->EFlags & EFLAGS_INTERRUPT_MASK))
|
if (!(TrapFrame->EFlags & EFLAGS_INTERRUPT_MASK))
|
||||||
{
|
{
|
||||||
@ -1412,7 +1408,7 @@ KiTrap0EHandler(IN PKTRAP_FRAME TrapFrame)
|
|||||||
/* This status code is repurposed so we can recognize it later */
|
/* This status code is repurposed so we can recognize it later */
|
||||||
KiDispatchException2Args(KI_EXCEPTION_ACCESS_VIOLATION,
|
KiDispatchException2Args(KI_EXCEPTION_ACCESS_VIOLATION,
|
||||||
TrapFrame->Eip,
|
TrapFrame->Eip,
|
||||||
StoreInstruction,
|
MI_IS_WRITE_ACCESS(TrapFrame->ErrCode),
|
||||||
Cr2,
|
Cr2,
|
||||||
TrapFrame);
|
TrapFrame);
|
||||||
}
|
}
|
||||||
@ -1422,7 +1418,7 @@ KiTrap0EHandler(IN PKTRAP_FRAME TrapFrame)
|
|||||||
/* These faults only have two parameters */
|
/* These faults only have two parameters */
|
||||||
KiDispatchException2Args(Status,
|
KiDispatchException2Args(Status,
|
||||||
TrapFrame->Eip,
|
TrapFrame->Eip,
|
||||||
StoreInstruction,
|
MI_IS_WRITE_ACCESS(TrapFrame->ErrCode),
|
||||||
Cr2,
|
Cr2,
|
||||||
TrapFrame);
|
TrapFrame);
|
||||||
}
|
}
|
||||||
@ -1432,7 +1428,7 @@ KiTrap0EHandler(IN PKTRAP_FRAME TrapFrame)
|
|||||||
0,
|
0,
|
||||||
TrapFrame->Eip,
|
TrapFrame->Eip,
|
||||||
3,
|
3,
|
||||||
StoreInstruction,
|
MI_IS_WRITE_ACCESS(TrapFrame->ErrCode),
|
||||||
Cr2,
|
Cr2,
|
||||||
Status,
|
Status,
|
||||||
TrapFrame);
|
TrapFrame);
|
||||||
|
Loading…
Reference in New Issue
Block a user