summaryrefslogtreecommitdiffstats
path: root/fs/nfs/namespace.c
diff options
context:
space:
mode:
authorBryan Schumaker2012-04-27 19:27:42 +0200
committerTrond Myklebust2012-04-27 20:10:03 +0200
commit7e6eb683d260d9325f0d1bd911518d5ed3cb4f0c (patch)
tree51b22645b2e55cff65acf9feb0d9f43f44ed70d3 /fs/nfs/namespace.c
parentNFS: Fix following referral mount points with different security (diff)
downloadkernel-qcow2-linux-7e6eb683d260d9325f0d1bd911518d5ed3cb4f0c.tar.gz
kernel-qcow2-linux-7e6eb683d260d9325f0d1bd911518d5ed3cb4f0c.tar.xz
kernel-qcow2-linux-7e6eb683d260d9325f0d1bd911518d5ed3cb4f0c.zip
NFS: Honor the authflavor set in the clone mount data
The authflavor is set in an nfs_clone_mount structure and passed to the xdev_mount() functions where it was promptly ignored. Instead, use it to initialize an rpc_clnt for the cloned server. Signed-off-by: Bryan Schumaker <bjschuma@netapp.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs/nfs/namespace.c')
-rw-r--r--fs/nfs/namespace.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/nfs/namespace.c b/fs/nfs/namespace.c
index b9a593d056b3..78dde307317f 100644
--- a/fs/nfs/namespace.c
+++ b/fs/nfs/namespace.c
@@ -257,7 +257,6 @@ struct vfsmount *nfs_d_automount(struct path *path)
struct nfs_fh *fh = NULL;
struct nfs_fattr *fattr = NULL;
struct rpc_clnt *client;
- rpc_authflavor_t flavor = RPC_AUTH_UNIX;
dprintk("--> nfs_d_automount()\n");
@@ -285,7 +284,7 @@ struct vfsmount *nfs_d_automount(struct path *path)
if (fattr->valid & NFS_ATTR_FATTR_V4_REFERRAL)
mnt = nfs_do_refmount(client, path->dentry);
else
- mnt = nfs_do_submount(path->dentry, fh, fattr, flavor);
+ mnt = nfs_do_submount(path->dentry, fh, fattr, client->cl_auth->au_flavor);
rpc_shutdown_client(client);
if (IS_ERR(mnt))