Whamcloud - gitweb
LU-6416 ldlm: no canceled lock on waiting list
If a lock was not granted straight away on server, but it's granted
with LDLM_FL_AST_SENT set before ldlm_handle_enqueue0 sends out
reply, client side will know she needs to cancel this lock.
At the meanwhile, this lock can be added to a long granting list
by another server thread.
When lock cancel request arrives at server and server calls into
ldlm_lock_cancel()->
ldlm_cancel_callback()->
tgt_blocking_ast(...LDLM_CB_CANCELING)->
tgt_sync()
The other server thread eventually get a chance to send completion
AST for this lock with LDLM_FL_AST_SENT set, and add this lock to
waiting list again.
However, tgt_sync may take arbitrary time which is irrelevant
to AT of lock revoke on client, server could evict client only
because itself has slow IO.
To resolve this race, this patch does not put canceled lock on
waiting list anymore.
Signed-off-by: Liang Zhen <liang.zhen@intel.com>
Change-Id: I86c1097d3ccbaa614b8811c1d9f37b39f019c61e
Reviewed-on: http://review.whamcloud.com/14085
Reviewed-by: Bobi Jam <bobijam@hotmail.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Jenkins
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>