Add a default value for VM_BCACHE_SIZE_MAX of 400MB. This is copied from

amd64, and is a factor of 3 less than the value previously auto-sized on
a 12GB machine, which would cause an overflow in calculations involving the
maxbcache int, causing bufinit() to loop forever at boot.

Reviewed by:	mlaier, peter
This commit is contained in:
Kris Kennaway 2005-10-14 20:31:12 +00:00
parent 728ef95410
commit 3c2adf40e9

View File

@ -110,6 +110,14 @@
#define KSTACK_GUARD_PAGES 1 /* pages of kstack guard; 0 disables */
#define PCPU_PAGES 1
/*
* 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.
*/
#ifndef VM_BCACHE_SIZE_MAX
#define VM_BCACHE_SIZE_MAX (400 * 1024 * 1024)
#endif
/*
* Mach derived conversion macros