summaryrefslogtreecommitdiffstats
path: root/sys/amd64
diff options
context:
space:
mode:
authordyson <dyson@FreeBSD.org>1996-06-08 06:48:35 +0000
committerdyson <dyson@FreeBSD.org>1996-06-08 06:48:35 +0000
commitdca5ec165f1eaf7fc7cb1b5e3c0674ee4ccbadbf (patch)
treec06be8b58bb694a3550d8b7913a7706f218974f0 /sys/amd64
parent4935a152211b73994e774e1f61bfc933505f92c6 (diff)
downloadFreeBSD-src-dca5ec165f1eaf7fc7cb1b5e3c0674ee4ccbadbf.zip
FreeBSD-src-dca5ec165f1eaf7fc7cb1b5e3c0674ee4ccbadbf.tar.gz
Adjust the threshold for blocking on movement of pages from the cache
queue in vm_fault. Move the PG_BUSY in vm_fault to the correct place. Remove redundant/unnecessary code in pmap.c. Properly block on rundown of page table pages, if they are busy. I think that the VM system is in pretty good shape now, and the following individuals (among others, in no particular order) have helped with this recent bunch of bugs, thanks! If I left anyone out, I apologize! Stephen McKay, Stephen Hocking, Eric J. Chet, Dan O'Brien, James Raynard, Marc Fournier.
Diffstat (limited to 'sys/amd64')
-rw-r--r--sys/amd64/amd64/pmap.c37
1 files changed, 13 insertions, 24 deletions
diff --git a/sys/amd64/amd64/pmap.c b/sys/amd64/amd64/pmap.c
index 27a5236..c96196d 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.100 1996/06/05 06:36:21 dyson Exp $
+ * $Id: pmap.c,v 1.101 1996/06/07 02:36:08 dyson Exp $
*/
/*
@@ -730,17 +730,6 @@ pmap_release(pmap)
if (object->ref_count != 1)
panic("pmap_release: pteobj reference count != 1");
- /*
- * Wait until any (bogus) paging activity on this object is
- * complete.
- */
- s = splvm();
- while (object->paging_in_progress) {
- object->flags |= OBJ_PIPWNT;
- tsleep(object,PVM,"pmrlob",0);
- }
- splx(s);
-
ptdpg = NULL;
retry:
for (p = TAILQ_FIRST(&object->memq); p != NULL; p = n) {
@@ -749,15 +738,14 @@ retry:
ptdpg = p;
continue;
}
- if ((p->flags & PG_BUSY) || p->busy)
- continue;
if (!pmap_release_free_page(pmap, p))
goto retry;
}
if (ptdpg == NULL)
panic("pmap_release: missing page table directory page");
- pmap_release_free_page(pmap, ptdpg);
+ if (!pmap_release_free_page(pmap, ptdpg))
+ goto retry;
vm_object_deallocate(object);
if (pdstackptr < PDSTACKMAX) {
@@ -1173,7 +1161,11 @@ pmap_remove(pmap, sva, eva)
}
}
-
+/*
+ * Remove pte mapping, don't do everything that we would do
+ * for normal pages because many things aren't necessary (like
+ * pmap_update())...
+ */
void
pmap_remove_pte_mapping(pa)
vm_offset_t pa;
@@ -1189,7 +1181,6 @@ pmap_remove_pte_mapping(pa)
unsigned tpte;
struct pmap *pmap;
- anyvalid = 1;
pmap = pv->pv_pmap;
pte = get_ptbase(pmap) + i386_btop(pv->pv_va);
if (tpte = *pte) {
@@ -1200,13 +1191,11 @@ pmap_remove_pte_mapping(pa)
}
}
- if (anyvalid) {
- for (pv = *ppv; pv; pv = npv) {
- npv = pv->pv_next;
- free_pv_entry(pv);
- }
- *ppv = NULL;
+ for (pv = *ppv; pv; pv = npv) {
+ npv = pv->pv_next;
+ free_pv_entry(pv);
}
+ *ppv = NULL;
}
/*
@@ -1221,7 +1210,7 @@ pmap_remove_pte_mapping(pa)
* inefficient because they iteratively called
* pmap_remove (slow...)
*/
-static __inline void
+static void
pmap_remove_all(pa)
vm_offset_t pa;
{
OpenPOWER on IntegriCloud