[openib-general] RE: Re: [PATCH] RFC Verbs: add support for transport specific verbs
Caitlin Bestler
caitlinb at broadcom.com
Tue Feb 28 14:40:28 PST 2006
Michael S. Tsirkin wrote:
> Quoting r. Caitlin Bestler <caitlinb at broadcom.com>:
>> The only trick is avoiding an extra layer of indirection for any
>> fastpath operations. So we may want to keep all fastpath operations
>> transport neutral, at least on a syntax basis, to avoid the extra
>> dereference. I'm not sure there are any, though.
>
> No, thats not the only way. You can just do
>
> struct ib_ops {
> process_local_mad;
> };
>
> struct iw_ops {
> llp_connect;
> };
>
> struct ib_device {
> struct ib_ops ib;
> struct iw_ops iw;
> }
>
> And there's no runtime overhead to this - its not an extra
> indirection.
>
That works, as long as we accept that all "struct transport_ops"
will be defined prior to this. That means that a change to
struct iw_ops will still trigger a make of InfiniBand specific
code. And (sizeof struct ib_device) will change. Since we
are talking years per new transport rather than new transports
per year this is probably acceptable.
More information about the general
mailing list