aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ocfs2/dlm/dlmast.c
diff options
context:
space:
mode:
authorMark Fasheh <mark.fasheh@oracle.com>2006-04-27 22:07:45 -0400
committerMark Fasheh <mark.fasheh@oracle.com>2006-06-26 17:42:55 -0400
commitc0a8520c7333dd62624683772f31864c7f9c46d9 (patch)
tree104c77f335821202518dcfb22ba76e7736e55187 /fs/ocfs2/dlm/dlmast.c
parentaa85235427992b8d3040297d9174d69dd1d8a675 (diff)
ocfs2: do LVB puts in place
Don't wait until the AST will be fired to do the LVB copy into the lock resource. Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
Diffstat (limited to 'fs/ocfs2/dlm/dlmast.c')
-rw-r--r--fs/ocfs2/dlm/dlmast.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/fs/ocfs2/dlm/dlmast.c b/fs/ocfs2/dlm/dlmast.c
index 87ee29cad50b..42775e2bbe2c 100644
--- a/fs/ocfs2/dlm/dlmast.c
+++ b/fs/ocfs2/dlm/dlmast.c
@@ -197,12 +197,14 @@ static void dlm_update_lvb(struct dlm_ctxt *dlm, struct dlm_lock_resource *res,
197 lock->ml.node == dlm->node_num ? "master" : 197 lock->ml.node == dlm->node_num ? "master" :
198 "remote"); 198 "remote");
199 memcpy(lksb->lvb, res->lvb, DLM_LVB_LEN); 199 memcpy(lksb->lvb, res->lvb, DLM_LVB_LEN);
200 } else if (lksb->flags & DLM_LKSB_PUT_LVB) {
201 mlog(0, "setting lvb from lockres for %s node\n",
202 lock->ml.node == dlm->node_num ? "master" :
203 "remote");
204 memcpy(res->lvb, lksb->lvb, DLM_LVB_LEN);
205 } 200 }
201 /* Do nothing for lvb put requests - they should be done in
202 * place when the lock is downconverted - otherwise we risk
203 * racing gets and puts which could result in old lvb data
204 * being propagated. We leave the put flag set and clear it
205 * here. In the future we might want to clear it at the time
206 * the put is actually done.
207 */
206 spin_unlock(&res->spinlock); 208 spin_unlock(&res->spinlock);
207 } 209 }
208 210