These changes are the raw update to linux-4.4.6-rt14. Kernel sources
[kvmfornfv.git] / kernel / fs / ocfs2 / dlm / dlmthread.c
index 69aac6f..c5f6c24 100644 (file)
@@ -211,6 +211,16 @@ static void dlm_purge_lockres(struct dlm_ctxt *dlm,
 
        __dlm_unhash_lockres(dlm, res);
 
+       spin_lock(&dlm->track_lock);
+       if (!list_empty(&res->tracking))
+               list_del_init(&res->tracking);
+       else {
+               mlog(ML_ERROR, "Resource %.*s not on the Tracking list\n",
+                               res->lockname.len, res->lockname.name);
+               __dlm_print_one_lock_resource(res);
+       }
+       spin_unlock(&dlm->track_lock);
+
        /* lockres is not in the hash now.  drop the flag and wake up
         * any processes waiting in dlm_get_lock_resource. */
        if (!master) {
@@ -483,7 +493,8 @@ int dlm_launch_thread(struct dlm_ctxt *dlm)
 {
        mlog(0, "Starting dlm_thread...\n");
 
-       dlm->dlm_thread_task = kthread_run(dlm_thread, dlm, "dlm_thread");
+       dlm->dlm_thread_task = kthread_run(dlm_thread, dlm, "dlm-%s",
+                       dlm->name);
        if (IS_ERR(dlm->dlm_thread_task)) {
                mlog_errno(PTR_ERR(dlm->dlm_thread_task));
                dlm->dlm_thread_task = NULL;