loader/arm/mmu: Set first available va to KERNEL_LOAD_BASE
* The existing code set the first available pa and va to the end of the page dirctory. * The arm mmu code was attempting to identity map (va==pa) the memory, but also wanted memory to be in kernel space. This allocation method isn't possible on all boards (including the pi) * We're adjusting the dynamic ram to KERNEL_LOAD_BASE plus the max size of the kernel. (which is what most other platforms are doing)
This commit is contained in:
@@ -700,8 +700,8 @@ mmu_init(void)
|
|||||||
sPageTableRegionEnd = (addr_t)sPageDirectory + 0x200000;
|
sPageTableRegionEnd = (addr_t)sPageDirectory + 0x200000;
|
||||||
|
|
||||||
// Mark start for dynamic allocation
|
// Mark start for dynamic allocation
|
||||||
sNextPhysicalAddress =
|
sNextPhysicalAddress = sPageTableRegionEnd;
|
||||||
sNextVirtualAddress = sPageTableRegionEnd;
|
sNextVirtualAddress = KERNEL_LOAD_BASE + kMaxKernelSize;
|
||||||
|
|
||||||
// mark allocated ranges, so they don't get overwritten
|
// mark allocated ranges, so they don't get overwritten
|
||||||
insert_physical_allocated_range((addr_t)&_start, (addr_t)&_end - (addr_t)&_start);
|
insert_physical_allocated_range((addr_t)&_start, (addr_t)&_end - (addr_t)&_start);
|
||||||
|
|||||||
Reference in New Issue
Block a user