[openib-general] Re: FW: summary of my understanding on our common work on openib.org
Michael S. Tsirkin
mst at mellanox.co.il
Thu Feb 10 02:15:19 PST 2005
Quoting r. Tziporet Koren <tziporet at mellanox.co.il>:
> Subject: FW: summary of my understanding on our common work on openib.org
>
> please do it
>
> -----Original Message-----
> From: Roland Dreier [mailto:roland at topspin.com]
> Sent: Wednesday, February 09, 2005 9:00 AM
> To: Tziporet Koren
> Subject: Re: summary of my understanding on our common work on
> openib.org
>
>
> Tziporet> sure. Just one note - we are going to remove the
> Tziporet> IB_SIGNAL_REQ_WR for receive QP. I talked about it with
> Tziporet> Sean and he agree its OK since its something we added in
> Tziporet> Tavor which is not IB compliant and not going to support
> Tziporet> in Arbel. I asked Michael to prepare this patch so I
> Tziporet> hope it will be ready this week. Or - do you prefer to
> Tziporet> do it yourself?
>
> It would be great for Michael to prepare the patch.
>
> Thanks,
> Roland
Signed-off-by: Michael S. Tsirkin <mst at mellanox.co.il>
Index: ulp/ipoib/ipoib_verbs.c
===================================================================
--- ulp/ipoib/ipoib_verbs.c (revision 1759)
+++ ulp/ipoib/ipoib_verbs.c (working copy)
@@ -165,7 +165,6 @@ int ipoib_transport_dev_init(struct net_
.max_recv_sge = 1
},
.sq_sig_type = IB_SIGNAL_ALL_WR,
- .rq_sig_type = IB_SIGNAL_ALL_WR,
.qp_type = IB_QPT_UD
};
Index: ulp/ipoib/ipoib_ib.c
===================================================================
--- ulp/ipoib/ipoib_ib.c (revision 1759)
+++ ulp/ipoib/ipoib_ib.c (working copy)
@@ -105,7 +105,6 @@ static inline int ipoib_ib_receive(struc
.wr_id = wr_id | IPOIB_OP_RECV,
.sg_list = &list,
.num_sge = 1,
- .recv_flags = IB_RECV_SIGNALED
};
struct ib_recv_wr *bad_wr;
Index: include/ib_verbs.h
===================================================================
--- include/ib_verbs.h (revision 1759)
+++ include/ib_verbs.h (working copy)
@@ -73,7 +73,6 @@ enum ib_device_cap_flags {
IB_DEVICE_RC_RNR_NAK_GEN = (1<<12),
IB_DEVICE_SRQ_RESIZE = (1<<13),
IB_DEVICE_N_NOTIFY_CQ = (1<<14),
- IB_DEVICE_RQ_SIG_TYPE = (1<<15)
};
enum ib_atomic_cap {
@@ -408,7 +407,6 @@ struct ib_qp_init_attr {
struct ib_srq *srq;
struct ib_qp_cap cap;
enum ib_sig_type sq_sig_type;
- enum ib_sig_type rq_sig_type;
enum ib_qp_type qp_type;
u8 port_num; /* special QP types only */
};
@@ -533,10 +531,6 @@ enum ib_send_flags {
IB_SEND_INLINE = (1<<3)
};
-enum ib_recv_flags {
- IB_RECV_SIGNALED = 1
-};
-
struct ib_sge {
u64 addr;
u32 length;
@@ -579,7 +573,6 @@ struct ib_recv_wr {
u64 wr_id;
struct ib_sge *sg_list;
int num_sge;
- int recv_flags;
};
enum ib_access_flags {
Index: core/mad.c
===================================================================
--- core/mad.c (revision 1759)
+++ core/mad.c (working copy)
@@ -2186,7 +2186,6 @@ static int ib_mad_post_receive_mads(stru
recv_wr.next = NULL;
recv_wr.sg_list = &sg_list;
recv_wr.num_sge = 1;
- recv_wr.recv_flags = IB_RECV_SIGNALED;
do {
/* Allocate and map receive buffer */
@@ -2381,7 +2380,6 @@ static int create_mad_qp(struct ib_mad_q
qp_init_attr.send_cq = qp_info->port_priv->cq;
qp_init_attr.recv_cq = qp_info->port_priv->cq;
qp_init_attr.sq_sig_type = IB_SIGNAL_ALL_WR;
- qp_init_attr.rq_sig_type = IB_SIGNAL_ALL_WR;
qp_init_attr.cap.max_send_wr = IB_MAD_QP_SEND_SIZE;
qp_init_attr.cap.max_recv_wr = IB_MAD_QP_RECV_SIZE;
qp_init_attr.cap.max_send_sge = IB_MAD_SEND_REQ_MAX_SG;
Index: hw/mthca/mthca_dev.h
===================================================================
--- hw/mthca/mthca_dev.h (revision 1759)
+++ hw/mthca/mthca_dev.h (working copy)
@@ -369,14 +369,12 @@ int mthca_alloc_qp(struct mthca_dev *dev
struct mthca_cq *recv_cq,
enum ib_qp_type type,
enum ib_sig_type send_policy,
- enum ib_sig_type recv_policy,
struct mthca_qp *qp);
int mthca_alloc_sqp(struct mthca_dev *dev,
struct mthca_pd *pd,
struct mthca_cq *send_cq,
struct mthca_cq *recv_cq,
enum ib_sig_type send_policy,
- enum ib_sig_type recv_policy,
int qpn,
int port,
struct mthca_sqp *sqp);
Index: hw/mthca/mthca_provider.c
===================================================================
--- hw/mthca/mthca_provider.c (revision 1759)
+++ hw/mthca/mthca_provider.c (working copy)
@@ -343,7 +343,7 @@ static struct ib_qp *mthca_create_qp(str
to_mcq(init_attr->send_cq),
to_mcq(init_attr->recv_cq),
init_attr->qp_type, init_attr->sq_sig_type,
- init_attr->rq_sig_type, qp);
+ qp);
qp->ibqp.qp_num = qp->qpn;
break;
}
@@ -364,7 +364,7 @@ static struct ib_qp *mthca_create_qp(str
err = mthca_alloc_sqp(to_mdev(pd->device), to_mpd(pd),
to_mcq(init_attr->send_cq),
to_mcq(init_attr->recv_cq),
- init_attr->sq_sig_type, init_attr->rq_sig_type,
+ init_attr->sq_sig_type,
qp->ibqp.qp_num, init_attr->port_num,
to_msqp(qp));
break;
Index: hw/mthca/mthca_provider.h
===================================================================
--- hw/mthca/mthca_provider.h (revision 1759)
+++ hw/mthca/mthca_provider.h (working copy)
@@ -154,7 +154,6 @@ struct mthca_wq {
void *last;
int max_gs;
int wqe_shift;
- enum ib_sig_type policy;
};
struct mthca_qp {
@@ -172,6 +171,7 @@ struct mthca_qp {
struct mthca_wq rq;
struct mthca_wq sq;
+ enum ib_sig_type sq_policy;
int send_wqe_offset;
u64 *wrid;
Index: hw/mthca/mthca_qp.c
===================================================================
--- hw/mthca/mthca_qp.c (revision 1759)
+++ hw/mthca/mthca_qp.c (working copy)
@@ -690,7 +690,7 @@ int mthca_modify_qp(struct ib_qp *ibqp,
MTHCA_QP_BIT_SRE |
MTHCA_QP_BIT_SWE |
MTHCA_QP_BIT_SAE);
- if (qp->sq.policy == IB_SIGNAL_ALL_WR)
+ if (qp->sq_policy == IB_SIGNAL_ALL_WR)
qp_context->params1 |= cpu_to_be32(MTHCA_QP_BIT_SSC);
if (attr_mask & IB_QP_RETRY_CNT) {
qp_context->params1 |= cpu_to_be32(attr->retry_cnt << 16);
@@ -778,8 +778,8 @@ int mthca_modify_qp(struct ib_qp *ibqp,
qp->resp_depth = attr->max_rd_atomic;
}
- if (qp->rq.policy == IB_SIGNAL_ALL_WR)
- qp_context->params2 |= cpu_to_be32(MTHCA_QP_BIT_RSC);
+ qp_context->params2 |= cpu_to_be32(MTHCA_QP_BIT_RSC);
+
if (attr_mask & IB_QP_MIN_RNR_TIMER) {
qp_context->rnr_nextrecvpsn |= cpu_to_be32(attr->min_rnr_timer << 24);
qp_param->opt_param_mask |= cpu_to_be32(MTHCA_QP_OPTPAR_RNR_TIMEOUT);
@@ -977,7 +977,6 @@ static int mthca_alloc_qp_common(struct
struct mthca_cq *send_cq,
struct mthca_cq *recv_cq,
enum ib_sig_type send_policy,
- enum ib_sig_type recv_policy,
struct mthca_qp *qp)
{
int err;
@@ -987,8 +986,7 @@ static int mthca_alloc_qp_common(struct
qp->state = IB_QPS_RESET;
qp->atomic_rd_en = 0;
qp->resp_depth = 0;
- qp->sq.policy = send_policy;
- qp->rq.policy = recv_policy;
+ qp->sq_policy = send_policy;
qp->rq.cur = 0;
qp->sq.cur = 0;
qp->rq.next = 0;
@@ -1008,7 +1006,6 @@ int mthca_alloc_qp(struct mthca_dev *dev
struct mthca_cq *recv_cq,
enum ib_qp_type type,
enum ib_sig_type send_policy,
- enum ib_sig_type recv_policy,
struct mthca_qp *qp)
{
int err;
@@ -1025,7 +1022,7 @@ int mthca_alloc_qp(struct mthca_dev *dev
return -ENOMEM;
err = mthca_alloc_qp_common(dev, pd, send_cq, recv_cq,
- send_policy, recv_policy, qp);
+ send_policy, qp);
if (err) {
mthca_free(&dev->qp_table.alloc, qp->qpn);
return err;
@@ -1044,7 +1041,6 @@ int mthca_alloc_sqp(struct mthca_dev *de
struct mthca_cq *send_cq,
struct mthca_cq *recv_cq,
enum ib_sig_type send_policy,
- enum ib_sig_type recv_policy,
int qpn,
int port,
struct mthca_sqp *sqp)
@@ -1073,8 +1069,7 @@ int mthca_alloc_sqp(struct mthca_dev *de
sqp->qp.transport = MLX;
err = mthca_alloc_qp_common(dev, pd, send_cq, recv_cq,
- send_policy, recv_policy,
- &sqp->qp);
+ send_policy, &sqp->qp);
if (err)
goto err_out_free;
@@ -1495,9 +1490,7 @@ int mthca_post_receive(struct ib_qp *ibq
((struct mthca_next_seg *) wqe)->nda_op = 0;
((struct mthca_next_seg *) wqe)->ee_nds =
cpu_to_be32(MTHCA_NEXT_DBD);
- ((struct mthca_next_seg *) wqe)->flags =
- (wr->recv_flags & IB_RECV_SIGNALED) ?
- cpu_to_be32(MTHCA_NEXT_CQ_UPDATE) : 0;
+ ((struct mthca_next_seg *) wqe)->flags = 0;
wqe += sizeof (struct mthca_next_seg);
size = sizeof (struct mthca_next_seg) / 16;
--
MST - Michael S. Tsirkin
More information about the general
mailing list