Author: nwhitehorn Date: Tue Dec 28 17:02:15 2010 New Revision: 216765 URL: http://svn.freebsd.org/changeset/base/216765
Log: Only keep track of PTE validity statistics for pages not locked in the table. The 'locked' attribute is used to circumvent the regular page table locking for some special pages, with the result that including locked pages here causes races when updating the stats. Modified: head/sys/powerpc/aim/moea64_native.c Modified: head/sys/powerpc/aim/moea64_native.c ============================================================================== --- head/sys/powerpc/aim/moea64_native.c Tue Dec 28 16:57:29 2010 (r216764) +++ head/sys/powerpc/aim/moea64_native.c Tue Dec 28 17:02:15 2010 (r216765) @@ -281,7 +281,10 @@ moea64_pte_set_native(struct lpte *pt, s EIEIO(); pt->pte_hi = pvo_pt->pte_hi; PTESYNC(); - moea64_pte_valid++; + + /* Keep statistics for unlocked pages */ + if (!(pvo_pt->pte_hi & LPTE_LOCKED)) + moea64_pte_valid++; } static void @@ -310,7 +313,10 @@ moea64_pte_unset_native(mmu_t mmu, uintp * Save the reg & chg bits. */ moea64_pte_synch_native(mmu, pt_cookie, pvo_pt); - moea64_pte_valid--; + + /* Keep statistics for unlocked pages */ + if (!(pvo_pt->pte_hi & LPTE_LOCKED)) + moea64_pte_valid--; } static void _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"