diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-07-11 13:17:13 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-07-11 13:17:13 -0400 |
commit | 0ff08ba5d066619f9973bfcdb5a21320d54219d0 (patch) | |
tree | 526e4a5799eb3023e9d5d81e81c0964b1d928a3e /net/sunrpc/auth_gss/svcauth_gss.c | |
parent | c72bb316916b1a6cf35e1d5238566ef27b0b7f80 (diff) | |
parent | d109148111cdfcdae94f797dc142468bd0ff7557 (diff) |
Merge branch 'for-3.11' of git://linux-nfs.org/~bfields/linux
Pull nfsd changes from Bruce Fields:
"Changes this time include:
- 4.1 enabled on the server by default: the last 4.1-specific issues
I know of are fixed, so we're not going to find the rest of the
bugs without more exposure.
- Experimental support for NFSv4.2 MAC Labeling (to allow running
selinux over NFS), from Dave Quigley.
- Fixes for some delicate cache/upcall races that could cause rare
server hangs; thanks to Neil Brown and Bodo Stroesser for extreme
debugging persistence.
- Fixes for some bugs found at the recent NFS bakeathon, mostly v4
and v4.1-specific, but also a generic bug handling fragmented rpc
calls"
* 'for-3.11' of git://linux-nfs.org/~bfields/linux: (31 commits)
nfsd4: support minorversion 1 by default
nfsd4: allow destroy_session over destroyed session
svcrpc: fix failures to handle -1 uid's
sunrpc: Don't schedule an upcall on a replaced cache entry.
net/sunrpc: xpt_auth_cache should be ignored when expired.
sunrpc/cache: ensure items removed from cache do not have pending upcalls.
sunrpc/cache: use cache_fresh_unlocked consistently and correctly.
sunrpc/cache: remove races with queuing an upcall.
nfsd4: return delegation immediately if lease fails
nfsd4: do not throw away 4.1 lock state on last unlock
nfsd4: delegation-based open reclaims should bypass permissions
svcrpc: don't error out on small tcp fragment
svcrpc: fix handling of too-short rpc's
nfsd4: minor read_buf cleanup
nfsd4: fix decoding of compounds across page boundaries
nfsd4: clean up nfs4_open_delegation
NFSD: Don't give out read delegations on creates
nfsd4: allow client to send no cb_sec flavors
nfsd4: fail attempts to request gss on the backchannel
nfsd4: implement minimal SP4_MACH_CRED
...
Diffstat (limited to 'net/sunrpc/auth_gss/svcauth_gss.c')
-rw-r--r-- | net/sunrpc/auth_gss/svcauth_gss.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/net/sunrpc/auth_gss/svcauth_gss.c b/net/sunrpc/auth_gss/svcauth_gss.c index b05ace4c5f12..d0347d148b34 100644 --- a/net/sunrpc/auth_gss/svcauth_gss.c +++ b/net/sunrpc/auth_gss/svcauth_gss.c | |||
@@ -377,8 +377,7 @@ rsc_init(struct cache_head *cnew, struct cache_head *ctmp) | |||
377 | new->handle.data = tmp->handle.data; | 377 | new->handle.data = tmp->handle.data; |
378 | tmp->handle.data = NULL; | 378 | tmp->handle.data = NULL; |
379 | new->mechctx = NULL; | 379 | new->mechctx = NULL; |
380 | new->cred.cr_group_info = NULL; | 380 | init_svc_cred(&new->cred); |
381 | new->cred.cr_principal = NULL; | ||
382 | } | 381 | } |
383 | 382 | ||
384 | static void | 383 | static void |
@@ -392,9 +391,7 @@ update_rsc(struct cache_head *cnew, struct cache_head *ctmp) | |||
392 | memset(&new->seqdata, 0, sizeof(new->seqdata)); | 391 | memset(&new->seqdata, 0, sizeof(new->seqdata)); |
393 | spin_lock_init(&new->seqdata.sd_lock); | 392 | spin_lock_init(&new->seqdata.sd_lock); |
394 | new->cred = tmp->cred; | 393 | new->cred = tmp->cred; |
395 | tmp->cred.cr_group_info = NULL; | 394 | init_svc_cred(&tmp->cred); |
396 | new->cred.cr_principal = tmp->cred.cr_principal; | ||
397 | tmp->cred.cr_principal = NULL; | ||
398 | } | 395 | } |
399 | 396 | ||
400 | static struct cache_head * | 397 | static struct cache_head * |
@@ -487,7 +484,7 @@ static int rsc_parse(struct cache_detail *cd, | |||
487 | len = qword_get(&mesg, buf, mlen); | 484 | len = qword_get(&mesg, buf, mlen); |
488 | if (len < 0) | 485 | if (len < 0) |
489 | goto out; | 486 | goto out; |
490 | gm = gss_mech_get_by_name(buf); | 487 | gm = rsci.cred.cr_gss_mech = gss_mech_get_by_name(buf); |
491 | status = -EOPNOTSUPP; | 488 | status = -EOPNOTSUPP; |
492 | if (!gm) | 489 | if (!gm) |
493 | goto out; | 490 | goto out; |
@@ -517,7 +514,6 @@ static int rsc_parse(struct cache_detail *cd, | |||
517 | rscp = rsc_update(cd, &rsci, rscp); | 514 | rscp = rsc_update(cd, &rsci, rscp); |
518 | status = 0; | 515 | status = 0; |
519 | out: | 516 | out: |
520 | gss_mech_put(gm); | ||
521 | rsc_free(&rsci); | 517 | rsc_free(&rsci); |
522 | if (rscp) | 518 | if (rscp) |
523 | cache_put(&rscp->h, cd); | 519 | cache_put(&rscp->h, cd); |