From 392e8d795801156738b8d51b8d1c8f840817db46 Mon Sep 17 00:00:00 2001 From: Matthew Dillon Date: Wed, 12 Aug 2009 14:38:50 -0700 Subject: [PATCH] AMD64 - Change VM_SWZONE_SIZE_MAX from 32M to 512M * Increase the KVM reservation for the swap zone structure on amd64. Space is reserved for enough swzone structures to cover around 512G of swap. --- sys/cpu/amd64/include/param.h | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/sys/cpu/amd64/include/param.h b/sys/cpu/amd64/include/param.h index bc82c29826..d258571d89 100644 --- a/sys/cpu/amd64/include/param.h +++ b/sys/cpu/amd64/include/param.h @@ -145,13 +145,17 @@ /* * Ceiling on amount of swblock kva space, can be changed via - * kern.maxswzone /boot/loader.conf variable. + * kern.maxswzone /boot/loader.conf variable. On 64 bit machines + * the kernel has a 512G address space so reserving 512M of KVM + * is not a big deal. * - * Approximately size / 160 x 32 x PAGE_SIZE bytes of swap. This + * Approximately (size / 160 x 32 x PAGE_SIZE) bytes of swap. This * comes to approximately 1GB of swap space per 1MB of kernel memory. + * Actually using 512G of swap will tie up a big chunk (512M) of physical + * memory. */ #ifndef VM_SWZONE_SIZE_MAX -#define VM_SWZONE_SIZE_MAX (32L * 1024 * 1024) +#define VM_SWZONE_SIZE_MAX (512L * 1024 * 1024) #endif /* -- 2.41.0