svn commit: r241287 - head/sys/mips/mips
Alan Cox
alc at FreeBSD.org
Sat Oct 6 19:33:53 UTC 2012
Author: alc
Date: Sat Oct 6 19:33:52 2012
New Revision: 241287
URL: http://svn.freebsd.org/changeset/base/241287
Log:
In general pmap implementations do not set the wired attribute on
the temporary mappings that are used to implement operations like
pmap_zero_page(). There is no reason for the MIPS pmap to deviate
from that practice.
Modified:
head/sys/mips/mips/pmap.c
Modified: head/sys/mips/mips/pmap.c
==============================================================================
--- head/sys/mips/mips/pmap.c Sat Oct 6 19:33:47 2012 (r241286)
+++ head/sys/mips/mips/pmap.c Sat Oct 6 19:33:52 2012 (r241287)
@@ -239,8 +239,7 @@ pmap_lmem_map1(vm_paddr_t phys)
sysm = &sysmap_lmem[cpu];
sysm->saved_intr = intr;
va = sysm->base;
- npte = TLBLO_PA_TO_PFN(phys) |
- PTE_D | PTE_V | PTE_G | PTE_W | PTE_C_CACHE;
+ npte = TLBLO_PA_TO_PFN(phys) | PTE_C_CACHE | PTE_D | PTE_V | PTE_G;
pte = pmap_pte(kernel_pmap, va);
*pte = npte;
sysm->valid1 = 1;
@@ -262,12 +261,10 @@ pmap_lmem_map2(vm_paddr_t phys1, vm_padd
sysm->saved_intr = intr;
va1 = sysm->base;
va2 = sysm->base + PAGE_SIZE;
- npte = TLBLO_PA_TO_PFN(phys1) |
- PTE_D | PTE_V | PTE_G | PTE_W | PTE_C_CACHE;
+ npte = TLBLO_PA_TO_PFN(phys1) | PTE_C_CACHE | PTE_D | PTE_V | PTE_G;
pte = pmap_pte(kernel_pmap, va1);
*pte = npte;
- npte = TLBLO_PA_TO_PFN(phys2) |
- PTE_D | PTE_V | PTE_G | PTE_W | PTE_C_CACHE;
+ npte = TLBLO_PA_TO_PFN(phys2) | PTE_C_CACHE | PTE_D | PTE_V | PTE_G;
pte = pmap_pte(kernel_pmap, va2);
*pte = npte;
sysm->valid1 = 1;
@@ -2329,7 +2326,8 @@ pmap_kenter_temporary(vm_paddr_t pa, int
cpu = PCPU_GET(cpuid);
sysm = &sysmap_lmem[cpu];
/* Since this is for the debugger, no locks or any other fun */
- npte = TLBLO_PA_TO_PFN(pa) | PTE_D | PTE_V | PTE_G | PTE_W | PTE_C_CACHE;
+ npte = TLBLO_PA_TO_PFN(pa) | PTE_C_CACHE | PTE_D | PTE_V |
+ PTE_G;
pte = pmap_pte(kernel_pmap, sysm->base);
*pte = npte;
sysm->valid1 = 1;
More information about the svn-src-head
mailing list