[ofa-general] RE: [PATCH 1/1 v2] librdmacm: add support for create qp expanded (with changelog this time)

Ron Livne ronli.voltaire at gmail.com
Sun Aug 3 04:27:04 PDT 2008


>+        qp = create_flags ?
>+               ibv_create_qp_expanded(pd, qp_init_attr, create_flags) :
>+               ibv_create_qp(pd, qp_init_attr);

What if the user wants to call rdma_create_qp_expanded with create_flags = 0,
with intension that ibv_create_qp_expanded will be called with create_flags = 0.
I know There's a pretty slim chance anyone would want to do so,
because it does the same thing.
But still...

Ron

On Sun, Aug 3, 2008 at 2:17 PM, Jack Morgenstein
<jackm at dev.mellanox.co.il> wrote:
> On Sunday 03 August 2008 13:36, Ron Livne wrote:
>> If I'll eliminate the expanded parameter,
>> I'll have to call ibv_create_qp_expanded with create_flags = 0.
>> This is not a good idea because it will not be compatible with an older
>> kernel.
>>
> Not so.
>
> In rdma_create_qp_common, just change:
> +        qp = expanded ?
> +               ibv_create_qp_expanded(pd, qp_init_attr, create_flags) :
> +               ibv_create_qp(pd, qp_init_attr);
>
> to
> +        qp = create_flags ?
> +               ibv_create_qp_expanded(pd, qp_init_attr, create_flags) :
> +               ibv_create_qp(pd, qp_init_attr);
>
> (i.e., just use the old ibv_create_qp if there are no create_flags set).
>
> - Jack
> _______________________________________________
> general mailing list
> general at lists.openfabrics.org
> http://lists.openfabrics.org/cgi-bin/mailman/listinfo/general
>
> To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general
>



More information about the general mailing list