projects
/
linux-block.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
43279e5
)
dlm: ignore cancel on granted lock
author
David Teigland
<teigland@redhat.com>
Fri, 27 Feb 2009 21:23:28 +0000
(15:23 -0600)
committer
David Teigland
<teigland@redhat.com>
Wed, 11 Mar 2009 17:23:58 +0000
(12:23 -0500)
Return immediately from dlm_unlock(CANCEL) if the lock is
granted and not being converted; there's nothing to cancel.
Signed-off-by: David Teigland <teigland@redhat.com>
fs/dlm/lock.c
patch
|
blob
|
blame
|
history
diff --git
a/fs/dlm/lock.c
b/fs/dlm/lock.c
index 8cb92046a5844c1a9f1148f5c1770c8aa7744ce2..205ec95b347e3001b6cb4358b8c6539802d95bed 100644
(file)
--- a/
fs/dlm/lock.c
+++ b/
fs/dlm/lock.c
@@
-2186,6
+2186,13
@@
static int validate_unlock_args(struct dlm_lkb *lkb, struct dlm_args *args)
goto out;
}
+ /* there's nothing to cancel */
+ if (lkb->lkb_status == DLM_LKSTS_GRANTED &&
+ !lkb->lkb_wait_type) {
+ rv = -EBUSY;
+ goto out;
+ }
+
switch (lkb->lkb_wait_type) {
case DLM_MSG_LOOKUP:
case DLM_MSG_REQUEST: