Disabled the optimization of not doing an invltlb_1pg() when changing
pte's from zero. The TLB is supposed to be invalidated when pte's are changed _to_ zero, but this doesn't occur in all cases for global pages (PG_G stops invltlb() from working, and invltlb_1pg() is not used enough). PR: 14141, 16568 Submitted by: dillon
This commit is contained in:
parent
023caa7b58
commit
311b554beb
@ -781,8 +781,8 @@ pmap_kenter(va, pa)
|
||||
pte = (unsigned *)vtopte(va);
|
||||
opte = *pte;
|
||||
*pte = npte;
|
||||
if (opte)
|
||||
invltlb_1pg(va);
|
||||
/*if (opte)*/
|
||||
invltlb_1pg(va); /* XXX what about SMP? */
|
||||
}
|
||||
|
||||
/*
|
||||
@ -796,7 +796,7 @@ pmap_kremove(va)
|
||||
|
||||
pte = (unsigned *)vtopte(va);
|
||||
*pte = 0;
|
||||
invltlb_1pg(va);
|
||||
invltlb_1pg(va); /* XXX what about SMP? */
|
||||
}
|
||||
|
||||
/*
|
||||
@ -2183,7 +2183,7 @@ pmap_enter(pmap_t pmap, vm_offset_t va, vm_offset_t pa, vm_prot_t prot,
|
||||
*/
|
||||
if ((origpte & ~(PG_M|PG_A)) != newpte) {
|
||||
*pte = newpte | PG_A;
|
||||
if (origpte) {
|
||||
/*if (origpte)*/ {
|
||||
#ifdef SMP
|
||||
cpu_invlpg((void *)va);
|
||||
if (pmap->pm_active & other_cpus)
|
||||
|
@ -781,8 +781,8 @@ pmap_kenter(va, pa)
|
||||
pte = (unsigned *)vtopte(va);
|
||||
opte = *pte;
|
||||
*pte = npte;
|
||||
if (opte)
|
||||
invltlb_1pg(va);
|
||||
/*if (opte)*/
|
||||
invltlb_1pg(va); /* XXX what about SMP? */
|
||||
}
|
||||
|
||||
/*
|
||||
@ -796,7 +796,7 @@ pmap_kremove(va)
|
||||
|
||||
pte = (unsigned *)vtopte(va);
|
||||
*pte = 0;
|
||||
invltlb_1pg(va);
|
||||
invltlb_1pg(va); /* XXX what about SMP? */
|
||||
}
|
||||
|
||||
/*
|
||||
@ -2183,7 +2183,7 @@ pmap_enter(pmap_t pmap, vm_offset_t va, vm_offset_t pa, vm_prot_t prot,
|
||||
*/
|
||||
if ((origpte & ~(PG_M|PG_A)) != newpte) {
|
||||
*pte = newpte | PG_A;
|
||||
if (origpte) {
|
||||
/*if (origpte)*/ {
|
||||
#ifdef SMP
|
||||
cpu_invlpg((void *)va);
|
||||
if (pmap->pm_active & other_cpus)
|
||||
|
Loading…
Reference in New Issue
Block a user