Commit cdf66442 authored by Bryan Schumaker's avatar Bryan Schumaker Committed by Trond Myklebust

NFS4: Set parsed mount data version to 4

This patch only affects mounting through "-t nfs4" since it doesn't set
up an nfs version to use in the mount data.  The nfs client was trying
to mount using NFS v0, causing either a BUG() or a protocol not
supported message.
Signed-off-by: default avatarBryan Schumaker <bjschuma@netapp.com>
Signed-off-by: default avatarTrond Myklebust <Trond.Myklebust@netapp.com>
parent bda197f5
...@@ -2637,6 +2637,8 @@ static int nfs4_validate_mount_data(void *options, ...@@ -2637,6 +2637,8 @@ static int nfs4_validate_mount_data(void *options,
if (data == NULL) if (data == NULL)
goto out_no_data; goto out_no_data;
args->version = 4;
switch (data->version) { switch (data->version) {
case 1: case 1:
if (data->host_addrlen > sizeof(args->nfs_server.address)) if (data->host_addrlen > sizeof(args->nfs_server.address))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment