Message ID | 1532953230-79945-5-git-send-email-oulijun@huawei.com (mailing list archive) |
---|---|
State | Accepted |
Delegated to: | Jason Gunthorpe |
Headers | show |
Series | The follow up updates for hns | expand |
diff --git a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c index 763172c..12e7f3f 100644 --- a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c +++ b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c @@ -3445,6 +3445,7 @@ static int hns_roce_v2_modify_qp(struct ib_qp *ibqp, ; } else { dev_err(dev, "Illegal state for QP!\n"); + ret = -EINVAL; goto out; }
When qp type is illegal according to RoCE protocol, The verb of modify qp will directly return a errno. This patch fixes it. Signed-off-by: Lijun Ou <oulijun@huawei.com> --- V1 -> V2: - Fix the errno type --- drivers/infiniband/hw/hns/hns_roce_hw_v2.c | 1 + 1 file changed, 1 insertion(+)