aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Wemm <peter@FreeBSD.org>1998-05-31 19:20:44 +0000
committerPeter Wemm <peter@FreeBSD.org>1998-05-31 19:20:44 +0000
commitccc2eb6a3ae7f67a9bb8568dc4fa1fbe63e3f484 (patch)
treeea286b9cc009c457d9add7ea5246f2ab6b1df690
parent71c667c91b04cb4fc332bc68ef4d24217e337796 (diff)
Notes
-rw-r--r--sys/nfs/nfs_vfsops.c6
-rw-r--r--sys/nfsclient/nfs_vfsops.c6
2 files changed, 6 insertions, 6 deletions
diff --git a/sys/nfs/nfs_vfsops.c b/sys/nfs/nfs_vfsops.c
index bbfa4d1bb328e..167e6c92394e6 100644
--- a/sys/nfs/nfs_vfsops.c
+++ b/sys/nfs/nfs_vfsops.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_vfsops.c 8.12 (Berkeley) 5/20/95
- * $Id: nfs_vfsops.c,v 1.65 1998/05/31 17:27:54 peter Exp $
+ * $Id: nfs_vfsops.c,v 1.66 1998/05/31 18:19:43 peter Exp $
*/
#include <sys/param.h>
@@ -344,7 +344,7 @@ nfs_fsinfo(nmp, vp, cred, p)
if (!error) {
nfsm_dissect(fsp, struct nfsv3_fsinfo *, NFSX_V3FSINFO);
pref = fxdr_unsigned(u_long, fsp->fs_wtpref);
- if (pref < nmp->nm_wsize)
+ if (pref < nmp->nm_wsize && pref >= NFS_FABLKSIZE)
nmp->nm_wsize = (pref + NFS_FABLKSIZE - 1) &
~(NFS_FABLKSIZE - 1);
max = fxdr_unsigned(u_long, fsp->fs_wtmax);
@@ -354,7 +354,7 @@ nfs_fsinfo(nmp, vp, cred, p)
nmp->nm_wsize = max;
}
pref = fxdr_unsigned(u_long, fsp->fs_rtpref);
- if (pref < nmp->nm_rsize)
+ if (pref < nmp->nm_rsize && pref >= NFS_FABLKSIZE)
nmp->nm_rsize = (pref + NFS_FABLKSIZE - 1) &
~(NFS_FABLKSIZE - 1);
max = fxdr_unsigned(u_long, fsp->fs_rtmax);
diff --git a/sys/nfsclient/nfs_vfsops.c b/sys/nfsclient/nfs_vfsops.c
index bbfa4d1bb328e..167e6c92394e6 100644
--- a/sys/nfsclient/nfs_vfsops.c
+++ b/sys/nfsclient/nfs_vfsops.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_vfsops.c 8.12 (Berkeley) 5/20/95
- * $Id: nfs_vfsops.c,v 1.65 1998/05/31 17:27:54 peter Exp $
+ * $Id: nfs_vfsops.c,v 1.66 1998/05/31 18:19:43 peter Exp $
*/
#include <sys/param.h>
@@ -344,7 +344,7 @@ nfs_fsinfo(nmp, vp, cred, p)
if (!error) {
nfsm_dissect(fsp, struct nfsv3_fsinfo *, NFSX_V3FSINFO);
pref = fxdr_unsigned(u_long, fsp->fs_wtpref);
- if (pref < nmp->nm_wsize)
+ if (pref < nmp->nm_wsize && pref >= NFS_FABLKSIZE)
nmp->nm_wsize = (pref + NFS_FABLKSIZE - 1) &
~(NFS_FABLKSIZE - 1);
max = fxdr_unsigned(u_long, fsp->fs_wtmax);
@@ -354,7 +354,7 @@ nfs_fsinfo(nmp, vp, cred, p)
nmp->nm_wsize = max;
}
pref = fxdr_unsigned(u_long, fsp->fs_rtpref);
- if (pref < nmp->nm_rsize)
+ if (pref < nmp->nm_rsize && pref >= NFS_FABLKSIZE)
nmp->nm_rsize = (pref + NFS_FABLKSIZE - 1) &
~(NFS_FABLKSIZE - 1);
max = fxdr_unsigned(u_long, fsp->fs_rtmax);