aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/infiniband')
-rw-r--r--drivers/infiniband/hw/mthca/mthca_qp.c26
1 files changed, 0 insertions, 26 deletions
diff --git a/drivers/infiniband/hw/mthca/mthca_qp.c b/drivers/infiniband/hw/mthca/mthca_qp.c
index 3b1c5baf13b..77b52b3adcc 100644
--- a/drivers/infiniband/hw/mthca/mthca_qp.c
+++ b/drivers/infiniband/hw/mthca/mthca_qp.c
@@ -848,23 +848,6 @@ out:
848 return err; 848 return err;
849} 849}
850 850
851static const struct ib_qp_attr dummy_init_attr = { .port_num = 1 };
852static const int dummy_init_attr_mask[] = {
853 [IB_QPT_UD] = (IB_QP_PKEY_INDEX |
854 IB_QP_PORT |
855 IB_QP_QKEY),
856 [IB_QPT_UC] = (IB_QP_PKEY_INDEX |
857 IB_QP_PORT |
858 IB_QP_ACCESS_FLAGS),
859 [IB_QPT_RC] = (IB_QP_PKEY_INDEX |
860 IB_QP_PORT |
861 IB_QP_ACCESS_FLAGS),
862 [IB_QPT_SMI] = (IB_QP_PKEY_INDEX |
863 IB_QP_QKEY),
864 [IB_QPT_GSI] = (IB_QP_PKEY_INDEX |
865 IB_QP_QKEY),
866};
867
868int mthca_modify_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr, int attr_mask, 851int mthca_modify_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr, int attr_mask,
869 struct ib_udata *udata) 852 struct ib_udata *udata)
870{ 853{
@@ -926,15 +909,6 @@ int mthca_modify_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr, int attr_mask,
926 goto out; 909 goto out;
927 } 910 }
928 911
929 if (cur_state == IB_QPS_RESET && new_state == IB_QPS_ERR) {
930 err = __mthca_modify_qp(ibqp, &dummy_init_attr,
931 dummy_init_attr_mask[ibqp->qp_type],
932 IB_QPS_RESET, IB_QPS_INIT);
933 if (err)
934 goto out;
935 cur_state = IB_QPS_INIT;
936 }
937
938 err = __mthca_modify_qp(ibqp, attr, attr_mask, cur_state, new_state); 912 err = __mthca_modify_qp(ibqp, attr, attr_mask, cur_state, new_state);
939 913
940out: 914out: