summaryrefslogtreecommitdiffstats
path: root/sys/kern/vfs_bio.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/kern/vfs_bio.c')
-rw-r--r--sys/kern/vfs_bio.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/kern/vfs_bio.c b/sys/kern/vfs_bio.c
index b1b760a..35ea932 100644
--- a/sys/kern/vfs_bio.c
+++ b/sys/kern/vfs_bio.c
@@ -621,7 +621,9 @@ bufinit(void)
lobufspace = hibufspace - MAXBSIZE;
lorunningspace = 512 * 1024;
- hirunningspace = 1024 * 1024;
+ hirunningspace = lmin(roundup(hibufspace/64, MAXBSIZE), 16*1024*1024);
+ if (hirunningspace < 1024 * 1024)
+ hirunningspace = 1024 * 1024;
/*
* Limit the amount of malloc memory since it is wired permanently into
OpenPOWER on IntegriCloud