[openib-general] slab error in kmem_cache_destroy(): cache `ib_mad': Can't free all objects

Hal Rosenstock halr at voltaire.com
Mon May 2 13:45:30 PDT 2005


On Mon, 2005-05-02 at 12:33, Michael S. Tsirkin wrote: 
> Do you have a theory on why are MADs leaking?

I don't see a MAD leak but perhaps see a couple of other possible memory
leaks on shutdown.

It looks to me like agent.c has the following issue on shutdown:
ib_agent_port_close removes the port from the agent port list before
deregistering its MAD agents. This causes any send completions to fail
the lookup and hence a number of resources are not returned in this
scenario. In that case, I would expect the following to be seend in
dmesg: "agent_send_handler: no matching MAD agent". Since this message
is not seen, this is not the scenario that is occurring but I will make
up a patch for this and send it to the list.

Also, does user_mad.c leak memory on the receive side if it is shutdown
and the application has not drained the receive queue ?

-- Hal





More information about the general mailing list