summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/intel/iwlwifi/mvm/mvm.h
diff options
context:
space:
mode:
authorChaya Rachel Ivgi2016-02-22 09:21:41 +0100
committerEmmanuel Grumbach2016-03-02 07:56:58 +0100
commitfcb6b92a682fe5032fdc31af7f8ed86f1dabb1e2 (patch)
tree93b7d6182920c18848f5b091b91d1e42fbb0bb8b /drivers/net/wireless/intel/iwlwifi/mvm/mvm.h
parentiwlwifi: support ucode with d0 unified image - regular and usniffer (diff)
downloadkernel-qcow2-linux-fcb6b92a682fe5032fdc31af7f8ed86f1dabb1e2.tar.gz
kernel-qcow2-linux-fcb6b92a682fe5032fdc31af7f8ed86f1dabb1e2.tar.xz
kernel-qcow2-linux-fcb6b92a682fe5032fdc31af7f8ed86f1dabb1e2.zip
iwlwifi: mvm: update ucode status before stopping device
Leaving ucode_loaded to true after stop_device() has been called is a recipe for problems. Flows that are not sync'ed with the driver life cycle (like debugfs hooks and thermal hooks) must check that the firmware is loaded before they interact with it. Therefore we need to keep this variable updated with the real status of the firmware. Signed-off-by: Chaya Rachel Ivgi <chaya.rachel.ivgi@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Diffstat (limited to 'drivers/net/wireless/intel/iwlwifi/mvm/mvm.h')
-rw-r--r--drivers/net/wireless/intel/iwlwifi/mvm/mvm.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/mvm.h b/drivers/net/wireless/intel/iwlwifi/mvm/mvm.h
index b461b909e7af..6d4e4879357c 100644
--- a/drivers/net/wireless/intel/iwlwifi/mvm/mvm.h
+++ b/drivers/net/wireless/intel/iwlwifi/mvm/mvm.h
@@ -1549,6 +1549,12 @@ void iwl_mvm_enable_ac_txq(struct iwl_mvm *mvm, int queue, int mac80211_queue,
iwl_mvm_enable_txq(mvm, queue, mac80211_queue, ssn, &cfg, wdg_timeout);
}
+static inline void iwl_mvm_stop_device(struct iwl_mvm *mvm)
+{
+ mvm->ucode_loaded = false;
+ iwl_trans_stop_device(mvm->trans);
+}
+
/* Thermal management and CT-kill */
void iwl_mvm_tt_tx_backoff(struct iwl_mvm *mvm, u32 backoff);
void iwl_mvm_tt_temp_changed(struct iwl_mvm *mvm, u32 temp);