Skip to contentSkip to conversation

dlm: add time stamp of blocking callback

PATCH New David Teigland 1 participant 1 message Dec 23, 2008 Distributed lock manager (DLM)

lore
Share & tools
lore

David Teigland

author maintainer
#0 lore raw

PATCH 8/10 dlm: add time stamp of blocking callback

Record the time the latest blocking callback was queued for a lock. This will be used for debugging in combination with lock queue timestamp changes in the previous patch.

---
 fs/dlm/dlm_internal.h |    1 +
 fs/dlm/lock.c         |    2 ++
 2 files changed, 3 insertions(+), 0 deletions(-)
fs/dlm/dlm_internal.h +1 -0
index e69135c..0c48829 100644
@@ -245,6 +245,7 @@ struct dlm_lkb {
 	struct list_head	lkb_astqueue;	/* need ast to be sent */
 	struct list_head	lkb_ownqueue;	/* list of locks for a process */
 	struct list_head	lkb_time_list;
+	ktime_t			lkb_time_bast;	/* for debugging */
 	ktime_t			lkb_timestamp;
 	unsigned long		lkb_timeout_cs;
 
fs/dlm/lock.c +2 -0
index dfc57ae..6cfe65b 100644
@@ -318,6 +318,8 @@ static inline void queue_cast_overlap(struct dlm_rsb *r, struct dlm_lkb *lkb)
 
 static void queue_bast(struct dlm_rsb *r, struct dlm_lkb *lkb, int rqmode)
 {
+	lkb->lkb_time_bast = ktime_get();
+
 	if (is_master_copy(lkb))
 		send_bast(r, lkb, rqmode);
 	else
Signature · 1 line
1.5.5.1