Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 17 Feb 2014 20:25:17 +0000 (UTC)
From:      Dimitry Andric <dim@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r262127 - stable/10/sys/vm
Message-ID:  <201402172025.s1HKPH9d034483@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
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));
 }



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