Quoting r. Caitlin Bestler <[EMAIL PROTECTED]>:
> 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.
You can even do:
struct ib_device {
struct ib_ops;
struct iw_ops;
}
To hide an extra structure from the user.
--
Michael S. Tsirkin
Staff Engineer, Mellanox Technologies
_______________________________________________
openib-general mailing list
[email protected]
http://openib.org/mailman/listinfo/openib-general
To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general