mirror of
https://github.com/reactos/reactos.git
synced 2024-06-24 06:51:47 +00:00
[NTOS:MM] Let ARM3 handle invalid PDE for itself.
This commit is contained in:
parent
36a92e6ea5
commit
7bffb92099
|
@ -186,17 +186,6 @@ ProtectToPTE(ULONG flProtect)
|
|||
return(Attributes);
|
||||
}
|
||||
|
||||
NTSTATUS
|
||||
NTAPI
|
||||
MiDispatchFault(IN ULONG FaultCode,
|
||||
IN PVOID Address,
|
||||
IN PMMPTE PointerPte,
|
||||
IN PMMPTE PointerProtoPte,
|
||||
IN BOOLEAN Recursive,
|
||||
IN PEPROCESS Process,
|
||||
IN PVOID TrapInformation,
|
||||
IN PVOID Vad);
|
||||
|
||||
NTSTATUS
|
||||
NTAPI
|
||||
MiFillSystemPageDirectory(IN PVOID Base,
|
||||
|
@ -244,32 +233,17 @@ MmGetPageTableForProcess(PEPROCESS Process, PVOID Address, BOOLEAN Create, PKIRQ
|
|||
}
|
||||
return Pt + MiAddressToPteOffset(Address);
|
||||
}
|
||||
|
||||
/* This is for our process */
|
||||
PointerPde = MiAddressToPde(Address);
|
||||
Pt = (PULONG)MiAddressToPte(Address);
|
||||
if (PointerPde->u.Hard.Valid == 0)
|
||||
{
|
||||
NTSTATUS Status;
|
||||
if (Create == FALSE)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
ASSERT(PointerPde->u.Long == 0);
|
||||
|
||||
MI_WRITE_INVALID_PTE(PointerPde, DemandZeroPde);
|
||||
// Tiny HACK: Parameter 1 is the architecture specific FaultCode for an access violation (i.e. page is present)
|
||||
Status = MiDispatchFault(0x1,
|
||||
Pt,
|
||||
PointerPde,
|
||||
NULL,
|
||||
FALSE,
|
||||
PsGetCurrentProcess(),
|
||||
NULL,
|
||||
NULL);
|
||||
DBG_UNREFERENCED_LOCAL_VARIABLE(Status);
|
||||
ASSERT(KeAreAllApcsDisabled() == TRUE);
|
||||
ASSERT(PointerPde->u.Hard.Valid == 1);
|
||||
if ((PointerPde->u.Hard.Valid == 0) && (Create == FALSE))
|
||||
{
|
||||
/* Do not fault PDE in if not needed */
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return (PULONG)MiAddressToPte(Address);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue