From 81d64d4191b53b26e9a815cbb4030545518de4c1 Mon Sep 17 00:00:00 2001 From: ericm Date: Mon, 8 Mar 2004 06:32:06 +0000 Subject: [PATCH] update b_v26 from HEAD (20040308_1423) --- lustre/ldlm/ldlm_flock.c | 4 +++- lustre/ldlm/ldlm_plain.c | 2 ++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lustre/ldlm/ldlm_flock.c b/lustre/ldlm/ldlm_flock.c index 181c72e..148be59 100644 --- a/lustre/ldlm/ldlm_flock.c +++ b/lustre/ldlm/ldlm_flock.c @@ -150,6 +150,8 @@ ldlm_process_flock_lock(struct ldlm_lock *req, int *flags, int first_enq, } } } else { + lockmode_verify(mode); + /* This loop determines if there are existing locks * that conflict with the new lock request. */ list_for_each(tmp, &res->lr_granted) { @@ -164,7 +166,7 @@ ldlm_process_flock_lock(struct ldlm_lock *req, int *flags, int first_enq, /* locks are compatible, overlap doesn't matter */ if (lockmode_compat(lock->l_granted_mode, mode)) continue; - + if (!ldlm_flocks_overlap(lock, req)) continue; diff --git a/lustre/ldlm/ldlm_plain.c b/lustre/ldlm/ldlm_plain.c index 9b2af34..9a693e3 100644 --- a/lustre/ldlm/ldlm_plain.c +++ b/lustre/ldlm/ldlm_plain.c @@ -43,6 +43,8 @@ ldlm_plain_compat_queue(struct list_head *queue, struct ldlm_lock *req, int compat = 1; ENTRY; + lockmode_verify(req_mode); + list_for_each(tmp, queue) { lock = list_entry(tmp, struct ldlm_lock, l_res_link); -- 1.8.3.1