> If we change struct ibv_port_attr transport field from enum to uint8,
 > we eliminate binary compatibility problems. That's because the previous
 > filed is aligned to 16 bits address so that leaves us 16 bits more.
 > 
 > diff --git a/include/infiniband/verbs.h b/include/infiniband/verbs.h
 > index 07d4395..f7fe68d 100644
 > --- a/include/infiniband/verbs.h
 > +++ b/include/infiniband/verbs.h
 > @@ -192,7 +192,7 @@ struct ibv_port_attr {
 >         uint8_t                 active_width;
 >         uint8_t                 active_speed;
 >         uint8_t                 phys_state;
 > -       enum rdma_transport_type transport;
 > +       uint8_t                 transport;
 >  };

Do all architectures round up the structure size?  ie is this always
going to preserve ABI?

 > Moreover, I would like to change the field's name from transport to
 > link_protocl. Let me know if that makes more sense to you.

I was thinking the same thing, although maybe a name like "link_layer"
would be clearer?

 - R.
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to