mlx4: Non-xrc SRQs need an xrcd which will never be used by xrc
Subsystems (2)
PATCH 1/1 mlx4: Non-xrc SRQs need an xrcd which will never be used by xrc
Non-xrc SRQs should be created with a domain number which will never be assigned to an XRC TGT QP. This is so there is no possibility of such an SRQ inadvertently receiving an XRC transmission.
XRC Domain number allocations begin with (dev->dev->caps.reserved_xrcds + 1); Domain number (dev->dev->caps.reserved_xrcds) has been set aside to be used for this purpose.
---
Sean,
This was a little "glitch" that I noticed during my code review.
-Jack
drivers/infiniband/hw/mlx4/srq.c +3 -2
@@ -77,7 +77,7 @@ struct ib_srq *mlx4_ib_create_srq(struct ib_pd *pd,struct mlx4_wqe_srq_next_seg *next;struct mlx4_wqe_data_seg *scatter;u32 cqn; -u32 xrcdn; +u16 xrcdn;int desc_size;int buf_size;int err;
@@ -179,7 +179,8 @@ struct ib_srq *mlx4_ib_create_srq(struct ib_pd *pd, cqn = (init_attr->srq_type ==IB_SRQT_XRC ) ?to_mcq (init_attr->ext.xrc.cq)->mcq.cqn :0 ; xrcdn = (init_attr->srq_type ==IB_SRQT_XRC ) ? -to_mxrcd (init_attr->ext.xrc.xrcd)->xrcdn :0 ; +to_mxrcd (init_attr->ext.xrc.xrcd)->xrcdn : + (u16 ) dev->dev->caps.reserved_xrcds; err =mlx4_srq_alloc (dev->dev,to_mpd (pd)->pdn, cqn, xrcdn, &srq->mtt, srq->db.dma, &srq->msrq);if (err)
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 201106221533.41053.jackm-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org
Quoted 11 lines
Non-xrc SRQs should be created with a domain number which will never be assigned to an XRC TGT QP. This is so there is no possibility of such an SRQ
inadvertently receiving an XRC transmission.XRC Domain number allocations begin with (
dev->dev->caps.reserved_xrcds+ 1);
Domain number (dev->dev->caps.reserved_xrcds) has been set aside to be used
for this purpose.
Quoted 5 lines
Signed-off-by Jack Morgenstein <[email protected]---
Sean,
This was a little "glitch" that I noticed during my code review.
Thanks - If it's okay, I'll merge this change into the existing patches.
- Sean
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 1828884A29C6694DAF28B7E6B8A82373029A79-P5GAC/[email protected]
Quoted 4 lines · Sean
Sean,
Quoted 1 line
This was a little "glitch" that I noticed during my code review.
Thanks - If it's okay, I'll merge this change into the existing patches.
That's just fine!
-Jack
Quoted 2 lines
- Sean
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html