aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAbhijeet Kolekar <abhijeet.kolekar@intel.com>2009-04-08 14:26:38 -0400
committerJohn W. Linville <linville@tuxdriver.com>2009-04-22 16:54:42 -0400
commitf45c271493c37d2d80177582191acc1a4e446297 (patch)
tree32721cc5440c4a05ca687088848044179fdc93c2
parente0158e61108bdadd70865c2149dc829a5c84dd73 (diff)
iwl3945: delay mode setting
Delay mode setting till uCode is ready. Signed-off-by: Abhijeet Kolekar <abhijeet.kolekar@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r--drivers/net/wireless/iwlwifi/iwl3945-base.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c
index e96a726dc5c9..0ad89fb90d05 100644
--- a/drivers/net/wireless/iwlwifi/iwl3945-base.c
+++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c
@@ -2758,6 +2758,9 @@ static void iwl3945_alive_start(struct iwl_priv *priv)
2758 iwl_mac_beacon_update(priv->hw, beacon); 2758 iwl_mac_beacon_update(priv->hw, beacon);
2759 } 2759 }
2760 2760
2761 if (test_and_clear_bit(STATUS_MODE_PENDING, &priv->status))
2762 iwl3945_set_mode(priv, priv->iw_mode);
2763
2761 return; 2764 return;
2762 2765
2763 restart: 2766 restart:
@@ -3497,8 +3500,8 @@ static int iwl3945_mac_add_interface(struct ieee80211_hw *hw,
3497 memcpy(priv->mac_addr, conf->mac_addr, ETH_ALEN); 3500 memcpy(priv->mac_addr, conf->mac_addr, ETH_ALEN);
3498 } 3501 }
3499 3502
3500 if (iwl_is_ready(priv)) 3503 if (iwl3945_set_mode(priv, conf->type) == -EAGAIN)
3501 iwl3945_set_mode(priv, conf->type); 3504 set_bit(STATUS_MODE_PENDING, &priv->status);
3502 3505
3503 mutex_unlock(&priv->mutex); 3506 mutex_unlock(&priv->mutex);
3504 3507