[Ocfs2-commits] smushran commits r2969 - branches/ocfs2-1.2/fs/ocfs2/dlm

svn-commits at oss.oracle.com svn-commits at oss.oracle.com
Mon Jan 29 14:06:55 PST 2007


Author: smushran
Date: 2007-01-29 14:06:54 -0800 (Mon, 29 Jan 2007)
New Revision: 2969

Modified:
   branches/ocfs2-1.2/fs/ocfs2/dlm/dlmdomain.c
   branches/ocfs2-1.2/fs/ocfs2/dlm/dlmmaster.c
Log:
ocfs2_dlm: Prevent cpu from spinning during umount

This is a temporary solution to prevent the umount thread for
eating cpu waiting for the dlm_thread to finsh purging all the
migrated/unused lockres'. The up coming patch will handle this
using wait queues.

Signed-off-by: mfasheh

Modified: branches/ocfs2-1.2/fs/ocfs2/dlm/dlmdomain.c
===================================================================
--- branches/ocfs2-1.2/fs/ocfs2/dlm/dlmdomain.c	2007-01-29 21:57:01 UTC (rev 2968)
+++ branches/ocfs2-1.2/fs/ocfs2/dlm/dlmdomain.c	2007-01-29 22:06:54 UTC (rev 2969)
@@ -606,6 +606,7 @@
 		dlm_kick_thread(dlm, NULL);
 
 		while (dlm_migrate_all_locks(dlm)) {
+			msleep(1000);
 			mlog(0, "%s: more migration to do\n", dlm->name);
 		}
 		dlm_mark_domain_leaving(dlm);

Modified: branches/ocfs2-1.2/fs/ocfs2/dlm/dlmmaster.c
===================================================================
--- branches/ocfs2-1.2/fs/ocfs2/dlm/dlmmaster.c	2007-01-29 21:57:01 UTC (rev 2968)
+++ branches/ocfs2-1.2/fs/ocfs2/dlm/dlmmaster.c	2007-01-29 22:06:54 UTC (rev 2969)
@@ -2728,6 +2728,7 @@
 			mlog(ML_ERROR, "%s:%.*s: this node is not master, "
 			     "trying to free this but locks remain\n",
 			     dlm->name, res->lockname.len, res->lockname.name);
+			dlm_print_one_lock_resource(res);
 		}
 		goto leave;
 	}




More information about the Ocfs2-commits mailing list