Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 20 Apr 2014 18:21:06 +0000 (UTC)
From:      Ian Lepore <ian@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r264702 - head/sys/arm/arm
Message-ID:  <201404201821.s3KIL6UW072036@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ian
Date: Sun Apr 20 18:21:05 2014
New Revision: 264702
URL: http://svnweb.freebsd.org/changeset/base/264702

Log:
  Remove uncessary cache and TLB maintenance ops.
  
   - These were needed on armv4/5 (VIVT cache), not needed on armv6.
   - The wbinv_all call can't be used on SMP systems; cache operations by
     set/way are not broadcast to other cores.
   - The TLB maintenance operations needed for pmap_growkernel() happen in
     pmap_grow_l2_bucket(), so there's no need to flush all TLB entries at
     the end.
   - There may not be any need for the TLB flush at the beginning of
     pmap_release(), but it's left in for now pending more investigation.
  
  Pointed out by:	   Svatopluk Kraus <onwahe@gmail.com>
  Discussed with:	   cognet@

Modified:
  head/sys/arm/arm/pmap-v6.c

Modified: head/sys/arm/arm/pmap-v6.c
==============================================================================
--- head/sys/arm/arm/pmap-v6.c	Sun Apr 20 18:15:23 2014	(r264701)
+++ head/sys/arm/arm/pmap-v6.c	Sun Apr 20 18:21:05 2014	(r264702)
@@ -1988,8 +1988,6 @@ pmap_release(pmap_t pmap)
 {
 	struct pcb *pcb;
 
-	cpu_idcache_wbinv_all();
-	cpu_l2cache_wbinv_all();
 	cpu_tlb_flushID();
 	cpu_cpwait();
 	if (vector_page < KERNBASE) {
@@ -2175,14 +2173,6 @@ pmap_growkernel(vm_offset_t addr)
 	for (; pmap_curmaxkvaddr < addr; pmap_curmaxkvaddr += L1_S_SIZE)
 		pmap_grow_l2_bucket(kpmap, pmap_curmaxkvaddr);
 
-	/*
-	 * flush out the cache, expensive but growkernel will happen so
-	 * rarely
-	 */
-	cpu_dcache_wbinv_all();
-	cpu_l2cache_wbinv_all();
-	cpu_tlb_flushD();
-	cpu_cpwait();
 	kernel_vm_end = pmap_curmaxkvaddr;
 }
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201404201821.s3KIL6UW072036>