[ofw] Re: [ofa-general] ib_create_qp and ib_get_err_str weirdness

Diego Guella diego.guella at sircomtech.com
Tue Feb 24 01:54:38 PST 2009


Hi Dotan,
thanks for your answers.
Please see below


----- Original Message ----- 
From: "Dotan Barak"
> Hi.
>
> Diego Guella wrote:
>> Hello,
>>
>> I am using Mellanox WinOF 2.0.0 with a MHES14-XTC SDR single-port card.
>> I noticed a strange behavior of ib_create_qp function:
>>
>> -----
>> memset(&qp_create, 0, sizeof(qp_create));
>> qp_create.qp_type = IB_QPT_RELIABLE_CONN; // Reliable Connected
>> qp_create.sq_depth = ctx->qdepth;
>> qp_create.rq_depth = ctx->qdepth;
>> qp_create.sq_sge = ctx->hca_attr->max_sges;
>> qp_create.rq_sge = ctx->hca_attr->max_sges;
>> qp_create.h_sq_cq = ctx->cq_h;
>> qp_create.h_rq_cq = ctx->cq_h;
>> qp_create.h_srq = NULL;
>> qp_create.sq_signaled = 1;
>> ctx->qp_h = 0;
>> rc = ib_create_qp(ctx->pd_h, &qp_create, NULL, NULL, &ctx->qp_h);
>> -----
>> return value ("rc") is 3 (=IB_INVALID_PARAMETER).
>>
>> I spent some time figuring out the problem was the SQ SGE value:
>> http://lists.openfabrics.org/pipermail/general/2006-June/023417.html
>>
>> According to iba/ib_al.h:
>> -----
>> * IB_INVALID_MAX_SGE
>> * The requested maximum number of scatter-gather entries for the send or
>> * receive queue could not be supported.
>> -----
>> so, why the return value isn't 22 (=IB_INVALID_MAX_SGE)?

Having the right error code returned can help to distinguish between wrong arguments or a too high value for max_sge, and take 
appropriate measures.
Should I signal a bug for this? (wrong error code)
If so, how can I do that?



Thanks,
Diego




More information about the ofw mailing list