diff options
Diffstat (limited to 'fs/nfs/super.c')
| -rw-r--r-- | fs/nfs/super.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/nfs/super.c b/fs/nfs/super.c index ff656c022684..06228192f64e 100644 --- a/fs/nfs/super.c +++ b/fs/nfs/super.c | |||
| @@ -1867,6 +1867,7 @@ static int nfs23_validate_mount_data(void *options, | |||
| 1867 | if (data == NULL) | 1867 | if (data == NULL) |
| 1868 | goto out_no_data; | 1868 | goto out_no_data; |
| 1869 | 1869 | ||
| 1870 | args->version = NFS_DEFAULT_VERSION; | ||
| 1870 | switch (data->version) { | 1871 | switch (data->version) { |
| 1871 | case 1: | 1872 | case 1: |
| 1872 | data->namlen = 0; | 1873 | data->namlen = 0; |
| @@ -2637,6 +2638,8 @@ static int nfs4_validate_mount_data(void *options, | |||
| 2637 | if (data == NULL) | 2638 | if (data == NULL) |
| 2638 | goto out_no_data; | 2639 | goto out_no_data; |
| 2639 | 2640 | ||
| 2641 | args->version = 4; | ||
| 2642 | |||
| 2640 | switch (data->version) { | 2643 | switch (data->version) { |
| 2641 | case 1: | 2644 | case 1: |
| 2642 | if (data->host_addrlen > sizeof(args->nfs_server.address)) | 2645 | if (data->host_addrlen > sizeof(args->nfs_server.address)) |
| @@ -2857,6 +2860,8 @@ static struct dentry *nfs4_try_mount(int flags, const char *dev_name, | |||
| 2857 | 2860 | ||
| 2858 | dfprintk(MOUNT, "--> nfs4_try_mount()\n"); | 2861 | dfprintk(MOUNT, "--> nfs4_try_mount()\n"); |
| 2859 | 2862 | ||
| 2863 | mount_info->fill_super = nfs4_fill_super; | ||
| 2864 | |||
| 2860 | export_path = data->nfs_server.export_path; | 2865 | export_path = data->nfs_server.export_path; |
| 2861 | data->nfs_server.export_path = "/"; | 2866 | data->nfs_server.export_path = "/"; |
| 2862 | root_mnt = nfs_do_root_mount(&nfs4_remote_fs_type, flags, mount_info, | 2867 | root_mnt = nfs_do_root_mount(&nfs4_remote_fs_type, flags, mount_info, |
