NFSv4: Remove requirement for machine creds for the "setclientid" operation
Use a cred from the nfs4_client->cl_state_owners list. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
This commit is contained in:
@ -1822,23 +1822,9 @@ static int nfs4_fill_super(struct super_block *sb, struct nfs4_mount_data *data,
|
||||
clnt->cl_softrtry = 1;
|
||||
clnt->cl_chatty = 1;
|
||||
clp->cl_rpcclient = clnt;
|
||||
clp->cl_cred = rpcauth_lookupcred(clnt->cl_auth, 0);
|
||||
if (IS_ERR(clp->cl_cred)) {
|
||||
up_write(&clp->cl_sem);
|
||||
err = PTR_ERR(clp->cl_cred);
|
||||
clp->cl_cred = NULL;
|
||||
goto out_fail;
|
||||
}
|
||||
memcpy(clp->cl_ipaddr, server->ip_addr, sizeof(clp->cl_ipaddr));
|
||||
nfs_idmap_new(clp);
|
||||
}
|
||||
if (list_empty(&clp->cl_superblocks)) {
|
||||
err = nfs4_init_client(clp);
|
||||
if (err != 0) {
|
||||
up_write(&clp->cl_sem);
|
||||
goto out_fail;
|
||||
}
|
||||
}
|
||||
list_add_tail(&server->nfs4_siblings, &clp->cl_superblocks);
|
||||
clnt = rpc_clone_client(clp->cl_rpcclient);
|
||||
if (!IS_ERR(clnt))
|
||||
|
Reference in New Issue
Block a user