svn commit: r281162 - head/sys/vm

Dmitry Chagin dchagin at FreeBSD.org
Mon Apr 6 18:45:42 UTC 2015


Author: dchagin
Date: Mon Apr  6 18:45:41 2015
New Revision: 281162
URL: https://svnweb.freebsd.org/changeset/base/281162

Log:
  Properly calculate "UMA Zones" per cpu cache size. Avoid allocating
  an extra struct uma_cache since the struct uma_zone already has one.
  
  PR:		199169
  Submitted by:	luke.tw gmail com
  MFC after:	1 week

Modified:
  head/sys/vm/uma_core.c

Modified: head/sys/vm/uma_core.c
==============================================================================
--- head/sys/vm/uma_core.c	Mon Apr  6 18:40:50 2015	(r281161)
+++ head/sys/vm/uma_core.c	Mon Apr  6 18:45:41 2015	(r281162)
@@ -1822,7 +1822,7 @@ uma_startup(void *bootmem, int boot_page
 #endif
 	args.name = "UMA Zones";
 	args.size = sizeof(struct uma_zone) +
-	    (sizeof(struct uma_cache) * (mp_maxid + 1));
+	    (sizeof(struct uma_cache) * (mp_maxid));
 	args.ctor = zone_ctor;
 	args.dtor = zone_dtor;
 	args.uminit = zero_init;


More information about the svn-src-head mailing list