Deleted Added
full compact
nfs_clvfsops.c (227507) nfs_clvfsops.c (227517)
1/*-
2 * Copyright (c) 1989, 1993, 1995
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from software contributed to Berkeley by
6 * Rick Macklem at The University of Guelph.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 19 unchanged lines hidden (view full) ---

28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30 * SUCH DAMAGE.
31 *
32 * from nfs_vfsops.c 8.12 (Berkeley) 5/20/95
33 */
34
35#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 1989, 1993, 1995
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from software contributed to Berkeley by
6 * Rick Macklem at The University of Guelph.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 19 unchanged lines hidden (view full) ---

28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30 * SUCH DAMAGE.
31 *
32 * from nfs_vfsops.c 8.12 (Berkeley) 5/20/95
33 */
34
35#include <sys/cdefs.h>
36__FBSDID("$FreeBSD: head/sys/fs/nfsclient/nfs_clvfsops.c 227507 2011-11-14 18:52:07Z jhb $");
36__FBSDID("$FreeBSD: head/sys/fs/nfsclient/nfs_clvfsops.c 227517 2011-11-15 01:39:02Z rmacklem $");
37
38
39#include "opt_bootp.h"
40#include "opt_nfsroot.h"
41
42#include <sys/param.h>
43#include <sys/systm.h>
44#include <sys/kernel.h>

--- 1181 unchanged lines hidden (view full) ---

1226 * Since nfs_decode_args() might optionally set them, these need to
1227 * set to defaults before the call, so that the optional settings
1228 * aren't overwritten.
1229 */
1230 nmp->nm_negnametimeo = negnametimeo;
1231 nmp->nm_timeo = NFS_TIMEO;
1232 nmp->nm_retry = NFS_RETRANS;
1233 nmp->nm_readahead = NFS_DEFRAHEAD;
37
38
39#include "opt_bootp.h"
40#include "opt_nfsroot.h"
41
42#include <sys/param.h>
43#include <sys/systm.h>
44#include <sys/kernel.h>

--- 1181 unchanged lines hidden (view full) ---

1226 * Since nfs_decode_args() might optionally set them, these need to
1227 * set to defaults before the call, so that the optional settings
1228 * aren't overwritten.
1229 */
1230 nmp->nm_negnametimeo = negnametimeo;
1231 nmp->nm_timeo = NFS_TIMEO;
1232 nmp->nm_retry = NFS_RETRANS;
1233 nmp->nm_readahead = NFS_DEFRAHEAD;
1234 if (desiredvnodes >= 11000)
1235 nmp->nm_wcommitsize = hibufspace / (desiredvnodes / 1000);
1236 else
1237 nmp->nm_wcommitsize = hibufspace / 10;
1234
1235 nfs_decode_args(mp, nmp, argp, hst, cred, td);
1236
1237 /*
1238 * V2 can only handle 32 bit filesizes. A 4GB-1 limit may be too
1239 * high, depending on whether we end up with negative offsets in
1240 * the client or server somewhere. 2GB-1 may be safer.
1241 *

--- 5 unchanged lines hidden (view full) ---

1247 else
1248 nmp->nm_maxfilesize = OFF_MAX;
1249
1250 if ((argp->flags & (NFSMNT_NFSV3 | NFSMNT_NFSV4)) == 0) {
1251 nmp->nm_wsize = NFS_WSIZE;
1252 nmp->nm_rsize = NFS_RSIZE;
1253 nmp->nm_readdirsize = NFS_READDIRSIZE;
1254 }
1238
1239 nfs_decode_args(mp, nmp, argp, hst, cred, td);
1240
1241 /*
1242 * V2 can only handle 32 bit filesizes. A 4GB-1 limit may be too
1243 * high, depending on whether we end up with negative offsets in
1244 * the client or server somewhere. 2GB-1 may be safer.
1245 *

--- 5 unchanged lines hidden (view full) ---

1251 else
1252 nmp->nm_maxfilesize = OFF_MAX;
1253
1254 if ((argp->flags & (NFSMNT_NFSV3 | NFSMNT_NFSV4)) == 0) {
1255 nmp->nm_wsize = NFS_WSIZE;
1256 nmp->nm_rsize = NFS_RSIZE;
1257 nmp->nm_readdirsize = NFS_READDIRSIZE;
1258 }
1255 nmp->nm_wcommitsize = hibufspace / (desiredvnodes / 1000);
1256 nmp->nm_numgrps = NFS_MAXGRPS;
1257 nmp->nm_tprintf_delay = nfs_tprintf_delay;
1258 if (nmp->nm_tprintf_delay < 0)
1259 nmp->nm_tprintf_delay = 0;
1260 nmp->nm_tprintf_initial_delay = nfs_tprintf_initial_delay;
1261 if (nmp->nm_tprintf_initial_delay < 0)
1262 nmp->nm_tprintf_initial_delay = 0;
1263 nmp->nm_fhsize = argp->fhsize;

--- 345 unchanged lines hidden ---
1259 nmp->nm_numgrps = NFS_MAXGRPS;
1260 nmp->nm_tprintf_delay = nfs_tprintf_delay;
1261 if (nmp->nm_tprintf_delay < 0)
1262 nmp->nm_tprintf_delay = 0;
1263 nmp->nm_tprintf_initial_delay = nfs_tprintf_initial_delay;
1264 if (nmp->nm_tprintf_initial_delay < 0)
1265 nmp->nm_tprintf_initial_delay = 0;
1266 nmp->nm_fhsize = argp->fhsize;

--- 345 unchanged lines hidden ---