]> git.baikalelectronics.ru Git - kernel.git/commit
lockd: introduce lockd_put()
authorNeilBrown <neilb@suse.de>
Mon, 29 Nov 2021 04:51:25 +0000 (15:51 +1100)
committerChuck Lever <chuck.lever@oracle.com>
Mon, 13 Dec 2021 18:42:56 +0000 (13:42 -0500)
commite5a741dd01cd6bc841c8de148d61d349eea73983
tree2d260168238e0d3658de4e5ed43614332a9b6929
parent73f60e38d957c323729c8de5c5b292b0e7078364
lockd: introduce lockd_put()

There is some cleanup that is duplicated in lockd_down() and the failure
path of lockd_up().
Factor these out into a new lockd_put() and call it from both places.

lockd_put() does *not* take the mutex - that must be held by the caller.
It decrements nlmsvc_users and if that reaches zero, it cleans up.

Signed-off-by: NeilBrown <neilb@suse.de>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
fs/lockd/svc.c