Commit 0ea9de0e authored by Jeff Layton's avatar Jeff Layton Committed by Trond Myklebust

sunrpc: turn warn_gssd() log message into a dprintk()

The original printk() made sense when the GSSAPI codepaths were called
only when sec=krb5* was explicitly requested. Now however, in many cases
the nfs client will try to acquire GSSAPI credentials by default, even
when it's not requested.

Since we don't have a great mechanism to distinguish between the two
cases, just turn the pr_warn into a dprintk instead. With this change we
can also get rid of the ratelimiting.

We do need to keep the EXPORT_SYMBOL(gssd_running) in place since
auth_gss.ko needs it and sunrpc.ko provides it. We can however,
eliminate the gssd_running call in the nfs code since that's a bit of a
layering violation.
Signed-off-by: default avatarJeff Layton <jlayton@redhat.com>
Signed-off-by: default avatarTrond Myklebust <trond.myklebust@primarydata.com>
parent d529ef83
...@@ -372,10 +372,7 @@ struct nfs_client *nfs4_init_client(struct nfs_client *clp, ...@@ -372,10 +372,7 @@ struct nfs_client *nfs4_init_client(struct nfs_client *clp,
__set_bit(NFS_CS_DISCRTRY, &clp->cl_flags); __set_bit(NFS_CS_DISCRTRY, &clp->cl_flags);
__set_bit(NFS_CS_NO_RETRANS_TIMEOUT, &clp->cl_flags); __set_bit(NFS_CS_NO_RETRANS_TIMEOUT, &clp->cl_flags);
error = -EINVAL; error = nfs_create_rpc_client(clp, timeparms, RPC_AUTH_GSS_KRB5I);
if (gssd_running(clp->cl_net))
error = nfs_create_rpc_client(clp, timeparms,
RPC_AUTH_GSS_KRB5I);
if (error == -EINVAL) if (error == -EINVAL)
error = nfs_create_rpc_client(clp, timeparms, RPC_AUTH_UNIX); error = nfs_create_rpc_client(clp, timeparms, RPC_AUTH_UNIX);
if (error < 0) if (error < 0)
......
...@@ -532,13 +532,7 @@ gss_setup_upcall(struct gss_auth *gss_auth, struct rpc_cred *cred) ...@@ -532,13 +532,7 @@ gss_setup_upcall(struct gss_auth *gss_auth, struct rpc_cred *cred)
static void warn_gssd(void) static void warn_gssd(void)
{ {
static unsigned long ratelimit; dprintk("AUTH_GSS upcall failed. Please check user daemon is running.\n");
unsigned long now = jiffies;
if (time_after(now, ratelimit)) {
pr_warn("RPC: AUTH_GSS upcall failed. Please check user daemon is running.\n");
ratelimit = now + 15*HZ;
}
} }
static inline int static inline int
......
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