提交 56928edd 编写于 作者: \ \"Talpey, Thomas\ 提交者: Trond Myklebust

NFS - print accurate transport protocol

Use the per-transport strings to display the transport protocol accurately.
Signed-off-by: NTom Talpey <tmt@netapp.com>
Signed-off-by: NTrond Myklebust <Trond.Myklebust@netapp.com>
上级 0896a725
......@@ -432,8 +432,6 @@ static void nfs_show_mount_options(struct seq_file *m, struct nfs_server *nfss,
};
const struct proc_nfs_info *nfs_infop;
struct nfs_client *clp = nfss->nfs_client;
char buf[12];
const char *proto;
seq_printf(m, ",vers=%d", clp->rpc_ops->version);
seq_printf(m, ",rsize=%d", nfss->rsize);
......@@ -452,18 +450,8 @@ static void nfs_show_mount_options(struct seq_file *m, struct nfs_server *nfss,
else
seq_puts(m, nfs_infop->nostr);
}
switch (nfss->client->cl_xprt->prot) {
case IPPROTO_TCP:
proto = "tcp";
break;
case IPPROTO_UDP:
proto = "udp";
break;
default:
snprintf(buf, sizeof(buf), "%u", nfss->client->cl_xprt->prot);
proto = buf;
}
seq_printf(m, ",proto=%s", proto);
seq_printf(m, ",proto=%s",
rpc_peeraddr2str(nfss->client, RPC_DISPLAY_PROTO));
seq_printf(m, ",timeo=%lu", 10U * clp->retrans_timeo / HZ);
seq_printf(m, ",retrans=%u", clp->retrans_count);
seq_printf(m, ",sec=%s", nfs_pseudoflavour_to_name(nfss->client->cl_auth->au_flavor));
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册