[Ocfs2-commits] khackel commits r2753 - branches/ocfs2-1.2/fs/ocfs2/dlm

svn-commits@oss.oracle.com svn-commits at oss.oracle.com
Wed Jan 18 19:06:24 CST 2006


Author: khackel
Signed-off-by: khackel
Signed-off-by: mfasheh
Date: 2006-01-18 19:06:16 -0600 (Wed, 18 Jan 2006)
New Revision: 2753

Modified:
   branches/ocfs2-1.2/fs/ocfs2/dlm/dlmlock.c
Log:
* fix a hang in recovery that occurred in dlmlock_remote.  the $RECOVERY lock
  was never moved to the granted queue even after getting DLM_NORMAL back from
  the master node.

Signed-off-by: khackel
Signed-off-by: mfasheh



Modified: branches/ocfs2-1.2/fs/ocfs2/dlm/dlmlock.c
===================================================================
--- branches/ocfs2-1.2/fs/ocfs2/dlm/dlmlock.c	2006-01-19 01:05:22 UTC (rev 2752)
+++ branches/ocfs2-1.2/fs/ocfs2/dlm/dlmlock.c	2006-01-19 01:06:16 UTC (rev 2753)
@@ -219,6 +219,17 @@
 			dlm_error(status);
 		dlm_revert_pending_lock(res, lock);
 		dlm_lock_put(lock);
+	} else if (dlm_is_recovery_lock(res->lockname.name, 
+					res->lockname.len)) {
+		/* special case for the $RECOVERY lock.
+		 * there will never be an AST delivered to put
+		 * this lock on the proper secondary queue
+		 * (granted), so do it manually. */
+		mlog(0, "%s: $RECOVERY lock for this node (%u) is "
+		     "mastered by %u; got lock, manually granting (no ast)\n",
+		     dlm->name, dlm->node_num, res->owner);
+		list_del_init(&lock->list);
+		list_add_tail(&lock->list, &res->granted);
 	}
 	spin_unlock(&res->spinlock);
 



More information about the Ocfs2-commits mailing list