aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/net/wireless/iwlwifi/mvm/bt-coex.c22
-rw-r--r--drivers/net/wireless/iwlwifi/mvm/mac80211.c2
2 files changed, 5 insertions, 19 deletions
diff --git a/drivers/net/wireless/iwlwifi/mvm/bt-coex.c b/drivers/net/wireless/iwlwifi/mvm/bt-coex.c
index dbd622a3929c..9195779a9d3f 100644
--- a/drivers/net/wireless/iwlwifi/mvm/bt-coex.c
+++ b/drivers/net/wireless/iwlwifi/mvm/bt-coex.c
@@ -384,6 +384,10 @@ static void iwl_mvm_bt_notif_iterator(void *_data, u8 *mac,
384 384
385 smps_mode = IEEE80211_SMPS_AUTOMATIC; 385 smps_mode = IEEE80211_SMPS_AUTOMATIC;
386 386
387 /* non associated BSSes aren't to be considered */
388 if (!vif->bss_conf.assoc)
389 return;
390
387 if (band != IEEE80211_BAND_2GHZ) { 391 if (band != IEEE80211_BAND_2GHZ) {
388 iwl_mvm_update_smps(mvm, vif, IWL_MVM_SMPS_REQ_BT_COEX, 392 iwl_mvm_update_smps(mvm, vif, IWL_MVM_SMPS_REQ_BT_COEX,
389 smps_mode); 393 smps_mode);
@@ -588,23 +592,5 @@ void iwl_mvm_bt_rssi_event(struct iwl_mvm *mvm, struct ieee80211_vif *vif,
588 592
589void iwl_mvm_bt_coex_vif_assoc(struct iwl_mvm *mvm, struct ieee80211_vif *vif) 593void iwl_mvm_bt_coex_vif_assoc(struct iwl_mvm *mvm, struct ieee80211_vif *vif)
590{ 594{
591 struct ieee80211_chanctx_conf *chanctx_conf;
592 enum ieee80211_band band;
593
594 rcu_read_lock();
595 chanctx_conf = rcu_dereference(vif->chanctx_conf);
596 if (chanctx_conf && chanctx_conf->def.chan)
597 band = chanctx_conf->def.chan->band;
598 else
599 band = -1;
600 rcu_read_unlock();
601
602 /* if we are in 2GHz we will get a notification from the fw */
603 if (band == IEEE80211_BAND_2GHZ)
604 return;
605
606 /* else, we can remove all the constraints */
607 memset(&mvm->last_bt_notif, 0, sizeof(mvm->last_bt_notif));
608
609 iwl_mvm_bt_coex_notif_handle(mvm); 595 iwl_mvm_bt_coex_notif_handle(mvm);
610} 596}
diff --git a/drivers/net/wireless/iwlwifi/mvm/mac80211.c b/drivers/net/wireless/iwlwifi/mvm/mac80211.c
index 2d07605eaabf..30319e069f45 100644
--- a/drivers/net/wireless/iwlwifi/mvm/mac80211.c
+++ b/drivers/net/wireless/iwlwifi/mvm/mac80211.c
@@ -761,7 +761,6 @@ static void iwl_mvm_bss_info_changed_station(struct iwl_mvm *mvm,
761 IWL_ERR(mvm, "failed to update quotas\n"); 761 IWL_ERR(mvm, "failed to update quotas\n");
762 return; 762 return;
763 } 763 }
764 iwl_mvm_bt_coex_vif_assoc(mvm, vif);
765 iwl_mvm_configure_mcast_filter(mvm, vif); 764 iwl_mvm_configure_mcast_filter(mvm, vif);
766 } else if (mvmvif->ap_sta_id != IWL_MVM_STATION_COUNT) { 765 } else if (mvmvif->ap_sta_id != IWL_MVM_STATION_COUNT) {
767 /* remove AP station now that the MAC is unassoc */ 766 /* remove AP station now that the MAC is unassoc */
@@ -782,6 +781,7 @@ static void iwl_mvm_bss_info_changed_station(struct iwl_mvm *mvm,
782 if (ret) 781 if (ret)
783 IWL_ERR(mvm, "failed to update power mode\n"); 782 IWL_ERR(mvm, "failed to update power mode\n");
784 } 783 }
784 iwl_mvm_bt_coex_vif_assoc(mvm, vif);
785 } else if (changes & BSS_CHANGED_BEACON_INFO) { 785 } else if (changes & BSS_CHANGED_BEACON_INFO) {
786 /* 786 /*
787 * We received a beacon _after_ association so 787 * We received a beacon _after_ association so