Page MenuHomeFreeBSD

D50112.id154676.diff
No OneTemporary

D50112.id154676.diff

Index: sys/vm/vm_page.c
===================================================================
--- sys/vm/vm_page.c
+++ sys/vm/vm_page.c
@@ -2593,18 +2593,19 @@
vm_domain_free_unlock(vmd);
return (NULL);
}
- m->pindex = count;
+ m->ref_count = count - 1;
TAILQ_INSERT_HEAD(&vmd->vmd_nofreeq, m, listq);
VM_CNT_ADD(v_nofree_count, count);
}
m = TAILQ_FIRST(&vmd->vmd_nofreeq);
TAILQ_REMOVE(&vmd->vmd_nofreeq, m, listq);
- if (m->pindex > 1) {
+ if (m->ref_count > 0) {
vm_page_t m_next;
m_next = &m[1];
- m_next->pindex = m->pindex - 1;
+ m_next->ref_count = m->ref_count - 1;
TAILQ_INSERT_HEAD(&vmd->vmd_nofreeq, m_next, listq);
+ m->ref_count = 0;
}
vm_domain_free_unlock(vmd);
VM_CNT_ADD(v_nofree_count, -1);
@@ -2622,7 +2623,7 @@
vm_page_free_nofree(struct vm_domain *vmd, vm_page_t m)
{
vm_domain_free_lock(vmd);
- m->pindex = 1;
+ MPASS(m->ref_count == 0);
TAILQ_INSERT_HEAD(&vmd->vmd_nofreeq, m, listq);
vm_domain_free_unlock(vmd);
VM_CNT_ADD(v_nofree_count, 1);

File Metadata

Mime Type
text/plain
Expires
Sun, Oct 12, 6:36 PM (4 m, 31 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
23635919
Default Alt Text
D50112.id154676.diff (1021 B)

Event Timeline