summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoralc <alc@FreeBSD.org>1999-03-05 08:05:44 +0000
committeralc <alc@FreeBSD.org>1999-03-05 08:05:44 +0000
commitf5c5ee7c748944f91d946429a694d8592e912801 (patch)
tree43459379dc8890dbe3aff07df14813ebfad87ec0
parent5306f681cbc74a3458faaebd7870cbc4baa7745b (diff)
downloadFreeBSD-src-f5c5ee7c748944f91d946429a694d8592e912801.zip
FreeBSD-src-f5c5ee7c748944f91d946429a694d8592e912801.tar.gz
Fix an SMP-only TLB invalidation bug. Specifically, disable
a TLB invalidation optimization that won't work given the limitations of our current SMP support. This patch should be applied to -stable ASAP. Thanks to John Capo <jc@irbs.com>, Steve Kargl <sgk@troutmask.apl.washington.edu>, and Chuck Robey <chuckr@mat.net> for testing.
-rw-r--r--sys/amd64/amd64/pmap.c6
-rw-r--r--sys/i386/i386/pmap.c6
2 files changed, 10 insertions, 2 deletions
diff --git a/sys/amd64/amd64/pmap.c b/sys/amd64/amd64/pmap.c
index b689fd4..498f653 100644
--- a/sys/amd64/amd64/pmap.c
+++ b/sys/amd64/amd64/pmap.c
@@ -39,7 +39,7 @@
* SUCH DAMAGE.
*
* from: @(#)pmap.c 7.7 (Berkeley) 5/12/91
- * $Id: pmap.c,v 1.222 1999/01/28 01:59:50 dillon Exp $
+ * $Id: pmap.c,v 1.223 1999/02/19 14:25:33 luoqi Exp $
*/
/*
@@ -1991,11 +1991,15 @@ pmap_remove_all(pa)
if (pmap_track_modified(pv->pv_va))
vm_page_dirty(ppv->pv_vm_page);
}
+#ifdef SMP
+ update_needed = 1;
+#else
if (!update_needed &&
((!curproc || (vmspace_pmap(curproc->p_vmspace) == pv->pv_pmap)) ||
(pv->pv_pmap == kernel_pmap))) {
update_needed = 1;
}
+#endif
TAILQ_REMOVE(&pv->pv_pmap->pm_pvlist, pv, pv_plist);
TAILQ_REMOVE(&ppv->pv_list, pv, pv_list);
diff --git a/sys/i386/i386/pmap.c b/sys/i386/i386/pmap.c
index b689fd4..498f653 100644
--- a/sys/i386/i386/pmap.c
+++ b/sys/i386/i386/pmap.c
@@ -39,7 +39,7 @@
* SUCH DAMAGE.
*
* from: @(#)pmap.c 7.7 (Berkeley) 5/12/91
- * $Id: pmap.c,v 1.222 1999/01/28 01:59:50 dillon Exp $
+ * $Id: pmap.c,v 1.223 1999/02/19 14:25:33 luoqi Exp $
*/
/*
@@ -1991,11 +1991,15 @@ pmap_remove_all(pa)
if (pmap_track_modified(pv->pv_va))
vm_page_dirty(ppv->pv_vm_page);
}
+#ifdef SMP
+ update_needed = 1;
+#else
if (!update_needed &&
((!curproc || (vmspace_pmap(curproc->p_vmspace) == pv->pv_pmap)) ||
(pv->pv_pmap == kernel_pmap))) {
update_needed = 1;
}
+#endif
TAILQ_REMOVE(&pv->pv_pmap->pm_pvlist, pv, pv_plist);
TAILQ_REMOVE(&ppv->pv_list, pv, pv_list);
OpenPOWER on IntegriCloud