svn commit: r357546 - head/sys/vm
Ryan Libby
rlibby at FreeBSD.org
Tue Feb 4 22:39:58 UTC 2020
Author: rlibby
Date: Tue Feb 4 22:39:58 2020
New Revision: 357546
URL: https://svnweb.freebsd.org/changeset/base/357546
Log:
uma: pcpu_page_free needs to startup_free pages from startup_alloc
After r357392, it is apparent that we do have some early-boot PCPU
zones. Make it so we can safely free pages from them if they are
actually used during early boot.
Reviewed by: jeff, markj
Sponsored by: Dell EMC Isilon
Differential Revision: https://reviews.freebsd.org/D23496
Modified:
head/sys/vm/uma_core.c
Modified: head/sys/vm/uma_core.c
==============================================================================
--- head/sys/vm/uma_core.c Tue Feb 4 21:43:39 2020 (r357545)
+++ head/sys/vm/uma_core.c Tue Feb 4 22:39:58 2020 (r357546)
@@ -1704,6 +1704,12 @@ pcpu_page_free(void *mem, vm_size_t size, uint8_t flag
vm_page_t m;
MPASS(size == (mp_maxid+1)*PAGE_SIZE);
+
+ if ((flags & UMA_SLAB_BOOT) != 0) {
+ startup_free(mem, size);
+ return;
+ }
+
sva = (vm_offset_t)mem;
for (curva = sva; curva < sva + size; curva += PAGE_SIZE) {
paddr = pmap_kextract(curva);
More information about the svn-src-all
mailing list