resending an unlock request can caused an memory leak as new request
will allocated on resend. Lets finish a request before resend.
Fixes:
85a12c6c8d7 ("LU-12828 ldlm: FLOCK request can be processed twice")
Cray-bug-id: LUS-8447
Signed-off-by: Alexey Lyashkov <c17817@cray.com>
Change-Id: I15dfe0388d1305c8eb5be18b19b0ffc687454ef1
Reviewed-on: https://review.whamcloud.com/37670
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andriy Skulysh <c17819@cray.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Mike Pershin <mpershin@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
can not rely on caller and this mainly for F_UNLCKs
(explicits or automatically generated by Kernel to clean
current FLocks upon exit) that can't be trashed */
+ ptlrpc_req_finished(req);
if (((rc == -EINTR) || (rc == -ETIMEDOUT)) &&
(einfo->ei_type == LDLM_FLOCK) &&
(einfo->ei_mode == LCK_NL))
goto resend;
- ptlrpc_req_finished(req);
RETURN(rc);
}