alistair23-linux/fs/lockd
Chuck Lever c8c23c423d NSM: Release nsmhandle in nlm_destroy_host
The nsm_handle's reference count is bumped in nlm_lookup_host().  It
should be decremented in nlm_destroy_host() to make it easier to see
the balance of these two operations.

Move the nsm_release() call to fs/lockd/host.c.

The h_nsmhandle pointer is set in nlm_lookup_host(), and never cleared.
The nlm_destroy_host() function is never called for the same nlm_host
twice, so h_nsmhandle won't ever be NULL when nsm_unmonitor() is
called.

All references to the nlm_host are gone before it is freed.  We can
skip making h_nsmhandle NULL just before the nlm_host is deallocated.

It's also likely we can remove the h_nsmhandle NULL check in
nlmsvc_is_client() as well, but we can do that later when rearchitect-
ing the nlm_host cache.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
2009-01-06 11:53:52 -05:00
..
clntlock.c NLM: allow lockd requests from an unprivileged port 2008-12-23 15:21:38 -05:00
clntproc.c NLM: Remove redundant printk() in nlmclnt_lock() 2009-01-06 11:53:51 -05:00
grace.c nfsd: common grace period control 2008-10-03 16:19:02 -04:00
host.c NSM: Release nsmhandle in nlm_destroy_host 2009-01-06 11:53:52 -05:00
Makefile nfsd: common grace period control 2008-10-03 16:19:02 -04:00
mon.c NSM: Release nsmhandle in nlm_destroy_host 2009-01-06 11:53:52 -05:00
svc.c lockd: set svc_serv->sv_maxconn to a more reasonable value (try #3) 2009-01-06 11:53:48 -05:00
svc4proc.c NLM: Set address family before calling nlm_host_rebooted() 2008-10-30 17:19:30 -04:00
svclock.c lockd: reject reclaims outside the grace period 2008-10-03 16:19:20 -04:00
svcproc.c NLM: Set address family before calling nlm_host_rebooted() 2008-10-30 17:19:30 -04:00
svcshare.c
svcsubs.c lockd: Teach nlm_cmp_addr() to support AF_INET6 addresses 2008-09-29 18:13:39 -04:00
xdr.c lockd: Remove unused fields in the nlm_reboot structure 2008-10-03 17:02:35 -04:00
xdr4.c lockd: Remove unused fields in the nlm_reboot structure 2008-10-03 17:02:35 -04:00