aboutsummaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorAlan Cox <alc@FreeBSD.org>2006-07-17 03:10:17 +0000
committerAlan Cox <alc@FreeBSD.org>2006-07-17 03:10:17 +0000
commite4cec2839810d2bb562e013747e4036063d21f22 (patch)
tree00840745b38dcee1d32627da65915d8af9f5ebd1 /sys
parentf2f0337e843aa9f50c28439ce3292b4ebab1e238 (diff)
Notes
Diffstat (limited to 'sys')
-rw-r--r--sys/amd64/amd64/pmap.c3
-rw-r--r--sys/i386/i386/pmap.c3
2 files changed, 4 insertions, 2 deletions
diff --git a/sys/amd64/amd64/pmap.c b/sys/amd64/amd64/pmap.c
index c5368dba6fb4..ed96ba7f3639 100644
--- a/sys/amd64/amd64/pmap.c
+++ b/sys/amd64/amd64/pmap.c
@@ -1627,6 +1627,7 @@ free_pv_entry(pmap_t pmap, pv_entry_t pv)
int idx, field, bit;
mtx_assert(&vm_page_queue_mtx, MA_OWNED);
+ PMAP_LOCK_ASSERT(pmap, MA_OWNED);
PV_STAT(pv_entry_frees++);
PV_STAT(pv_entry_spare++);
pv_entry_count--;
@@ -2015,8 +2016,8 @@ pmap_remove_all(vm_page_t m)
TAILQ_REMOVE(&m->md.pv_list, pv, pv_list);
m->md.pv_list_count--;
pmap_unuse_pt(pmap, pv->pv_va, ptepde);
- PMAP_UNLOCK(pmap);
free_pv_entry(pmap, pv);
+ PMAP_UNLOCK(pmap);
}
vm_page_flag_clear(m, PG_WRITEABLE);
}
diff --git a/sys/i386/i386/pmap.c b/sys/i386/i386/pmap.c
index e28069907fa5..24ae05919f18 100644
--- a/sys/i386/i386/pmap.c
+++ b/sys/i386/i386/pmap.c
@@ -1702,6 +1702,7 @@ free_pv_entry(pmap_t pmap, pv_entry_t pv)
int idx, field, bit;
mtx_assert(&vm_page_queue_mtx, MA_OWNED);
+ PMAP_LOCK_ASSERT(pmap, MA_OWNED);
PV_STAT(pv_entry_frees++);
PV_STAT(pv_entry_spare++);
pv_entry_count--;
@@ -2097,8 +2098,8 @@ pmap_remove_all(vm_page_t m)
TAILQ_REMOVE(&m->md.pv_list, pv, pv_list);
m->md.pv_list_count--;
pmap_unuse_pt(pmap, pv->pv_va);
- PMAP_UNLOCK(pmap);
free_pv_entry(pmap, pv);
+ PMAP_UNLOCK(pmap);
}
vm_page_flag_clear(m, PG_WRITEABLE);
sched_unpin();