From 55e063d2a153d713ced7c581d0ebf14c330a3e6b Mon Sep 17 00:00:00 2001 From: Zach Brown Date: Wed, 2 May 2018 09:20:42 -0700 Subject: [PATCH] scoutfs: get rid of silly lock destroy BUG_ON The BUG_ON() at the start of scoutfs_lock_destroy() was intended to ensure that scoutfs_lock_shutdown() had been called first. But that doesn't happen in the case where we get an error during mount. The _destroy() function is careful to notice active use and only tears down resources that were created. The BUG_ON() can just be removed. Signed-off-by: Zach Brown --- kmod/src/lock.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/kmod/src/lock.c b/kmod/src/lock.c index c6545c19..f9935c56 100644 --- a/kmod/src/lock.c +++ b/kmod/src/lock.c @@ -1402,8 +1402,6 @@ void scoutfs_lock_destroy(struct super_block *sb) if (!linfo) return; - BUG_ON(!linfo->shutdown); - trace_scoutfs_lock_destroy(sb, linfo); /* stop the shrinker from queueing work */