[PATCH] knfsd: Correctly handle error condition from lockd_up
authorNeilBrown <neilb@suse.de>
Mon, 2 Oct 2006 09:17:53 +0000 (02:17 -0700)
committerLinus Torvalds <torvalds@g5.osdl.org>
Mon, 2 Oct 2006 14:57:18 +0000 (07:57 -0700)
commit4a3ae42dc312dbdffee803efaf393421b79f997a
treed18249c89fc1a5ab273beec1639cde769a0b6e96
parent7dcf91ec6698fe8564ad91bbe42740aacaa0d9ee
[PATCH] knfsd: Correctly handle error condition from lockd_up

If lockd_up fails - what should we expect?  Do we have to later call
lockd_down?

Well the nfs client thinks "no", the nfs server thinks "yes".  lockd thinks
"yes".

The only answer that really makes sense is "no" !!

So:
  Make lockd_up only increment  nlmsvc_users on success.
  Make nfsd handle errors from lockd_up properly.
  Make sure lockd_up(0) never fails when lockd is running
    so that the 'reclaimer' call to lockd_up doesn't need to
    be error checked.

Cc: "J. Bruce Fields" <bfields@fieldses.org>
Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
fs/lockd/clntlock.c
fs/lockd/svc.c
fs/nfsd/nfssvc.c