[openib-general] [PATCH] ib_mad: Implement ib_free_recv_mad routine
Hal Rosenstock
halr at voltaire.com
Wed Sep 15 14:42:05 PDT 2004
On Wed, 2004-09-15 at 17:33, Sean Hefty wrote:
> On Wed, 15 Sep 2004 17:03:48 -0400
> Hal Rosenstock <halr at voltaire.com> wrote:
>
> > > Would it make more sense for ib_mad_recv_wc to have an embedded
> > > recv_buf, rather than a a pointer to a recv_buf?
> > > Seems like a minor optimization/simplification.
> >
> > I think that optimization would only work short term. Once RMPP is
> > supported, it doesn't so I would leave the API as is.
>
> I think that the optimization works even with RMPP. Assuming that
> most receives are for a one MAD, it allocates a single structure,
> rather than two that then need to be chained together. For RMPP,
> you can still have more recv_buf's chained together. It's just
> that the first recv_buf is included with the mad_recv_wc,
> rather than being linked off of it.
OK. It is probably worth the extra memory to optimize for the single
buffer case.
-- Hal
More information about the general
mailing list