aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfs/super.c
diff options
context:
space:
mode:
authorTrond Myklebust <Trond.Myklebust@netapp.com>2008-06-17 16:12:00 -0400
committerTrond Myklebust <Trond.Myklebust@netapp.com>2008-07-09 12:09:25 -0400
commitcd100725620a8063fbc81bcf16d7c9e71a9583e0 (patch)
tree2c1f64d5ba23f45c91e6e29ba3bf10bbe696782c /fs/nfs/super.c
parente468bae97d243fe0e1515abaa1f7d0edf1476ad0 (diff)
NFS: Fix a dependency on CONFIG_NFS_V4 in nfs_remount
Fix the 'nfs4_fs_type' undeclared error in nfs_remount when compiling sans NFSv4... Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com> Cc: Jeff Layton <jlayton@redhat.com>
Diffstat (limited to 'fs/nfs/super.c')
-rw-r--r--fs/nfs/super.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/fs/nfs/super.c b/fs/nfs/super.c
index a1065c1a3149..b880db18035b 100644
--- a/fs/nfs/super.c
+++ b/fs/nfs/super.c
@@ -1428,6 +1428,7 @@ nfs_remount(struct super_block *sb, int *flags, char *raw_data)
1428 struct nfs_parsed_mount_data *data; 1428 struct nfs_parsed_mount_data *data;
1429 struct nfs_mount_data *options = (struct nfs_mount_data *)raw_data; 1429 struct nfs_mount_data *options = (struct nfs_mount_data *)raw_data;
1430 struct nfs4_mount_data *options4 = (struct nfs4_mount_data *)raw_data; 1430 struct nfs4_mount_data *options4 = (struct nfs4_mount_data *)raw_data;
1431 u32 nfsvers = nfss->nfs_client->rpc_ops->version;
1431 1432
1432 /* 1433 /*
1433 * Userspace mount programs that send binary options generally send 1434 * Userspace mount programs that send binary options generally send
@@ -1435,8 +1436,8 @@ nfs_remount(struct super_block *sb, int *flags, char *raw_data)
1435 * ones were explicitly specified. Fall back to legacy behavior and 1436 * ones were explicitly specified. Fall back to legacy behavior and
1436 * just return success. 1437 * just return success.
1437 */ 1438 */
1438 if ((sb->s_type == &nfs4_fs_type && options4->version == 1) || 1439 if ((nfsvers == 4 && options4->version == 1) ||
1439 (sb->s_type == &nfs_fs_type && options->version >= 1 && 1440 (nfsvers <= 3 && options->version >= 1 &&
1440 options->version <= 6)) 1441 options->version <= 6))
1441 return 0; 1442 return 0;
1442 1443