FreeBSD/sys/powerpc/aim/mmu_oea.c
/*
 *	moea_ts_referenced:
 *
 *	Return a count of reference bits for a page, clearing those bits.
 *	It is not necessary for every reference bit to be cleared, but it
 *	is necessary that 0 only be returned when there are truly no
 *	reference bits set.
 *
 *	XXX: The exact number of bits to check and clear is a matter that
 *	should be tested and standardized at some point in the future for
 *	optimal aging of shared pages.
 */
Return a count of reference bits for a page, clearing those bits.
It is not necessary for every reference bit to be cleared, but it
is necessary that 0 only be returned when there are truly no
reference bits set.

The exact number of bits to check and clear is a matter that
should be tested and standardized at some point in the future for
optimal aging of shared pages.
Return a count of reference bits for a page clearing those bits . It is not necessary for every reference bit to be cleared but it is necessary that 0 only be returned when there are truly no reference bits set . The exact number of bits to check and clear is a matter that should be tested and standardized at some point in the future for optimal aging of shared pages .
int
moea_ts_referenced(mmu_t mmu, vm_page_t m)
{
	int count;
	KASSERT((m->oflags & VPO_UNMANAGED) == 0,
	    ("moea_ts_referenced: page %p is not managed", m));
	rw_wlock(&pvh_global_lock);
	count = moea_clear_bit(m, PTE_REF);
	rw_wunlock(&pvh_global_lock);
	return (count);
}
int moea_ts_referenced ( mmu_t mmu , vm_page_t m ) { int count ; KASSERT ( ( m -> oflags & VPO_UNMANAGED ) == 0 , ( " " , m ) ) ; rw_wlock ( & pvh_global_lock ) ; count = moea_clear_bit ( m , PTE_REF ) ; rw_wunlock ( & pvh_global_lock ) ; return ( count ) ; }
moea_ts_referenced:
      Return a count of reference bits for a page, clearing those bits.
moea_ts_referenced : Return a count of reference bits for a page clearing those bits .