svn commit: r357392 - head/sys/vm

Jeff Roberson jeff at FreeBSD.org
Sat Feb 1 23:46:31 UTC 2020


Author: jeff
Date: Sat Feb  1 23:46:30 2020
New Revision: 357392
URL: https://svnweb.freebsd.org/changeset/base/357392

Log:
  Fix a bug in r356776 where the page allocator was not properly restored to
  the percpu page allocator after it had been temporarily overridden by
  startup_alloc.
  
  Reported by:	pho, bdragon

Modified:
  head/sys/vm/uma_core.c

Modified: head/sys/vm/uma_core.c
==============================================================================
--- head/sys/vm/uma_core.c	Sat Feb  1 23:16:30 2020	(r357391)
+++ head/sys/vm/uma_core.c	Sat Feb  1 23:46:30 2020	(r357392)
@@ -2101,7 +2101,9 @@ zone_kva_available(uma_zone_t zone, void *unused)
 	if ((zone->uz_flags & UMA_ZFLAG_CACHE) != 0)
 		return;
 	KEG_GET(zone, keg);
-	if (keg->uk_allocf == startup_alloc)
+	if (keg->uk_flags & UMA_ZONE_PCPU)
+		keg->uk_allocf = pcpu_page_alloc;
+	else if (keg->uk_allocf == startup_alloc)
 		keg->uk_allocf = page_alloc;
 }
 


More information about the svn-src-all mailing list