From: David Teigland Date: Fri, 8 Sep 2006 13:36:35 +0000 (-0500) Subject: [DLM] confirm master for recovered waiting requests X-Git-Tag: v2.6.19-rc1~32^2~43 X-Git-Url: http://www.pilppa.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=fa9f0e4925c7796afd14bf7bbf7a064078818bbc;p=linux-2.6-omap-h63xx.git [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 Signed-off-by: Steven Whitehouse --- diff --git a/fs/dlm/lock.c b/fs/dlm/lock.c index 67247f0b508..af2f2f01bd5 100644 --- a/fs/dlm/lock.c +++ b/fs/dlm/lock.c @@ -3283,6 +3283,8 @@ int dlm_recover_waiters_post(struct dlm_ls *ls) hold_rsb(r); lock_rsb(r); _request_lock(r, lkb); + if (is_master(r)) + confirm_master(r, 0); unlock_rsb(r); put_rsb(r); break;