RE: [RFC PATCH 1/5] IB/core: Add Core Capability flags to ib_device

Hefty, Sean
2015-05-04T16:40:23Z

> > +/* Protocol 0xFFFF000000000000 */
> > +#define RDMA_CORE_CAP_PROT_IB 0x0001000000000000ULL
> > +#define RDMA_CORE_CAP_PROT_IBOE 0x0002000000000000ULL
> > +#define RDMA_CORE_CAP_PROT_IWARP 0x0004000000000000ULL
> > +#define RDMA_CORE_CAP_PROT_USNIC_UDP 0x0008000000000000ULL
>
> In accordance with what we've been talking about, drop IBOE for ROCE.
>
> Drop the UDP off of USNIC, then define a bit for CAP_PROT_UDP_ENCAP.
> USNIC will be just USNIC, USNIC_UDP will be USNIC | UDP_ENCAP, ROCE v1
> will be ROCE, and ROCEv2 will be ROCE | UDP_ENCAP.

USNIC_UDP is just UDP. I don't understand why we would want 'USNIC | UDP_ENCAP', or what UDP_ENCAP is intended to convey. Nothing is being encapsulated.

RoCEv2 is IB transport over UDP.

I'm not sure what the protocol field is intended to imply. If we want to expose the link, network, transport, and RDMA protocols in use, shouldn't these be separate fields or bits? And even then, I'm not sure what use this has for the ULPs. iWarp does not require Ethernet or TCP. RoCEv2 would work fine over any link. And the core layer should not assume that a device is limited to supporting only one protocol, especially at the network and transport levels. I vote for deprecating the protocol goofiness.

- Sean