Writing anything but '1' to the use-gss-proxy file currently results in an error. This means that you can't explicitly disable gssproxy. Change it so that it allows a '0' to be written there as well. With this, we can potentially have rpc.svcgssd write a 0 to this file to get around the initial 5s hang on RPCs if gssproxy is not in use. Signed-off-by: Jeff Layton <jlayton@xxxxxxxxxx> --- net/sunrpc/auth_gss/svcauth_gss.c | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/net/sunrpc/auth_gss/svcauth_gss.c b/net/sunrpc/auth_gss/svcauth_gss.c index 17c24bd..aa30d49 100644 --- a/net/sunrpc/auth_gss/svcauth_gss.c +++ b/net/sunrpc/auth_gss/svcauth_gss.c @@ -1342,12 +1342,20 @@ static ssize_t write_gssp(struct file *file, const char __user *buf, res = kstrtoul(tbuf, 0, &i); if (res) return res; - if (i != 1) + + switch (i) { + case 1: + res = set_gssp_clnt(net); + if (res) + return res; + break; + case 0: + break; + default: return -EINVAL; - res = set_gssp_clnt(net); - if (res) - return res; - res = set_gss_proxy(net, 1); + } + + res = set_gss_proxy(net, i); if (res) return res; return count; -- 1.8.4.2 -- To unsubscribe from this list: send the line "unsubscribe linux-nfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html