mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-28 11:57:28 +00:00
Add support for a pmap direct map for 64-bit Book-E
As with AIM64, map the DMAP at the beginning of the fourth "quadrant" of memory, and move the KERNBASE to the the start of KVA. Eventually we may run the kernel out of the DMAP, but for now, continue booting as it has been.
This commit is contained in:
parent
271ce40239
commit
9f5b999aca
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=331900
@ -1724,7 +1724,11 @@ mmu_booke_bootstrap(mmu_t mmu, vm_offset_t start, vm_offset_t kernelend)
|
||||
debugf("mmu_booke_bootstrap: entered\n");
|
||||
|
||||
/* Set interesting system properties */
|
||||
#ifdef __powerpc64__
|
||||
hw_direct_map = 1;
|
||||
#else
|
||||
hw_direct_map = 0;
|
||||
#endif
|
||||
#if defined(COMPAT_FREEBSD32) || !defined(__powerpc64__)
|
||||
elf32_nxstack = 1;
|
||||
#endif
|
||||
@ -1971,6 +1975,15 @@ mmu_booke_bootstrap(mmu_t mmu, vm_offset_t start, vm_offset_t kernelend)
|
||||
debugf("physsz = 0x%09jx physmem = %jd (0x%09jx)\n",
|
||||
(uintmax_t)physsz, (uintmax_t)physmem, (uintmax_t)physmem);
|
||||
|
||||
#ifdef __powerpc64__
|
||||
/*
|
||||
* Map the physical memory contiguously in TLB1.
|
||||
* Round so it fits into a single mapping.
|
||||
*/
|
||||
tlb1_mapin_region(DMAP_BASE_ADDRESS, 0,
|
||||
phys_avail[i + 1]);
|
||||
#endif
|
||||
|
||||
/*******************************************************/
|
||||
/* Initialize (statically allocated) kernel pmap. */
|
||||
/*******************************************************/
|
||||
|
@ -106,13 +106,8 @@
|
||||
#define FREEBSD32_USRSTACK FREEBSD32_SHAREDPAGE
|
||||
|
||||
#ifdef __powerpc64__
|
||||
#ifdef AIM
|
||||
#define VM_MIN_KERNEL_ADDRESS 0xe000000000000000UL
|
||||
#define VM_MAX_KERNEL_ADDRESS 0xe0000001c7ffffffUL
|
||||
#else
|
||||
#define VM_MIN_KERNEL_ADDRESS 0xc000000000000000UL
|
||||
#define VM_MAX_KERNEL_ADDRESS 0xc0000001c7ffffffUL
|
||||
#endif
|
||||
#define VM_MAX_SAFE_KERNEL_ADDRESS VM_MAX_KERNEL_ADDRESS
|
||||
#endif
|
||||
|
||||
@ -135,9 +130,9 @@
|
||||
|
||||
#ifdef __powerpc64__
|
||||
#ifndef LOCORE
|
||||
#define KERNBASE 0xc000000000000100UL /* start of kernel virtual */
|
||||
#define KERNBASE 0xe000000000000100UL /* start of kernel virtual */
|
||||
#else
|
||||
#define KERNBASE 0xc000000000000100 /* start of kernel virtual */
|
||||
#define KERNBASE 0xe000000000000100 /* start of kernel virtual */
|
||||
#endif
|
||||
#else
|
||||
#define KERNBASE 0xc0000000 /* start of kernel virtual */
|
||||
|
Loading…
Reference in New Issue
Block a user