summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/intel/iwlwifi/dvm/lib.c
diff options
context:
space:
mode:
authorEmmanuel Grumbach2015-12-20 07:45:40 +0100
committerEmmanuel Grumbach2016-01-07 18:01:09 +0100
commita1cdb1c59c8c203de2731fc6910598ed19c97e41 (patch)
treed1d80f978cfd5c40c69b0564baf9049c4dd71890 /drivers/net/wireless/intel/iwlwifi/dvm/lib.c
parentiwlwifi: bail out in case of bad trans state (diff)
downloadkernel-qcow2-linux-a1cdb1c59c8c203de2731fc6910598ed19c97e41.tar.gz
kernel-qcow2-linux-a1cdb1c59c8c203de2731fc6910598ed19c97e41.tar.xz
kernel-qcow2-linux-a1cdb1c59c8c203de2731fc6910598ed19c97e41.zip
iwlwifi: dvm: fix WoWLAN
My commit below introduced a mutex in the transport to prevent concurrent operations. To do so, it added a flag (is_down) to make sure the transport is in the right state. This uncoverred an bug that didn't cause any harm until now: iwldvm calls stop_device and then starts the firmware without calling start_hw in between. While this flow is fine from the device configuration point of view (register, etc...), it is now forbidden by the new is_down flag. This led to this error to appear: iwlwifi 0000:05:00.0: Can't start_fw since the HW hasn't been started and the suspend would fail. This fixes: https://bugzilla.kernel.org/show_bug.cgi?id=109591 CC: <stable@vger.kernel.org> [4.3+] Reported-by: Bogdan Bogush <bogdan.s.bogush@gmail.com> Fixes=fa9f3281cbb1 ("iwlwifi: pcie: lock start_hw / start_fw / stop_device") Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Diffstat (limited to 'drivers/net/wireless/intel/iwlwifi/dvm/lib.c')
-rw-r--r--drivers/net/wireless/intel/iwlwifi/dvm/lib.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/wireless/intel/iwlwifi/dvm/lib.c b/drivers/net/wireless/intel/iwlwifi/dvm/lib.c
index bee1c03ee259..4841be2aa499 100644
--- a/drivers/net/wireless/intel/iwlwifi/dvm/lib.c
+++ b/drivers/net/wireless/intel/iwlwifi/dvm/lib.c
@@ -1154,6 +1154,9 @@ int iwlagn_suspend(struct iwl_priv *priv, struct cfg80211_wowlan *wowlan)
priv->ucode_loaded = false;
iwl_trans_stop_device(priv->trans);
+ ret = iwl_trans_start_hw(priv->trans);
+ if (ret)
+ goto out;
priv->wowlan = true;