diff options
author | des <des@FreeBSD.org> | 2012-08-27 13:22:27 +0000 |
---|---|---|
committer | des <des@FreeBSD.org> | 2012-08-27 13:22:27 +0000 |
commit | 2d4d812fecc8adc9c98e129a432978ed92fe0841 (patch) | |
tree | 19d5b74c3c372ec7ef18dd42d79765d6f4b74762 /sys/i386/include/param.h | |
parent | 91ac59768e01665b410d3b300837246ebb43e79e (diff) | |
download | FreeBSD-src-2d4d812fecc8adc9c98e129a432978ed92fe0841.zip FreeBSD-src-2d4d812fecc8adc9c98e129a432978ed92fe0841.tar.gz |
Parly revert r239255: reinstate a default maxswzone on i386, where KVA is
scarce, but set it slightly higher so we can handle 8 GB of swap.
Diffstat (limited to 'sys/i386/include/param.h')
-rw-r--r-- | sys/i386/include/param.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/sys/i386/include/param.h b/sys/i386/include/param.h index c1e1424..b494f35 100644 --- a/sys/i386/include/param.h +++ b/sys/i386/include/param.h @@ -123,6 +123,20 @@ #define KSTACK_GUARD_PAGES 1 /* pages of kstack guard; 0 disables */ /* + * Ceiling on amount of swblock kva space, can be changed via + * the kern.maxswzone /boot/loader.conf variable. + * + * 276 is sizeof(struct swblock), but we do not always have a definition + * in scope for struct swblock, so we have to hardcode it. Each struct + * swblock holds metadata for 32 pages, so in theory, this is enough for + * 16 GB of swap. In practice, however, the usable amount is considerably + * lower due to fragmentation. + */ +#ifndef VM_SWZONE_SIZE_MAX +#define VM_SWZONE_SIZE_MAX (276 * 128 * 1024) +#endif + +/* * Ceiling on size of buffer cache (really only effects write queueing, * the VM page cache is not effected), can be changed via * the kern.maxbcache /boot/loader.conf variable. |