Thread (8 messages) 8 messages, 3 authors, 2004-01-10

Re: [PATCH] panic during unregister_netdevice()

flat view

From: David S. Miller <hidden>
Date: 2003-11-06 19:59:35

On Thu, 6 Nov 2003 11:58:24 -0800
Krishna Kumar [off-list ref] wrote:
When unregister_netdev() is called by the driver, it first calls
unregister_netdevice() which
drops it's last ref to the dev, making it zero. unregister_netdev() then
calls rtnl_unlock() which
calls netdev_run_todo(), which calls netdev_wait_allrefs() and only after
that succeeds,
does the driver do a free_netdev(). So the dev should not be freed while
the wait_ref() is
executing, and the original code looks correct.
That's correct.
I don't know if it is some corruption on my system, some hardware problem ?
I will look
some more, also try to get a different machine.
It could be some 'user after free' or similar issue.
Just an idea of something else to look for.

My earlier comments about "putting to zero multiple times" were
misguided, I forgot that these days dev_put() just decrements the
count and does not do anything special when the count reaches zero.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help