[ewg] Re: [PATCH] rdmaoe/libibverbs: handle binary compatibility

Jason Gunthorpe jgunthorpe at obsidianresearch.com
Thu Dec 10 14:17:55 PST 2009


On Thu, Dec 10, 2009 at 01:57:11PM -0800, Roland Dreier wrote:

> Maybe I'm wrong but I don't like setting "don't know" magically to IB
> behind the scenes.

Well, it isn't just "don't know" it also means "the kernel doesn't
support the link_layer query". The kernels that don't support
link_layer also only support link_layer == IB for
IBV_TRANSPORT_IB. One proves the other..

So IBV_TRANSPORT_IB ports should always return
IBV_LINK_LAYER_INFINIBAND unless the kernel supports the new API and
says otherwise. You can still have IBV_LINK_LAYER_UNSPECIFIED, but it
can't be 0.

If this isn't done then again compatability with apps is compromised,
what should an app do when it sees IBV_LINK_LAYER_UNSPECIFIED due to
an older kernel and newer libibverbs?

> And there's no reason why iWARP has to run over ethernet in
> principle.

Right.. so existing kernels with the new library should return
IBV_LINK_LAYER_INFINIBAND for ports on IBV_TRANSPORT_IB devices and
IBV_LINK_LAYER_UNSPECIFIED for ports on everything else
(IBV_TRANSPORT_IWARP, IBV_TRANSPORT_UNKNOWN)

Jason



More information about the ewg mailing list