Correct an error in the new pmap_collect(), thus only affecting HEAD.

Specifically, the pv entry was always being freed to the caller's pmap
instead of the pmap to which the pv entry belongs.
This commit is contained in:
Alan Cox 2006-07-02 18:22:47 +00:00
parent 7fd083a540
commit da536e6348
2 changed files with 2 additions and 2 deletions

View File

@ -1608,9 +1608,9 @@ pmap_collect(pmap_t locked_pmap, struct vpgqueues *vpq)
vm_page_flag_clear(m, PG_WRITEABLE);
m->md.pv_list_count--;
pmap_unuse_pt(pmap, va, ptepde);
free_pv_entry(pmap, pv);
if (pmap != locked_pmap)
PMAP_UNLOCK(pmap);
free_pv_entry(locked_pmap, pv);
}
}
}

View File

@ -1686,9 +1686,9 @@ pmap_collect(pmap_t locked_pmap, struct vpgqueues *vpq)
vm_page_flag_clear(m, PG_WRITEABLE);
m->md.pv_list_count--;
pmap_unuse_pt(pmap, va);
free_pv_entry(pmap, pv);
if (pmap != locked_pmap)
PMAP_UNLOCK(pmap);
free_pv_entry(locked_pmap, pv);
}
}
sched_unpin();