From: Pavel Emelyanov Date: Mon, 5 May 2008 00:59:30 +0000 (-0700) Subject: mac80211: Do not free net device after it is unregistered. X-Git-Tag: v2.6.26-rc2~60^2~11 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=339a7c41c913035bf58579f6e47b4ba29da83795;p=pandora-kernel.git mac80211: Do not free net device after it is unregistered. The error path in ieee80211_register_hw() may call the unregister_netdev() and right after it - the free_netdev(), which is wrong, since the unregister releases the device itself. So the proposed fix is to NULL the local->mdev after unregister is done and check this before calling free_netdev(). I checked - no code uses the local->mdev after unregister in this error path (but even if some did this would be a BUG). Signed-off-by: Pavel Emelyanov Signed-off-by: David S. Miller --- Reading git-diff-tree failed