Skip to content

Commit

Permalink
RDMA/rtrs-clt: Missing error from rtrs_rdma_conn_established
Browse files Browse the repository at this point in the history
When rtrs_rdma_conn_established returns error (non-zero value), the error
value is stored in con->cm_err and it cannot trigger
rtrs_rdma_error_recovery. Finally the error of rtrs_rdma_con_established
will be forgot.

Fixes: 6a98d71 ("RDMA/rtrs: client: main functionality")
Link: https://lore.kernel.org/r/20201023074353.21946-5-jinpu.wang@cloud.ionos.com
Signed-off-by: Gioh Kim <gi-oh.kim@cloud.ionos.com>
Signed-off-by: Jack Wang <jinpu.wang@cloud.ionos.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
  • Loading branch information
Gioh Kim authored and jgunthorpe committed Oct 28, 2020
1 parent fcf2959 commit f553e76
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/infiniband/ulp/rtrs/rtrs-clt.c
Original file line number Diff line number Diff line change
Expand Up @@ -1831,8 +1831,8 @@ static int rtrs_clt_rdma_cm_handler(struct rdma_cm_id *cm_id,
cm_err = rtrs_rdma_route_resolved(con);
break;
case RDMA_CM_EVENT_ESTABLISHED:
con->cm_err = rtrs_rdma_conn_established(con, ev);
if (likely(!con->cm_err)) {
cm_err = rtrs_rdma_conn_established(con, ev);
if (likely(!cm_err)) {
/*
* Report success and wake up. Here we abuse state_wq,
* i.e. wake up without state change, but we set cm_err.
Expand Down

0 comments on commit f553e76

Please sign in to comment.