summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authordg <dg@FreeBSD.org>1999-06-16 15:54:30 +0000
committerdg <dg@FreeBSD.org>1999-06-16 15:54:30 +0000
commite44ff62d384f14b4e19ee57b580fe95798be7e69 (patch)
treed52f0ce6bc71db0fe41f3881a9c30874849ad525 /sys
parent3b7c3aa4be419cf5415989e5ad1552b65226d743 (diff)
downloadFreeBSD-src-e44ff62d384f14b4e19ee57b580fe95798be7e69.zip
FreeBSD-src-e44ff62d384f14b4e19ee57b580fe95798be7e69.tar.gz
Changed trypbuf to a getpbuf to work around a problem where redundant writes
would occur when clustering them - caused by running out of buffers and taking a degenerate code path as a result. It appears that waiting instead for buffers to become available is okay. Submitted by: Matthew Dillon <dillon@apollo.backplane.com> Discovered by: Craig A Soules <soules+@andrew.cmu.edu>
Diffstat (limited to 'sys')
-rw-r--r--sys/kern/vfs_cluster.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/kern/vfs_cluster.c b/sys/kern/vfs_cluster.c
index 5f7f870..47e4322 100644
--- a/sys/kern/vfs_cluster.c
+++ b/sys/kern/vfs_cluster.c
@@ -33,7 +33,7 @@
* SUCH DAMAGE.
*
* @(#)vfs_cluster.c 8.7 (Berkeley) 2/13/94
- * $Id: vfs_cluster.c,v 1.80 1999/03/12 02:24:56 julian Exp $
+ * $Id: vfs_cluster.c,v 1.81 1999/05/02 23:56:11 alc Exp $
*/
#include "opt_debug_cluster.h"
@@ -660,7 +660,7 @@ cluster_wbuild(vp, size, start_lbn, len)
(tbp->b_bcount != tbp->b_bufsize) ||
(tbp->b_bcount != size) ||
(len == 1) ||
- ((bp = trypbuf(&cluster_pbuf_freecnt)) == NULL)) {
+ ((bp = getpbuf(&cluster_pbuf_freecnt)) == NULL)) {
totalwritten += tbp->b_bufsize;
bawrite(tbp);
++start_lbn;
OpenPOWER on IntegriCloud