diff options
author | Trond Myklebust <Trond.Myklebust@netapp.com> | 2012-04-30 12:04:58 -0400 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2012-04-30 12:04:58 -0400 |
commit | 3617e5031b3acec04efaa36566a8111ac8f07325 (patch) | |
tree | 20fac2901263ee8602e2c211dd971705c58974f5 /fs | |
parent | cbbb34498f8b2b26cbdc79532c8a2ee5cd1e756a (diff) |
NFSv4.1: Use the correct hostname in the client identifier string
We need to use the hostname of the process that created the nfs_client.
That hostname is now stored in the rpc_client->cl_nodename.
Also remove the utsname()->domainname component. There is no reason
to include the NIS/YP domainname in a client identifier string.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/nfs/nfs4proc.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index 75eb883ed4ce..99650aaf8937 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c | |||
@@ -5122,10 +5122,9 @@ int nfs4_proc_exchange_id(struct nfs_client *clp, struct rpc_cred *cred) | |||
5122 | nfs4_construct_boot_verifier(clp, &verifier); | 5122 | nfs4_construct_boot_verifier(clp, &verifier); |
5123 | 5123 | ||
5124 | args.id_len = scnprintf(args.id, sizeof(args.id), | 5124 | args.id_len = scnprintf(args.id, sizeof(args.id), |
5125 | "%s/%s.%s/%u", | 5125 | "%s/%s/%u", |
5126 | clp->cl_ipaddr, | 5126 | clp->cl_ipaddr, |
5127 | init_utsname()->nodename, | 5127 | clp->cl_rpcclient->cl_nodename, |
5128 | init_utsname()->domainname, | ||
5129 | clp->cl_rpcclient->cl_auth->au_flavor); | 5128 | clp->cl_rpcclient->cl_auth->au_flavor); |
5130 | 5129 | ||
5131 | res.server_scope = kzalloc(sizeof(struct server_scope), GFP_KERNEL); | 5130 | res.server_scope = kzalloc(sizeof(struct server_scope), GFP_KERNEL); |