aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEytan Lifshitz <eytan.lifshitz@intel.com>2013-09-03 05:06:11 -0400
committerJohannes Berg <johannes.berg@intel.com>2013-10-02 12:00:45 -0400
commitff116373f6b2e080208fc0478457734a13d8e6dc (patch)
treedb7ad4b529609e935ed5c4c4b85103f6f59e117f
parentf7fc598931766a0609f33de249c17c067737425e (diff)
iwlwifi: mvm: change the name of init_ucode_run flag
In RF KILL the init ucode is running, but don't complete all its tasks, so we need to run the init ucode again. Change the flag name to init_ucode_complete, to be more appropriate. Signed-off-by: Eytan Lifshitz <eytan.lifshitz@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
-rw-r--r--drivers/net/wireless/iwlwifi/mvm/fw.c12
-rw-r--r--drivers/net/wireless/iwlwifi/mvm/mvm.h2
2 files changed, 9 insertions, 5 deletions
diff --git a/drivers/net/wireless/iwlwifi/mvm/fw.c b/drivers/net/wireless/iwlwifi/mvm/fw.c
index c76299a3a1e0..f96186f28035 100644
--- a/drivers/net/wireless/iwlwifi/mvm/fw.c
+++ b/drivers/net/wireless/iwlwifi/mvm/fw.c
@@ -243,7 +243,7 @@ int iwl_run_init_mvm_ucode(struct iwl_mvm *mvm, bool read_nvm)
243 243
244 lockdep_assert_held(&mvm->mutex); 244 lockdep_assert_held(&mvm->mutex);
245 245
246 if (mvm->init_ucode_run) 246 if (mvm->init_ucode_complete)
247 return 0; 247 return 0;
248 248
249 iwl_init_notification_wait(&mvm->notif_wait, 249 iwl_init_notification_wait(&mvm->notif_wait,
@@ -310,7 +310,7 @@ int iwl_run_init_mvm_ucode(struct iwl_mvm *mvm, bool read_nvm)
310 ret = iwl_wait_notification(&mvm->notif_wait, &calib_wait, 310 ret = iwl_wait_notification(&mvm->notif_wait, &calib_wait,
311 MVM_UCODE_CALIB_TIMEOUT); 311 MVM_UCODE_CALIB_TIMEOUT);
312 if (!ret) 312 if (!ret)
313 mvm->init_ucode_run = true; 313 mvm->init_ucode_complete = true;
314 goto out; 314 goto out;
315 315
316error: 316error:
@@ -353,8 +353,12 @@ int iwl_mvm_up(struct iwl_mvm *mvm)
353 if (ret) 353 if (ret)
354 return ret; 354 return ret;
355 355
356 /* If we were in RFKILL during module loading, load init ucode now */ 356 /*
357 if (!mvm->init_ucode_run) { 357 * If we haven't completed the run of the init ucode during
358 * module loading, load init ucode now
359 * (for example, if we were in RFKILL)
360 */
361 if (!mvm->init_ucode_complete) {
358 ret = iwl_run_init_mvm_ucode(mvm, false); 362 ret = iwl_run_init_mvm_ucode(mvm, false);
359 if (ret && !iwlmvm_mod_params.init_dbg) { 363 if (ret && !iwlmvm_mod_params.init_dbg) {
360 IWL_ERR(mvm, "Failed to run INIT ucode: %d\n", ret); 364 IWL_ERR(mvm, "Failed to run INIT ucode: %d\n", ret);
diff --git a/drivers/net/wireless/iwlwifi/mvm/mvm.h b/drivers/net/wireless/iwlwifi/mvm/mvm.h
index 33dbc7cefeba..18c0ae965658 100644
--- a/drivers/net/wireless/iwlwifi/mvm/mvm.h
+++ b/drivers/net/wireless/iwlwifi/mvm/mvm.h
@@ -441,7 +441,7 @@ struct iwl_mvm {
441 441
442 enum iwl_ucode_type cur_ucode; 442 enum iwl_ucode_type cur_ucode;
443 bool ucode_loaded; 443 bool ucode_loaded;
444 bool init_ucode_run; 444 bool init_ucode_complete;
445 u32 error_event_table; 445 u32 error_event_table;
446 u32 log_event_table; 446 u32 log_event_table;
447 447