]> git.baikalelectronics.ru Git - kernel.git/commit
ipw2x00: fix rtnl mutex deadlock
authorStanislaw Gruszka <sgruszka@redhat.com>
Wed, 14 Sep 2011 14:47:50 +0000 (16:47 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Fri, 16 Sep 2011 19:32:09 +0000 (15:32 -0400)
commit7f4e336cbe54f812dbfbdad729b7829462a176c1
treedb6808f5e5c443f006b7a8e91c05c51248758f5d
parent41754925185a8fde79764fc17cdc2924e6263d32
ipw2x00: fix rtnl mutex deadlock

This fix regression introduced by:

commit: 0a701d7b326f14ede2919ab8e7e7e049aada8e93
Author: Stanislaw Gruszka <sgruszka@redhat.com>
Date:   Fri Aug 12 14:00:59 2011 +0200

    mac80211: fix suspend/resume races with unregister hw

Above commit add rtnl_lock() into wiphy_register(), what cause deadlock
when initializing ipw2x00 driver, which itself call wiphy_register()
from register_netdev() internal callback with rtnl mutex taken.

To fix move wiphy_register() outside register_netdev(). This solution
have side effect of not creating /sys/class/net/wlanX/phy80211 link,
but that's a minor issue we can live with.

Bisected-by: Witold Baryluk <baryluk@smp.if.uj.edu.pl>
Bisected-by: Michael Witten <mfwitten@gmail.com>
Tested-by: Witold Baryluk <baryluk@smp.if.uj.edu.pl>
Tested-by: Michael Witten <mfwitten@gmail.com>
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ipw2x00/ipw2100.c
drivers/net/wireless/ipw2x00/ipw2200.c