Commit 17202c7c authored by Xin Zhao's avatar Xin Zhao
Browse files

Bug-fix: store lock entry pointer in request even data is dropped

When data is dropped but lock is queued, we should still store
the lock entry in current request, so that we can try to acquire
the lock when we received and dropped all data.

No reviewer.
parent a44c53d6
......@@ -424,6 +424,7 @@ static inline int enqueue_lock_origin(MPID_Win *win_ptr, MPIDI_VC_t *vc,
req->dev.recv_data_sz = recv_data_sz;
req->dev.OnDataAvail = MPIDI_CH3_ReqHandler_PiggybackLockOpRecvComplete;
req->dev.OnFinal = MPIDI_CH3_ReqHandler_PiggybackLockOpRecvComplete;
req->dev.lock_queue_entry = new_ptr;
MPIDI_CH3_PKT_RMA_GET_IMMED_LEN((*pkt), immed_len, mpi_errno);
if (immed_len > 0) {
......
......@@ -1463,8 +1463,7 @@ int MPIDI_CH3_ReqHandler_PiggybackLockOpRecvComplete( MPIDI_VC_t *vc,
/* Note that if we decided to drop op data, here we just need to complete this
request; otherwise we try to get the lock again in this handler. */
if (rreq->dev.drop_data == FALSE) {
MPIU_Assert(lock_queue_entry != NULL);
if (rreq->dev.lock_queue_entry != NULL) {
/* Mark all data received in lock queue entry */
lock_queue_entry->all_data_recved = 1;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment