Commit 05f3a9af authored by Chuck Lever's avatar Chuck Lever Committed by J. Bruce Fields

NSM: Remove !nsm check from nsm_release()

The nsm_release() function should never be called with a NULL handle
point.  If it is, that's a bug.
Signed-off-by: default avatarChuck Lever <chuck.lever@oracle.com>
Signed-off-by: default avatarJ. Bruce Fields <bfields@citi.umich.edu>
parent bc1cc6c4
...@@ -288,8 +288,6 @@ found: ...@@ -288,8 +288,6 @@ found:
*/ */
void nsm_release(struct nsm_handle *nsm) void nsm_release(struct nsm_handle *nsm)
{ {
if (!nsm)
return;
if (atomic_dec_and_lock(&nsm->sm_count, &nsm_lock)) { if (atomic_dec_and_lock(&nsm->sm_count, &nsm_lock)) {
list_del(&nsm->sm_link); list_del(&nsm->sm_link);
spin_unlock(&nsm_lock); spin_unlock(&nsm_lock);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment