FreeBSD/sys/powerpc/aim/mmu_oea.c
/*
 * Remove physical page from all pmaps in which it resides. moea_pvo_remove()
 * will reflect changes in pte's back to the vm_page.
 */
Remove physical page from all pmaps in which it resides. moea_pvo_remove()
will reflect changes in pte's back to the vm_page.
Remove physical page from all pmaps in which it resides . moea_pvo_remove () will reflect changes in pte ' s back to the vm_page .
void
moea_remove_all(mmu_t mmu, vm_page_t m)
{
	struct  pvo_head *pvo_head;
	struct	pvo_entry *pvo, *next_pvo;
	pmap_t	pmap;
	rw_wlock(&pvh_global_lock);
	pvo_head = vm_page_to_pvoh(m);
	for (pvo = LIST_FIRST(pvo_head); pvo != NULL; pvo = next_pvo) {
		next_pvo = LIST_NEXT(pvo, pvo_vlink);
		pmap = pvo->pvo_pmap;
		PMAP_LOCK(pmap);
		moea_pvo_remove(pvo, -1);
		PMAP_UNLOCK(pmap);
	}
	if ((m->aflags & PGA_WRITEABLE) && moea_query_bit(m, PTE_CHG)) {
		moea_attr_clear(m, PTE_CHG);
		vm_page_dirty(m);
	}
	vm_page_aflag_clear(m, PGA_WRITEABLE);
	rw_wunlock(&pvh_global_lock);
}
void moea_remove_all ( mmu_t mmu , vm_page_t m ) { struct pvo_head * pvo_head ; struct pvo_entry * pvo , * next_pvo ; pmap_t pmap ; rw_wlock ( & pvh_global_lock ) ; pvo_head = vm_page_to_pvoh ( m ) ; for ( pvo = LIST_FIRST ( pvo_head ) ; pvo != NULL ; pvo = next_pvo ) { next_pvo = LIST_NEXT ( pvo , pvo_vlink ) ; pmap = pvo -> pvo_pmap ; PMAP_LOCK ( pmap ) ; moea_pvo_remove ( pvo , -1 ) ; PMAP_UNLOCK ( pmap ) ; } if ( ( m -> aflags & PGA_WRITEABLE ) && moea_query_bit ( m , PTE_CHG ) ) { moea_attr_clear ( m , PTE_CHG ) ; vm_page_dirty ( m ) ; } vm_page_aflag_clear ( m , PGA_WRITEABLE ) ; rw_wunlock ( & pvh_global_lock ) ; }
Remove physical page from all pmaps in which it resides.
Remove physical page from all pmaps in which it resides .