diff options
| author | Linus Walleij <linus.walleij@linaro.org> | 2013-10-08 13:27:11 +0200 | 
|---|---|---|
| committer | Linus Walleij <linus.walleij@linaro.org> | 2013-10-08 13:27:11 +0200 | 
| commit | bfabb59433fc18ff78d2818e10e212d0f85d56ae (patch) | |
| tree | dd7cbead179c09c62627a84c16c802d99095ba6e /net/sunrpc/auth_gss/auth_gss.c | |
| parent | 6a08a92ec45782e5543addf5f8785e2560a078f6 (diff) | |
| parent | d0e639c9e06d44e713170031fe05fb60ebe680af (diff) | |
Merge tag 'v3.12-rc4' into devel
Linux 3.12-rc4
Diffstat (limited to 'net/sunrpc/auth_gss/auth_gss.c')
| -rw-r--r-- | net/sunrpc/auth_gss/auth_gss.c | 11 | 
1 files changed, 11 insertions, 0 deletions
diff --git a/net/sunrpc/auth_gss/auth_gss.c b/net/sunrpc/auth_gss/auth_gss.c index fcac5d14171..084656671d6 100644 --- a/net/sunrpc/auth_gss/auth_gss.c +++ b/net/sunrpc/auth_gss/auth_gss.c @@ -1075,6 +1075,15 @@ gss_destroy(struct rpc_auth *auth)  	kref_put(&gss_auth->kref, gss_free_callback);  } +/* + * Auths may be shared between rpc clients that were cloned from a + * common client with the same xprt, if they also share the flavor and + * target_name. + * + * The auth is looked up from the oldest parent sharing the same + * cl_xprt, and the auth itself references only that common parent + * (which is guaranteed to last as long as any of its descendants). + */  static struct gss_auth *  gss_auth_find_or_add_hashed(struct rpc_auth_create_args *args,  		struct rpc_clnt *clnt, @@ -1088,6 +1097,8 @@ gss_auth_find_or_add_hashed(struct rpc_auth_create_args *args,  			gss_auth,  			hash,  			hashval) { +		if (gss_auth->client != clnt) +			continue;  		if (gss_auth->rpc_auth.au_flavor != args->pseudoflavor)  			continue;  		if (gss_auth->target_name != args->target_name) {  | 
