[ofa-general] Re: A question about tx lock in ipoib_flush_paths
akepner at sgi.com
akepner at sgi.com
Fri Jul 10 09:08:50 PDT 2009
On Fri, Jul 10, 2009 at 02:27:56PM +0300, Yossi Etigin wrote:
> akepner at sgi.com wrote:
> > .....
> > If so, it would be addressed by the patch I sent here:
> >
> > http://lists.openfabrics.org/pipermail/general/2009-July/060501.html
> >
> > because the ipoib_neigh structure wouldn't be freed until after
> > ipoib_start_xmit() had done rcu_read_unlock().
> >
>
> Yes, I guess it would address the ipoib_neigh structure problem.
> But then neigh->ah might be freed while xmit is using it.
>
Maybe I'm missing something, but what you say doesn't look
correct.
path_free() now does:
if (neigh->ah)
ipoib_put_ah(neigh->ah);
(with a comment explaining that it's OK to do that while holding
priv->lock.)
But with the patch above, ipoib_put_ah() is deferred to the rcu
callback (just like the kfree() of the ipoib_neigh structure is).
--
Arthur
More information about the general
mailing list