aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-agn.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wireless/iwlwifi/iwl-agn.c
index 4e3d6c7fd6de..e01f048a02dd 100644
--- a/drivers/net/wireless/iwlwifi/iwl-agn.c
+++ b/drivers/net/wireless/iwlwifi/iwl-agn.c
@@ -4372,15 +4372,18 @@ static void __devexit iwl4965_pci_remove(struct pci_dev *pdev)
4372 iwl_dbgfs_unregister(priv); 4372 iwl_dbgfs_unregister(priv);
4373 sysfs_remove_group(&pdev->dev.kobj, &iwl4965_attribute_group); 4373 sysfs_remove_group(&pdev->dev.kobj, &iwl4965_attribute_group);
4374 4374
4375 /* ieee80211_unregister_hw call wil cause iwl4965_mac_stop to
4376 * to be called and iwl4965_down since we are removing the device
4377 * we need to set STATUS_EXIT_PENDING bit.
4378 */
4379 set_bit(STATUS_EXIT_PENDING, &priv->status);
4375 if (priv->mac80211_registered) { 4380 if (priv->mac80211_registered) {
4376 ieee80211_unregister_hw(priv->hw); 4381 ieee80211_unregister_hw(priv->hw);
4377 priv->mac80211_registered = 0; 4382 priv->mac80211_registered = 0;
4383 } else {
4384 iwl4965_down(priv);
4378 } 4385 }
4379 4386
4380 set_bit(STATUS_EXIT_PENDING, &priv->status);
4381
4382 iwl4965_down(priv);
4383
4384 /* make sure we flush any pending irq or 4387 /* make sure we flush any pending irq or
4385 * tasklet for the driver 4388 * tasklet for the driver
4386 */ 4389 */