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-4965.c6
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-5000.c5
-rw-r--r--drivers/net/wireless/iwlwifi/iwl4965-base.c26
3 files changed, 20 insertions, 17 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965.c b/drivers/net/wireless/iwlwifi/iwl-4965.c
index 1b3e82ff90cb..3bb6ac588aaf 100644
--- a/drivers/net/wireless/iwlwifi/iwl-4965.c
+++ b/drivers/net/wireless/iwlwifi/iwl-4965.c
@@ -156,6 +156,8 @@ static int iwl4965_load_bsm(struct iwl_priv *priv)
156 156
157 IWL_DEBUG_INFO("Begin load bsm\n"); 157 IWL_DEBUG_INFO("Begin load bsm\n");
158 158
159 priv->ucode_type = UCODE_RT;
160
159 /* make sure bootstrap program is no larger than BSM's SRAM size */ 161 /* make sure bootstrap program is no larger than BSM's SRAM size */
160 if (len > IWL_MAX_BSM_SIZE) 162 if (len > IWL_MAX_BSM_SIZE)
161 return -EINVAL; 163 return -EINVAL;
@@ -221,8 +223,6 @@ static int iwl4965_load_bsm(struct iwl_priv *priv)
221 223
222 iwl_release_nic_access(priv); 224 iwl_release_nic_access(priv);
223 225
224 priv->ucode_type = UCODE_INIT;
225
226 return 0; 226 return 0;
227} 227}
228 228
@@ -269,8 +269,6 @@ static int iwl4965_set_ucode_ptrs(struct iwl_priv *priv)
269 269
270 IWL_DEBUG_INFO("Runtime uCode pointers are set.\n"); 270 IWL_DEBUG_INFO("Runtime uCode pointers are set.\n");
271 271
272 priv->ucode_type = UCODE_RT;
273
274 return ret; 272 return ret;
275} 273}
276 274
diff --git a/drivers/net/wireless/iwlwifi/iwl-5000.c b/drivers/net/wireless/iwlwifi/iwl-5000.c
index eb6141e6edbc..685a84e5a021 100644
--- a/drivers/net/wireless/iwlwifi/iwl-5000.c
+++ b/drivers/net/wireless/iwlwifi/iwl-5000.c
@@ -804,8 +804,11 @@ static int iwl5000_alive_notify(struct iwl_priv *priv)
804 804
805 iwl5000_send_Xtal_calib(priv); 805 iwl5000_send_Xtal_calib(priv);
806 806
807 if (priv->ucode_type == UCODE_RT) 807 if (priv->ucode_type == UCODE_RT) {
808 iwl5000_send_calib_results(priv); 808 iwl5000_send_calib_results(priv);
809 set_bit(STATUS_READY, &priv->status);
810 priv->is_open = 1;
811 }
809 812
810 return 0; 813 return 0;
811} 814}
diff --git a/drivers/net/wireless/iwlwifi/iwl4965-base.c b/drivers/net/wireless/iwlwifi/iwl4965-base.c
index b3c180723489..af8394c4b2df 100644
--- a/drivers/net/wireless/iwlwifi/iwl4965-base.c
+++ b/drivers/net/wireless/iwlwifi/iwl4965-base.c
@@ -4074,21 +4074,23 @@ static int iwl4965_mac_start(struct ieee80211_hw *hw)
4074 if (test_bit(STATUS_IN_SUSPEND, &priv->status)) 4074 if (test_bit(STATUS_IN_SUSPEND, &priv->status))
4075 return 0; 4075 return 0;
4076 4076
4077 /* Wait for START_ALIVE from ucode. Otherwise callbacks from 4077 /* Wait for START_ALIVE from Run Time ucode. Otherwise callbacks from
4078 * mac80211 will not be run successfully. */ 4078 * mac80211 will not be run successfully. */
4079 ret = wait_event_interruptible_timeout(priv->wait_command_queue, 4079 if (priv->ucode_type == UCODE_RT) {
4080 test_bit(STATUS_READY, &priv->status), 4080 ret = wait_event_interruptible_timeout(priv->wait_command_queue,
4081 UCODE_READY_TIMEOUT); 4081 test_bit(STATUS_READY, &priv->status),
4082 if (!ret) { 4082 UCODE_READY_TIMEOUT);
4083 if (!test_bit(STATUS_READY, &priv->status)) { 4083 if (!ret) {
4084 IWL_ERROR("Wait for START_ALIVE timeout after %dms.\n", 4084 if (!test_bit(STATUS_READY, &priv->status)) {
4085 jiffies_to_msecs(UCODE_READY_TIMEOUT)); 4085 IWL_ERROR("START_ALIVE timeout after %dms.\n",
4086 ret = -ETIMEDOUT; 4086 jiffies_to_msecs(UCODE_READY_TIMEOUT));
4087 goto out_release_irq; 4087 ret = -ETIMEDOUT;
4088 goto out_release_irq;
4089 }
4088 } 4090 }
4089 }
4090 4091
4091 priv->is_open = 1; 4092 priv->is_open = 1;
4093 }
4092 IWL_DEBUG_MAC80211("leave\n"); 4094 IWL_DEBUG_MAC80211("leave\n");
4093 return 0; 4095 return 0;
4094 4096