From: Ram Amrani Date: Tue, 24 Jan 2017 11:50:34 +0000 (+0200) Subject: RDMA/qedr: Return success when not changing QP state X-Git-Tag: MMI-PSA29.97-13-9~6244^2~16 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=865cea40b69741c3da2574176876463233b2b67c;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git RDMA/qedr: Return success when not changing QP state If the user is requesting us to change the QP state to the same state that it is already in, return success instead of failure. Signed-off-by: Ram Amrani Signed-off-by: Michal Kalderon Signed-off-by: Doug Ledford --- diff --git a/drivers/infiniband/hw/qedr/verbs.c b/drivers/infiniband/hw/qedr/verbs.c index 84dcd73bd57b..27d90a82d731 100644 --- a/drivers/infiniband/hw/qedr/verbs.c +++ b/drivers/infiniband/hw/qedr/verbs.c @@ -1657,7 +1657,7 @@ static int qedr_update_qp_state(struct qedr_dev *dev, int status = 0; if (new_state == qp->state) - return 1; + return 0; switch (qp->state) { case QED_ROCE_QP_STATE_RESET: