[openib-general] [PATCH] remove modifying port number on special QPs
Sean Hefty
mshefty at ichips.intel.com
Fri Sep 24 10:53:04 PDT 2004
Index: access/ib_mad.c
===================================================================
--- access/ib_mad.c (revision 880)
+++ access/ib_mad.c (working copy)
@@ -1068,7 +1068,7 @@
/*
* Modify QP into Init state
*/
-static inline int ib_mad_change_qp_state_to_init(struct ib_qp *qp, int port_num)
+static inline int ib_mad_change_qp_state_to_init(struct ib_qp *qp)
{
int ret;
struct ib_qp_attr *attr = NULL;
@@ -1087,13 +1087,12 @@
* one is needed for the Reset to Init transition.
*/
attr->pkey_index = 0;
- attr->port_num = port_num;
/* QKey is 0 for QP0 */
if (qp->qp_num == 0)
attr->qkey = 0;
else
attr->qkey = IB_QP1_QKEY;
- attr_mask = IB_QP_STATE | IB_QP_PKEY_INDEX | IB_QP_PORT | IB_QP_QKEY;
+ attr_mask = IB_QP_STATE | IB_QP_PKEY_INDEX | IB_QP_QKEY;
ret = ib_modify_qp(qp, attr, attr_mask, &qp_cap);
kfree(attr);
@@ -1189,8 +1188,7 @@
int ret, i, ret2;
for (i = 0; i < IB_MAD_QPS_CORE; i++) {
- ret = ib_mad_change_qp_state_to_init(port_priv->qp[i],
- port_priv->port_num);
+ ret = ib_mad_change_qp_state_to_init(port_priv->qp[i]);
if (ret) {
printk(KERN_ERR "Could not change QP%d state to INIT\n", i);
return ret;
--
More information about the general
mailing list