[ofa-general] [RFC PATCH 3/4] rdma/cma: add high availability mode attribute to IDs

Or Gerlitz or.gerlitz at gmail.com
Tue May 13 13:10:30 PDT 2008


On 5/13/08, Roland Dreier <rdreier at cisco.com> wrote:
>
> > +enum  rdma_ha_mode {
>   > +    RDMA_ALIGN_WITH_NETDEVICE = 1
>   > +};
>
>   > +int rdma_set_high_availability_mode(struct rdma_cm_id *id, enum
> rdma_ha_mode mode)
>
> this seems like overengineering to me... given there are no other modes,
> you are adding an elaborate NOP.  (Nothing looks at ha_mode)


First, this patch would be later extended for the rdma_ucm part (exposing
the ha_mode to user space). Second, indeed nothing looks on ha_mode in this
patch, but the next one (4/4) uses it. I was thinking its better to
decompose the changes this way such that patches are not too small and not
too big both in size and the change they carry in their content.

Do you have plans for other modes?


down the road someone might want to add APM support for the rdma-cm, or more
modes that I can't think of now.

  >      u8                      srq;
>   >      u8                      tos;
>   > +    enum rdma_ha_mode       ha_mode;
>
> Side note -- you're wasting two bytes here because of alignment.


What would be the easy way to avoid it?

Or.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openfabrics.org/pipermail/general/attachments/20080513/012450ee/attachment.html>


More information about the general mailing list