Author: jchandra Date: Thu Aug 12 09:15:27 2010 New Revision: 211216 URL: http://svn.freebsd.org/changeset/base/211216
Log: Optimization for pmap_kenter(), call pmap_update_page() only when necessary. On SMP, pmap_update_page() can be costly as it needs a a smp_rendezvous(). Reviewed by: alc, neel Obtained from: jmallett (http://svn.freebsd.org/base/user/jmallett/octeon) Modified: head/sys/mips/mips/pmap.c Modified: head/sys/mips/mips/pmap.c ============================================================================== --- head/sys/mips/mips/pmap.c Thu Aug 12 09:03:21 2010 (r211215) +++ head/sys/mips/mips/pmap.c Thu Aug 12 09:15:27 2010 (r211216) @@ -810,7 +810,8 @@ pmap_kenter(vm_offset_t va, vm_paddr_t p pte = pmap_pte(kernel_pmap, va); opte = *pte; *pte = npte; - pmap_update_page(kernel_pmap, va, npte); + if (pte_test(&opte, PTE_V) && opte != npte) + pmap_update_page(kernel_pmap, va, npte); } /* _______________________________________________ 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"