diff options
author | dfr <dfr@FreeBSD.org> | 1997-05-10 16:59:36 +0000 |
---|---|---|
committer | dfr <dfr@FreeBSD.org> | 1997-05-10 16:59:36 +0000 |
commit | 824696dc98c3a0d29af46d3b3ef2a83c1195aea9 (patch) | |
tree | 72b0708fa5aa935ece6b4d428dbb0e9c338e108f /sys/nfs/nfs_serv.c | |
parent | ff5630dff67f4c3a38f2d5f2cc72d3bc7d9c2f4e (diff) | |
download | FreeBSD-src-824696dc98c3a0d29af46d3b3ef2a83c1195aea9.zip FreeBSD-src-824696dc98c3a0d29af46d3b3ef2a83c1195aea9.tar.gz |
Implement a separate control for write gathering on NFSv3. This is turned
off for NFSv3 by default since write gathering seems to reduce performance
for NFSv3 by up to 60%.
Add sysctl knobs to control both variables.
Diffstat (limited to 'sys/nfs/nfs_serv.c')
-rw-r--r-- | sys/nfs/nfs_serv.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/nfs/nfs_serv.c b/sys/nfs/nfs_serv.c index 7946328..75842dc 100644 --- a/sys/nfs/nfs_serv.c +++ b/sys/nfs/nfs_serv.c @@ -34,7 +34,7 @@ * SUCH DAMAGE. * * @(#)nfs_serv.c 8.3 (Berkeley) 1/12/94 - * $Id: nfs_serv.c,v 1.40 1997/03/29 12:40:18 bde Exp $ + * $Id: nfs_serv.c,v 1.41 1997/05/10 16:12:03 dfr Exp $ */ /* @@ -96,6 +96,7 @@ extern enum vtype nv3tov_type[8]; extern struct nfsstats nfsstats; int nfsrvw_procrastinate = NFS_GATHERDELAY * 1000; +int nfsrvw_procrastinate_v3 = 0; int nfs_async; SYSCTL_INT(_vfs_nfs, OID_AUTO, async, CTLFLAG_RW, &nfs_async, 0, ""); @@ -929,7 +930,8 @@ nfsrv_writegather(ndp, slp, procp, mrq) nfsd->nd_mreq = NULL; nfsd->nd_stable = NFSV3WRITE_FILESYNC; cur_usec = (u_quad_t)time.tv_sec * 1000000 + (u_quad_t)time.tv_usec; - nfsd->nd_time = cur_usec + nfsrvw_procrastinate; + nfsd->nd_time = cur_usec + + (v3 ? nfsrvw_procrastinate_v3 : nfsrvw_procrastinate); /* * Now, get the write header.. |