In ptlrpc_check_set, the bulk should be unregistered before
ptl_send_rpc in any case.
Lustre-change: https://review.whamcloud.com/22378
Lustre-commit:
e34a4cf031a2b83259cee8e05c2f646b5652b6a9
Change-Id: Icf963002f934b43ccbb9d6ef02ba7f9d11f297f8
Signed-off-by: Hongchao Zhang <hongchao@whamcloud.com>
Reviewed-on: https://review.whamcloud.com/33798
Tested-by: Jenkins
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
spin_lock(&req->rq_lock);
req->rq_resend = 1;
spin_unlock(&req->rq_lock);
spin_lock(&req->rq_lock);
req->rq_resend = 1;
spin_unlock(&req->rq_lock);
-
- if (req->rq_bulk != NULL &&
- !ptlrpc_unregister_bulk(req, 1))
- continue;
}
/*
* rq_wait_ctx is only touched by ptlrpcd,
}
/*
* rq_wait_ctx is only touched by ptlrpcd,
spin_unlock(&req->rq_lock);
}
spin_unlock(&req->rq_lock);
}
+ /* In any case, the previous bulk should be
+ * cleaned up to prepare for the new sending */
+ if (req->rq_bulk != NULL &&
+ !ptlrpc_unregister_bulk(req, 1))
+ continue;
+
rc = ptl_send_rpc(req, 0);
if (rc == -ENOMEM) {
spin_lock(&imp->imp_lock);
rc = ptl_send_rpc(req, 0);
if (rc == -ENOMEM) {
spin_lock(&imp->imp_lock);