[openib-general] ib_free_recv_mad and references

Hal Rosenstock halr at voltaire.com
Wed Oct 27 07:08:45 PDT 2004


On Tue, 2004-10-26 at 12:40, Sean Hefty wrote:
> Currently, a call to ib_free_recv_mad does not dereference the mad_agent that 
> the mad was given to.  The call itself does not access the mad_agent, 
> but should a reference be held on the mad_agent while it has a received MAD?  
> Looking at the implementation, it appears that a mad_agent could deregister 
> with the access layer, then call ib_free_recv_mad, which accesses the 
> ib_mad_cache.

ib_mad_cache is in existence from the time of module insertion to
removal. Deregistering the mad_agent has no effect on its presence so I
don't think the order of ib_free_mad_recv and ib_unregister_mad_agent
matters.

-- Hal






More information about the general mailing list