Subject: Re: if_detach
To: None <itojun@iijlab.net>
From: Jason Thorpe <thorpej@nas.nasa.gov>
List: tech-net
Date: 02/01/2000 17:29:51
On Wed, 02 Feb 2000 10:27:05 +0900 
 itojun@iijlab.net wrote:

 > >This mostly works ... i.e. works for my USB Ethernet, except for a dangling
 > >ifaddr reference left by the IPv6 code; have not yet tracked this down.
 > 
 > 	in which part do you suspect them left?  i'll try to look at it.

What I've seen is that a cloning route to the link-local-multicast
for the address that's being detached isn't going away, and that
would be what's holding onto the reference, I'm guessing.

If you build your kernel with IFAREF_DEBUG, you'll get lots of messages
on your console for where references are added and deleted, and when
the ifaddr struct is actually freed.

        -- Jason R. Thorpe <thorpej@nas.nasa.gov>