Commit f518e35a authored by Chuck Lever's avatar Chuck Lever Committed by Trond Myklebust

SUNRPC: get rid of cl_chatty

 Clean up: Every ULP that uses the in-kernel RPC client, except the NLM
 client, sets cl_chatty.  There's no reason why NLM shouldn't set it, so
 just get rid of cl_chatty and always be verbose.

 Test-plan:
 Compile with CONFIG_NFS enabled.
Signed-off-by: default avatarChuck Lever <cel@netapp.com>
Signed-off-by: default avatarTrond Myklebust <Trond.Myklebust@netapp.com>
parent 92200412
...@@ -223,7 +223,6 @@ nlmclnt_proc(struct inode *inode, int cmd, struct file_lock *fl) ...@@ -223,7 +223,6 @@ nlmclnt_proc(struct inode *inode, int cmd, struct file_lock *fl)
} }
clnt->cl_softrtry = nfssrv->client->cl_softrtry; clnt->cl_softrtry = nfssrv->client->cl_softrtry;
clnt->cl_intr = nfssrv->client->cl_intr; clnt->cl_intr = nfssrv->client->cl_intr;
clnt->cl_chatty = nfssrv->client->cl_chatty;
} }
/* Keep the old signal mask */ /* Keep the old signal mask */
......
...@@ -123,7 +123,6 @@ nsm_create(void) ...@@ -123,7 +123,6 @@ nsm_create(void)
if (IS_ERR(clnt)) if (IS_ERR(clnt))
goto out_err; goto out_err;
clnt->cl_softrtry = 1; clnt->cl_softrtry = 1;
clnt->cl_chatty = 1;
clnt->cl_oneshot = 1; clnt->cl_oneshot = 1;
return clnt; return clnt;
......
...@@ -413,7 +413,6 @@ nfs_create_client(struct nfs_server *server, const struct nfs_mount_data *data) ...@@ -413,7 +413,6 @@ nfs_create_client(struct nfs_server *server, const struct nfs_mount_data *data)
clnt->cl_intr = 1; clnt->cl_intr = 1;
clnt->cl_softrtry = 1; clnt->cl_softrtry = 1;
clnt->cl_chatty = 1;
return clnt; return clnt;
...@@ -1838,7 +1837,6 @@ static int nfs4_fill_super(struct super_block *sb, struct nfs4_mount_data *data, ...@@ -1838,7 +1837,6 @@ static int nfs4_fill_super(struct super_block *sb, struct nfs4_mount_data *data,
} }
clnt->cl_intr = 1; clnt->cl_intr = 1;
clnt->cl_softrtry = 1; clnt->cl_softrtry = 1;
clnt->cl_chatty = 1;
clp->cl_rpcclient = clnt; clp->cl_rpcclient = clnt;
memcpy(clp->cl_ipaddr, server->ip_addr, sizeof(clp->cl_ipaddr)); memcpy(clp->cl_ipaddr, server->ip_addr, sizeof(clp->cl_ipaddr));
nfs_idmap_new(clp); nfs_idmap_new(clp);
......
...@@ -82,7 +82,6 @@ mnt_create(char *hostname, struct sockaddr_in *srvaddr, int version, ...@@ -82,7 +82,6 @@ mnt_create(char *hostname, struct sockaddr_in *srvaddr, int version,
RPC_AUTH_UNIX); RPC_AUTH_UNIX);
if (!IS_ERR(clnt)) { if (!IS_ERR(clnt)) {
clnt->cl_softrtry = 1; clnt->cl_softrtry = 1;
clnt->cl_chatty = 1;
clnt->cl_oneshot = 1; clnt->cl_oneshot = 1;
clnt->cl_intr = 1; clnt->cl_intr = 1;
} }
......
...@@ -431,7 +431,6 @@ nfsd4_probe_callback(struct nfs4_client *clp) ...@@ -431,7 +431,6 @@ nfsd4_probe_callback(struct nfs4_client *clp)
} }
clnt->cl_intr = 0; clnt->cl_intr = 0;
clnt->cl_softrtry = 1; clnt->cl_softrtry = 1;
clnt->cl_chatty = 1;
/* Kick rpciod, put the call on the wire. */ /* Kick rpciod, put the call on the wire. */
......
...@@ -49,7 +49,6 @@ struct rpc_clnt { ...@@ -49,7 +49,6 @@ struct rpc_clnt {
unsigned int cl_softrtry : 1,/* soft timeouts */ unsigned int cl_softrtry : 1,/* soft timeouts */
cl_intr : 1,/* interruptible */ cl_intr : 1,/* interruptible */
cl_chatty : 1,/* be verbose */
cl_autobind : 1,/* use getport() */ cl_autobind : 1,/* use getport() */
cl_oneshot : 1,/* dispose after use */ cl_oneshot : 1,/* dispose after use */
cl_dead : 1;/* abandoned */ cl_dead : 1;/* abandoned */
......
...@@ -957,7 +957,6 @@ call_status(struct rpc_task *task) ...@@ -957,7 +957,6 @@ call_status(struct rpc_task *task)
rpc_exit(task, status); rpc_exit(task, status);
break; break;
default: default:
if (clnt->cl_chatty)
printk("%s: RPC call returned error %d\n", printk("%s: RPC call returned error %d\n",
clnt->cl_protname, -status); clnt->cl_protname, -status);
rpc_exit(task, status); rpc_exit(task, status);
...@@ -993,14 +992,13 @@ call_timeout(struct rpc_task *task) ...@@ -993,14 +992,13 @@ call_timeout(struct rpc_task *task)
dprintk("RPC: %4d call_timeout (major)\n", task->tk_pid); dprintk("RPC: %4d call_timeout (major)\n", task->tk_pid);
if (RPC_IS_SOFT(task)) { if (RPC_IS_SOFT(task)) {
if (clnt->cl_chatty)
printk(KERN_NOTICE "%s: server %s not responding, timed out\n", printk(KERN_NOTICE "%s: server %s not responding, timed out\n",
clnt->cl_protname, clnt->cl_server); clnt->cl_protname, clnt->cl_server);
rpc_exit(task, -EIO); rpc_exit(task, -EIO);
return; return;
} }
if (clnt->cl_chatty && !(task->tk_flags & RPC_CALL_MAJORSEEN)) { if (!(task->tk_flags & RPC_CALL_MAJORSEEN)) {
task->tk_flags |= RPC_CALL_MAJORSEEN; task->tk_flags |= RPC_CALL_MAJORSEEN;
printk(KERN_NOTICE "%s: server %s not responding, still trying\n", printk(KERN_NOTICE "%s: server %s not responding, still trying\n",
clnt->cl_protname, clnt->cl_server); clnt->cl_protname, clnt->cl_server);
...@@ -1027,7 +1025,7 @@ call_decode(struct rpc_task *task) ...@@ -1027,7 +1025,7 @@ call_decode(struct rpc_task *task)
dprintk("RPC: %4d call_decode (status %d)\n", dprintk("RPC: %4d call_decode (status %d)\n",
task->tk_pid, task->tk_status); task->tk_pid, task->tk_status);
if (clnt->cl_chatty && (task->tk_flags & RPC_CALL_MAJORSEEN)) { if (task->tk_flags & RPC_CALL_MAJORSEEN) {
printk(KERN_NOTICE "%s: server %s OK\n", printk(KERN_NOTICE "%s: server %s OK\n",
clnt->cl_protname, clnt->cl_server); clnt->cl_protname, clnt->cl_server);
task->tk_flags &= ~RPC_CALL_MAJORSEEN; task->tk_flags &= ~RPC_CALL_MAJORSEEN;
......
...@@ -217,7 +217,6 @@ pmap_create(char *hostname, struct sockaddr_in *srvaddr, int proto, int privileg ...@@ -217,7 +217,6 @@ pmap_create(char *hostname, struct sockaddr_in *srvaddr, int proto, int privileg
RPC_AUTH_UNIX); RPC_AUTH_UNIX);
if (!IS_ERR(clnt)) { if (!IS_ERR(clnt)) {
clnt->cl_softrtry = 1; clnt->cl_softrtry = 1;
clnt->cl_chatty = 1;
clnt->cl_oneshot = 1; clnt->cl_oneshot = 1;
} }
return clnt; return clnt;
......
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