Whamcloud - gitweb
LU-5116 ptlrpc: race at req processing 62/10562/2
authorAlexander.Boyko <alexander_boyko@xyratex.com>
Wed, 28 May 2014 17:52:13 +0000 (21:52 +0400)
committerOleg Drokin <oleg.drokin@intel.com>
Wed, 11 Jun 2014 19:42:59 +0000 (19:42 +0000)
commitdeb4e43a1a10c31fe8fc1f26840e59a82b35d394
tree64ae23d1fe7100b195baea43d47706d21323bd7c
parenteb39d82ae13ddb6010065cede13dca11f1da6aaf
LU-5116 ptlrpc: race at req processing

Race between ptlrpc_resend_req() and ptlrpc_check_set().
1 thread do ptlrpc_check_set()->after_reply()
2 thread do ptlrpc_resend_req()
The result is request with rq_resend = 1 and MSG_REPLY flag.
When this request will came to server it will cause client eviction.
The patch skip ptlrpc_resend_req logic if rq_replied is set,
and clear rq_resend flag at reply_in_callback() when client got
reply.

Signed-off-by: Alexander Boyko <alexander_boyko@xyratex.com>
Xyratex-bug-id: MRP-1888
Change-Id: If47b9a1f559ab16e4b416332ada7c73a8758d46c
Reviewed-on: http://review.whamcloud.com/10471
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Chris Horn <hornc@cray.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/10562
Reviewed-by: James Nunez <james.a.nunez@intel.com>
lustre/ptlrpc/client.c
lustre/ptlrpc/events.c
lustre/ptlrpc/niobuf.c