svn commit: r262127 - stable/10/sys/vm

Dimitry Andric dim at FreeBSD.org
Mon Feb 17 20:25:18 UTC 2014


Author: dim
Date: Mon Feb 17 20:25:17 2014
New Revision: 262127
URL: http://svnweb.freebsd.org/changeset/base/262127

Log:
  MFC r261896:
  
  After r251709, avoid a clang 3.4 warning about an unused static const
  variable (uma_max_ipers), when asserts are disabled.
  
  Reviewed by:	glebius

Modified:
  stable/10/sys/vm/uma_core.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/vm/uma_core.c
==============================================================================
--- stable/10/sys/vm/uma_core.c	Mon Feb 17 20:19:34 2014	(r262126)
+++ stable/10/sys/vm/uma_core.c	Mon Feb 17 20:25:17 2014	(r262127)
@@ -150,9 +150,6 @@ static int booted = 0;
 #define	UMA_STARTUP	1
 #define	UMA_STARTUP2	2
 
-/* Maximum number of allowed items-per-slab if the slab header is OFFPAGE */
-static const u_int uma_max_ipers = SLAB_SETSIZE;
-
 /*
  * Only mbuf clusters use ref zones.  Just provide enough references
  * to support the one user.  New code should not use the ref facility.
@@ -1388,7 +1385,7 @@ keg_cachespread_init(uma_keg_t keg)
 	keg->uk_slabsize = UMA_SLAB_SIZE;
 	keg->uk_ipers = ((pages * PAGE_SIZE) + trailer) / rsize;
 	keg->uk_flags |= UMA_ZONE_OFFPAGE | UMA_ZONE_VTOSLAB;
-	KASSERT(keg->uk_ipers <= uma_max_ipers,
+	KASSERT(keg->uk_ipers <= SLAB_SETSIZE,
 	    ("%s: keg->uk_ipers too high(%d) increase max_ipers", __func__,
 	    keg->uk_ipers));
 }


More information about the svn-src-stable-10 mailing list