From: Li Dongyang Date: Wed, 3 Jun 2015 06:32:40 +0000 (+1000) Subject: LU-6679 ldlm: do not send blocking ast for group locks X-Git-Tag: 2.7.57~11 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=3016d3eba34f1718278e40d16d1e7e62e7c7abfa;p=fs%2Flustre-release.git LU-6679 ldlm: do not send blocking ast for group locks Group locks are acquired and released manually on client so it doesn't make sense to send blocking AST to client when there is an incompatible lock enqueued. Currently client will set CBPENDING on the group lock when it receives a blocking AST. Having the CBPENDING flag set will make ldlm_lock_match to fail and there will be two group locks granted on the same resource on the client. Signed-off-by: Li Dongyang Change-Id: I7af89e957528b3ed9771d86243ac8271084ee81f Reviewed-on: http://review.whamcloud.com/15119 Tested-by: Jenkins Tested-by: Maloo Reviewed-by: Jinshan Xiong Reviewed-by: John L. Hammond Reviewed-by: Oleg Drokin --- diff --git a/lustre/ldlm/ldlm_extent.c b/lustre/ldlm/ldlm_extent.c index 523c294..cf5d7a9 100644 --- a/lustre/ldlm/ldlm_extent.c +++ b/lustre/ldlm/ldlm_extent.c @@ -339,7 +339,8 @@ static enum interval_iter ldlm_extent_compat_cb(struct interval_node *n, ldlm_lockname[mode], ldlm_lockname[lock->l_granted_mode]); count++; - if (lock->l_blocking_ast) + if (lock->l_blocking_ast && + lock->l_granted_mode != LCK_GROUP) ldlm_add_ast_work_item(lock, enq, work_list); } @@ -608,7 +609,8 @@ ldlm_extent_compat_queue(struct list_head *queue, struct ldlm_lock *req, *contended_locks += check_contention; compat = 0; - if (lock->l_blocking_ast) + if (lock->l_blocking_ast && + lock->l_req_mode != LCK_GROUP) ldlm_add_ast_work_item(lock, req, work_list); } }