summaryrefslogtreecommitdiffstats
path: root/sys/alpha
diff options
context:
space:
mode:
authoralc <alc@FreeBSD.org>2004-04-24 20:53:55 +0000
committeralc <alc@FreeBSD.org>2004-04-24 20:53:55 +0000
commit106fdfcb2b41f5994fcce7d63193060ddf3fd6ec (patch)
treeb1edd1c09e5fbd01f822423350dbe7bf2ca92c4a /sys/alpha
parentabc6dc77728ccca216d89be00cb15898f75de565 (diff)
downloadFreeBSD-src-106fdfcb2b41f5994fcce7d63193060ddf3fd6ec.zip
FreeBSD-src-106fdfcb2b41f5994fcce7d63193060ddf3fd6ec.tar.gz
Push down the responsibility for zeroing a physical page from the
caller to vm_page_grab(). Although this gives VM_ALLOC_ZERO a different meaning for vm_page_grab() than for vm_page_alloc(), I feel such change is necessary to accomplish other goals. Specifically, I want to make the PG_ZERO flag immutable between the time it is allocated by vm_page_alloc() and freed by vm_page_free() or vm_page_free_zero() to avoid locking overheads. Once we gave up on the ability to automatically recognize a zeroed page upon entry to vm_page_free(), the ability to mutate the PG_ZERO flag became useless. Instead, I would like to say that "Once a page becomes valid, its PG_ZERO flag must be ignored."
Diffstat (limited to 'sys/alpha')
-rw-r--r--sys/alpha/alpha/pmap.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/sys/alpha/alpha/pmap.c b/sys/alpha/alpha/pmap.c
index 11571cb..30afacb 100644
--- a/sys/alpha/alpha/pmap.c
+++ b/sys/alpha/alpha/pmap.c
@@ -1194,8 +1194,6 @@ _pmap_allocpte(pmap, ptepindex)
VM_OBJECT_LOCK(pmap->pm_pteobj);
m = vm_page_grab(pmap->pm_pteobj, ptepindex,
VM_ALLOC_WIRED | VM_ALLOC_ZERO | VM_ALLOC_RETRY);
- if ((m->flags & PG_ZERO) == 0)
- pmap_zero_page(m);
KASSERT(m->queue == PQ_NONE,
("_pmap_allocpte: %p->queue != PQ_NONE", m));
@@ -1242,7 +1240,6 @@ _pmap_allocpte(pmap, ptepindex)
vm_page_lock_queues();
m->valid = VM_PAGE_BITS_ALL;
- vm_page_flag_clear(m, PG_ZERO);
vm_page_wakeup(m);
vm_page_unlock_queues();
if (!is_object_locked)
OpenPOWER on IntegriCloud