Message ID | 1532503781-45205-7-git-send-email-oulijun@huawei.com (mailing list archive) |
---|---|
State | Changes Requested |
Headers | show |
Series | Updates hns for v4.19 | expand |
On Wed, Jul 25, 2018 at 03:29:34PM +0800, Lijun Ou wrote: > When qp type is illegal according to RoCE protocol, The verb of modify > qp will direct return a errno. This patch fixes it. > > Signed-off-by: Lijun Ou <oulijun@huawei.com> > drivers/infiniband/hw/hns/hns_roce_hw_v2.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c > index a69bfc6..cb677f0 100644 > +++ b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c > @@ -3441,6 +3441,7 @@ static int hns_roce_v2_modify_qp(struct ib_qp *ibqp, > ; > } else { > dev_err(dev, "Illegal state for QP!\n"); > + ret = -EAGAIN; > goto out; Should this be EGAIN? What do other drivers do? I though this was EINVAL? Jason -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c index a69bfc6..cb677f0 100644 --- a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c +++ b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c @@ -3441,6 +3441,7 @@ static int hns_roce_v2_modify_qp(struct ib_qp *ibqp, ; } else { dev_err(dev, "Illegal state for QP!\n"); + ret = -EAGAIN; goto out; }
When qp type is illegal according to RoCE protocol, The verb of modify qp will direct return a errno. This patch fixes it. Signed-off-by: Lijun Ou <oulijun@huawei.com> --- drivers/infiniband/hw/hns/hns_roce_hw_v2.c | 1 + 1 file changed, 1 insertion(+)