]> git.baikalelectronics.ru Git - kernel.git/commit
dlm: fix missing check in validate_lock_args
authorAlexander Aring <aahringo@redhat.com>
Mon, 4 Apr 2022 20:06:29 +0000 (16:06 -0400)
committerDavid Teigland <teigland@redhat.com>
Wed, 6 Apr 2022 19:01:49 +0000 (14:01 -0500)
commit4b66e4692ae0923d00026c7c7a13177a61cefdc9
treedeb640eb9afed2285c871e0aac02a118c414e461
parent8789d44f9eb0c0e62c99b28d0695b543e653df38
dlm: fix missing check in validate_lock_args

This patch adds a additional check if lkb->lkb_wait_count is non zero as
it is done in validate_unlock_args() to check if any operation is in
progress. While on it add a comment taken from validate_unlock_args() to
signal what the check is doing.

There might be no changes because if lkb->lkb_wait_type is non zero
implies that lkb->lkb_wait_count is non zero. However we should add the
check as it does validate_unlock_args().

Signed-off-by: Alexander Aring <aahringo@redhat.com>
Signed-off-by: David Teigland <teigland@redhat.com>
fs/dlm/lock.c