aboutsummaryrefslogtreecommitdiffstats
path: root/fs/dlm/lock.c
diff options
context:
space:
mode:
authorDavid Teigland <teigland@redhat.com>2006-09-08 09:36:35 -0400
committerSteven Whitehouse <swhiteho@redhat.com>2006-09-08 17:00:12 -0400
commitfa9f0e4925c7796afd14bf7bbf7a064078818bbc (patch)
treeeaa690bf742fafef333b11b50c5aed6468e7f891 /fs/dlm/lock.c
parent37b2fa6a24f996d751dc80fbc8a77602cead269b (diff)
[DLM] confirm master for recovered waiting requests
Fixing the following scenario: - A request is on the waiters list waiting for a reply from a remote node. - The request is the first one on the resource, so first_lkid is set. - The remote node fails causing recovery. - During recovery the requesting node becomes master. - The request is now processed locally instead of being a remote operation. - At this point we need to call confirm_master() on the resource since we're certain we're now the master node. This will clear first_lkid. - We weren't calling confirm_master(), so first_lkid was not being cleared causing subsequent requests on that resource to get stuck. Signed-off-by: David Teigland <teigland@redhat.com> Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
Diffstat (limited to 'fs/dlm/lock.c')
-rw-r--r--fs/dlm/lock.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/dlm/lock.c b/fs/dlm/lock.c
index 67247f0b508a..af2f2f01bd5f 100644
--- a/fs/dlm/lock.c
+++ b/fs/dlm/lock.c
@@ -3283,6 +3283,8 @@ int dlm_recover_waiters_post(struct dlm_ls *ls)
3283 hold_rsb(r); 3283 hold_rsb(r);
3284 lock_rsb(r); 3284 lock_rsb(r);
3285 _request_lock(r, lkb); 3285 _request_lock(r, lkb);
3286 if (is_master(r))
3287 confirm_master(r, 0);
3286 unlock_rsb(r); 3288 unlock_rsb(r);
3287 put_rsb(r); 3289 put_rsb(r);
3288 break; 3290 break;