[ofw] [PATCH] hca/wv: set max inline data during QP creation

Leonid Keller leonid at mellanox.co.il
Tue May 12 06:25:24 PDT 2009


Applied in 2166, thank you. 

> -----Original Message-----
> From: ofw-bounces at lists.openfabrics.org 
> [mailto:ofw-bounces at lists.openfabrics.org] On Behalf Of Sean Hefty
> Sent: Saturday, May 09, 2009 1:00 AM
> To: ofw at lists.openfabrics.org
> Subject: [ofw] [PATCH] hca/wv: set max inline data during QP creation
> 
> Pass through the user's specified max inline data value when 
> creating a QP.
> Currently, if the user specifies a value, it gets ignored 
> when the QP is created.  The inline data value supported is 
> then returned to the user, which may be less than requested.
> 
> This fixes a failure running dtest over mthca adapters.  Mlx4 
> adapters end up working for userspace apps because the 
> max_inline_data is passed from the UVP to the kernel via the 
> UMV buffer.  However, for completeness, fixup kernel calls 
> for QP creation from IBAL for mlx4.
> 
> Signed-off-by: Sean Hefty <sean.hefty at intel.com>
> ---
> It looks like all existing calls to create QPs through IBAL 
> zero the QP creation attributes, so max_inline_data appears 
> to always be initialized.
> 
> Index: hw/mlx4/kernel/hca/qp.c
> ===================================================================
> --- hw/mlx4/kernel/hca/qp.c	(revision 2100)
> +++ hw/mlx4/kernel/hca/qp.c	(working copy)
> @@ -135,7 +135,7 @@
>  		qp_init_attr.cap.max_send_sge = p_create_attr->sq_sge;
>  		qp_init_attr.cap.max_recv_wr = p_create_attr->rq_depth;
>  		qp_init_attr.cap.max_send_wr = p_create_attr->sq_depth;
> -		qp_init_attr.cap.max_inline_data = 0;	/* 
> absent in IBAL */
> +		qp_init_attr.cap.max_inline_data = 
> p_create_attr->sq_max_inline;
>  	}
>  	qp_init_attr.sq_sig_type = (p_create_attr->sq_signaled) ?
> IB_SIGNAL_ALL_WR : IB_SIGNAL_REQ_WR;
>  	qp_init_attr.qp_type = to_qp_type(p_create_attr->qp_type);
> Index: hw/mthca/kernel/hca_verbs.c
> ===================================================================
> --- hw/mthca/kernel/hca_verbs.c	(revision 2100)
> +++ hw/mthca/kernel/hca_verbs.c	(working copy)
> @@ -1050,6 +1050,7 @@
>  	qp_init_attr.recv_cq = (struct ib_cq *)p_create_attr->h_rq_cq;
>  	qp_init_attr.send_cq = (struct ib_cq *)p_create_attr->h_sq_cq;
>  	qp_init_attr.srq = (struct ib_srq *)p_create_attr->h_srq;
> +	qp_init_attr.cap.max_inline_data = p_create_attr->sq_max_inline;
>  	qp_init_attr.cap.max_recv_sge = p_create_attr->rq_sge;
>  	qp_init_attr.cap.max_send_sge = p_create_attr->sq_sge;
>  	qp_init_attr.cap.max_recv_wr = p_create_attr->rq_depth;
> Index: core/winverbs/kernel/wv_qp.c
> ===================================================================
> --- core/winverbs/kernel/wv_qp.c	(revision 2100)
> +++ core/winverbs/kernel/wv_qp.c	(working copy)
> @@ -47,6 +47,7 @@
>  	pVerbsAttr->h_srq = (pQp->pSrq != NULL) ? 
> pQp->pSrq->hVerbsSrq : NULL;
>  
>  	pVerbsAttr->qp_type = (ib_qp_type_t) pAttr->QpType;
> +	pVerbsAttr->sq_max_inline = pAttr->MaxInlineSend;
>  	pVerbsAttr->sq_depth = pAttr->SendDepth;
>  	pVerbsAttr->rq_depth = pAttr->ReceiveDepth;
>  	pVerbsAttr->sq_sge = pAttr->SendSge;
> 
> _______________________________________________
> ofw mailing list
> ofw at lists.openfabrics.org
> http://lists.openfabrics.org/cgi-bin/mailman/listinfo/ofw
> 



More information about the ofw mailing list