diff options
author | alc <alc@FreeBSD.org> | 2004-04-16 03:45:28 +0000 |
---|---|---|
committer | alc <alc@FreeBSD.org> | 2004-04-16 03:45:28 +0000 |
commit | c4d18d39a4f98928920f201d8d4ed05f43bd33e7 (patch) | |
tree | bdee0d82996fa9cf4ac08f6eaaba73ccef014644 /sys/amd64 | |
parent | f928512a2b8ef04ebab4b8686531ca6373413171 (diff) | |
download | FreeBSD-src-c4d18d39a4f98928920f201d8d4ed05f43bd33e7.zip FreeBSD-src-c4d18d39a4f98928920f201d8d4ed05f43bd33e7.tar.gz |
Set the "global" attribute on the page table entries for the kernel and
direct mappings. This shaves a few seconds off of my buildworld times.
Discussed with: peter@
Diffstat (limited to 'sys/amd64')
-rw-r--r-- | sys/amd64/amd64/pmap.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/amd64/amd64/pmap.c b/sys/amd64/amd64/pmap.c index dd2cf7e..f918384 100644 --- a/sys/amd64/amd64/pmap.c +++ b/sys/amd64/amd64/pmap.c @@ -384,7 +384,7 @@ create_pagetables(void) /* XXX not fully used, underneath 2M pages */ for (i = 0; (i << PAGE_SHIFT) < avail_start; i++) { ((pt_entry_t *)KPTphys)[i] = i << PAGE_SHIFT; - ((pt_entry_t *)KPTphys)[i] |= PG_RW | PG_V; + ((pt_entry_t *)KPTphys)[i] |= PG_RW | PG_V | PG_G; } /* Now map the page tables at their location within PTmap */ @@ -397,7 +397,7 @@ create_pagetables(void) /* This replaces some of the KPTphys entries above */ for (i = 0; (i << PDRSHIFT) < avail_start; i++) { ((pd_entry_t *)KPDphys)[i] = i << PDRSHIFT; - ((pd_entry_t *)KPDphys)[i] |= PG_RW | PG_V | PG_PS; + ((pd_entry_t *)KPDphys)[i] |= PG_RW | PG_V | PG_PS | PG_G; } /* And connect up the PD to the PDP */ @@ -410,7 +410,7 @@ create_pagetables(void) /* Now set up the direct map space using 2MB pages */ for (i = 0; i < NPDEPG * ndmpdp; i++) { ((pd_entry_t *)DMPDphys)[i] = (vm_paddr_t)i << PDRSHIFT; - ((pd_entry_t *)DMPDphys)[i] |= PG_RW | PG_V | PG_PS; + ((pd_entry_t *)DMPDphys)[i] |= PG_RW | PG_V | PG_PS | PG_G; } /* And the direct map space's PDP */ |