summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/intel/iwlwifi/iwl-io.c
diff options
context:
space:
mode:
authorJohannes Berg <johannes.berg@intel.com>2018-12-10 11:36:58 +0300
committerLuca Coelho <luciano.coelho@intel.com>2019-02-04 13:28:10 +0300
commitb998fbbd531fe33d9dd50fd37056f48b4257113d (patch)
tree3f2e63683220bc0a0e23e09dbf434ed66501d000 /drivers/net/wireless/intel/iwlwifi/iwl-io.c
parentdbf592f3d14fb7d532cb7c820b1065cf33e02aaa (diff)
downloadlinux-b998fbbd531fe33d9dd50fd37056f48b4257113d.tar.xz
iwlwifi: implement BISR HW workaround for 22260 devices
There's a small hardware bug in 22260 devices which thus require a few more delays during initialization. Implement this workaround. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Diffstat (limited to 'drivers/net/wireless/intel/iwlwifi/iwl-io.c')
-rw-r--r--drivers/net/wireless/intel/iwlwifi/iwl-io.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/net/wireless/intel/iwlwifi/iwl-io.c b/drivers/net/wireless/intel/iwlwifi/iwl-io.c
index 4ea5883f9175..bf171edad53a 100644
--- a/drivers/net/wireless/intel/iwlwifi/iwl-io.c
+++ b/drivers/net/wireless/intel/iwlwifi/iwl-io.c
@@ -493,6 +493,11 @@ int iwl_finish_nic_init(struct iwl_trans *trans)
{
int err;
+ if (trans->cfg->bisr_workaround) {
+ /* ensure the TOP FSM isn't still in previous reset */
+ mdelay(2);
+ }
+
/*
* Set "initialization complete" bit to move adapter from
* D0U* --> D0A* (powered-up active) state.
@@ -515,6 +520,11 @@ int iwl_finish_nic_init(struct iwl_trans *trans)
if (err < 0)
IWL_DEBUG_INFO(trans, "Failed to wake NIC\n");
+ if (trans->cfg->bisr_workaround) {
+ /* ensure BISR shift has finished */
+ udelay(200);
+ }
+
return err < 0 ? err : 0;
}
IWL_EXPORT_SYMBOL(iwl_finish_nic_init);