Skip to content

Commit e717f2e

Browse files
Alexander Aringteigland
authored andcommitted
fs: dlm: add missing spin_unlock
This patch fixes commit dc52cd2 ("fs: dlm: fix F_CANCELLK to cancel pending request") that we don't unlock the ops_lock in a rate case when a waiter cannot be found. This case can only happen when cancellation of plock operation was successful but no kernel waiter was being found. Fixes: dc52cd2 ("fs: dlm: fix F_CANCELLK to cancel pending request") Signed-off-by: Alexander Aring <[email protected]> Signed-off-by: David Teigland <[email protected]>
1 parent dc52cd2 commit e717f2e

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

fs/dlm/plock.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -398,6 +398,7 @@ int dlm_posix_cancel(dlm_lockspace_t *lockspace, u64 number, struct file *file,
398398
*/
399399
op = plock_lookup_waiter(&info);
400400
if (WARN_ON_ONCE(!op)) {
401+
spin_unlock(&ops_lock);
401402
rv = -ENOLCK;
402403
break;
403404
}

0 commit comments

Comments
 (0)