Skip to content

Commit 61b717d

Browse files
KAGA-KOKOjgunthorpe
authored andcommitted
RDMA/rxe: Set wqe->status correctly if an unexpected response is received
Every function that returns COMPST_ERROR must set wqe->status to another value than IB_WC_SUCCESS before returning COMPST_ERROR. Fix the only code path for which this is not yet the case. Signed-off-by: Bart Van Assche <[email protected]> Cc: <[email protected]> Reviewed-by: Yuval Shaia <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
1 parent 2e51e45 commit 61b717d

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/infiniband/sw/rxe/rxe_comp.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -276,6 +276,7 @@ static inline enum comp_state check_ack(struct rxe_qp *qp,
276276
case IB_OPCODE_RC_RDMA_READ_RESPONSE_MIDDLE:
277277
if (wqe->wr.opcode != IB_WR_RDMA_READ &&
278278
wqe->wr.opcode != IB_WR_RDMA_READ_WITH_INV) {
279+
wqe->status = IB_WC_FATAL_ERR;
279280
return COMPST_ERROR;
280281
}
281282
reset_retry_counters(qp);

0 commit comments

Comments
 (0)