mirror of
https://github.com/reactos/reactos.git
synced 2025-04-20 12:29:56 +00:00
[NTOS]: We might get page faults before memory areas are setup, since so much ARM3 work now gets done before the memory areas are ready to go. Since obviously these faults cannot be caused by non-ARM3 Mm, we assume them to be ARM3 faults (as long as they happened in KSEG0_BASE). Fixes a bug where early page faults in ARM3 PTEs would get treated as non-ARM3 faults and fail.
svn path=/trunk/; revision=47161
This commit is contained in:
parent
f61cf60f1b
commit
c5e12bcf40
1 changed files with 12 additions and 4 deletions
|
@ -274,15 +274,23 @@ MmAccessFault(IN BOOLEAN StoreInstruction,
|
|||
#endif
|
||||
}
|
||||
|
||||
//
|
||||
// Check if this is an ARM3 memory area
|
||||
//
|
||||
/*
|
||||
* Check if this is an ARM3 memory area or if there's no memory area at all.
|
||||
* The latter can happen early in the boot cycle when ARM3 paged pool is in
|
||||
* use before having defined the memory areas proper.
|
||||
* A proper fix would be to define memory areas in the ARM3 code, but we want
|
||||
* to avoid adding this ReactOS-specific construct to ARM3 code.
|
||||
* Either way, in the future, as ReactOS-paged pool is eliminated, this hack
|
||||
* can go away.
|
||||
*/
|
||||
MemoryArea = MmLocateMemoryAreaByAddress(MmGetKernelAddressSpace(), Address);
|
||||
if ((MemoryArea) && (MemoryArea->Type == MEMORY_AREA_OWNED_BY_ARM3))
|
||||
if ((!(MemoryArea) && ((ULONG_PTR)Address >= (ULONG_PTR)MmSystemRangeStart)) ||
|
||||
((MemoryArea) && (MemoryArea->Type == MEMORY_AREA_OWNED_BY_ARM3)))
|
||||
{
|
||||
//
|
||||
// Hand it off to more competent hands...
|
||||
//
|
||||
DPRINT1("ARM3 fault\n");
|
||||
return MmArmAccessFault(StoreInstruction, Address, Mode, TrapInformation);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue