From b698da0e43aa830000c44d13133d05da7c6b3da3 Mon Sep 17 00:00:00 2001 From: Wengang Wang Date: Thu, 3 Sep 2009 15:56:33 +0800 Subject: [PATCH] --- yaml --- r: 165143 b: refs/heads/master c: 83e32d9044a4510fffdf65c2691a25c0ba84e259 h: refs/heads/master i: 165141: b592a121d2051141526608550f932be111a36661 165139: a29691071c9587f5f603b5e46367bbbfcfd0d05e 165135: 76ede06978201ed0fc65a819a86998a2225783d4 v: v3 --- [refs] | 2 +- trunk/fs/ocfs2/dlm/dlmthread.c | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index e022f1235a16..c4a6786dca12 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: d92bc5127b27f315ef0ef2c1e1829fd6a5cba54a +refs/heads/master: 83e32d9044a4510fffdf65c2691a25c0ba84e259 diff --git a/trunk/fs/ocfs2/dlm/dlmthread.c b/trunk/fs/ocfs2/dlm/dlmthread.c index d490b66ad9d7..98569e86c613 100644 --- a/trunk/fs/ocfs2/dlm/dlmthread.c +++ b/trunk/fs/ocfs2/dlm/dlmthread.c @@ -212,14 +212,18 @@ static int dlm_purge_lockres(struct dlm_ctxt *dlm, spin_lock(&dlm->spinlock); } + spin_lock(&res->spinlock); if (!list_empty(&res->purge)) { mlog(0, "removing lockres %.*s:%p from purgelist, " "master = %d\n", res->lockname.len, res->lockname.name, res, master); list_del_init(&res->purge); + spin_unlock(&res->spinlock); dlm_lockres_put(res); dlm->purge_count--; - } + } else + spin_unlock(&res->spinlock); + __dlm_unhash_lockres(res); /* lockres is not in the hash now. drop the flag and wake up