Whamcloud - gitweb
LU-3333 ptlrpc: Protect request buffer changing
*_enlarge_reqbuf class of functions can change request body location
for a request that's already in replay list, as such a parallel
traverser of the list (after_reply -> ptlrpc_free_committed) might
access freed and scrambled memory causing assertions.
Separate out the common code in ptlrpc_enlarge_req_buffer and
protect the buffer replacement by imp_lock since all users
that can get to this request must be holding this lock themselves
first.
Change-Id: I051d96196b44faafc15c58e0b2127856929f0ba7
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/6467
Tested-by: Jenkins
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Alexey Lyashkov <alexey_lyashkov@xyratex.com>