|
@@ -276,7 +276,6 @@ int iwl_mvm_mac_setup_register(struct iwl_mvm *mvm)
|
|
|
IEEE80211_HW_AMPDU_AGGREGATION |
|
|
|
IEEE80211_HW_TIMING_BEACON_ONLY |
|
|
|
IEEE80211_HW_CONNECTION_MONITOR |
|
|
|
- IEEE80211_HW_SUPPORTS_UAPSD |
|
|
|
IEEE80211_HW_SUPPORTS_DYNAMIC_SMPS |
|
|
|
IEEE80211_HW_SUPPORTS_STATIC_SMPS;
|
|
|
|
|
@@ -286,8 +285,6 @@ int iwl_mvm_mac_setup_register(struct iwl_mvm *mvm)
|
|
|
IEEE80211_RADIOTAP_MCS_HAVE_STBC;
|
|
|
hw->radiotap_vht_details |= IEEE80211_RADIOTAP_VHT_KNOWN_STBC;
|
|
|
hw->rate_control_algorithm = "iwl-mvm-rs";
|
|
|
- hw->uapsd_queues = IWL_UAPSD_AC_INFO;
|
|
|
- hw->uapsd_max_sp_len = IWL_UAPSD_MAX_SP;
|
|
|
|
|
|
/*
|
|
|
* Enable 11w if advertised by firmware and software crypto
|
|
@@ -298,9 +295,13 @@ int iwl_mvm_mac_setup_register(struct iwl_mvm *mvm)
|
|
|
!iwlwifi_mod_params.sw_crypto)
|
|
|
hw->flags |= IEEE80211_HW_MFP_CAPABLE;
|
|
|
|
|
|
- /* Disable uAPSD due to firmware issues */
|
|
|
- if (true)
|
|
|
- hw->flags &= ~IEEE80211_HW_SUPPORTS_UAPSD;
|
|
|
+ if (mvm->fw->ucode_capa.flags & IWL_UCODE_TLV_FLAGS_UAPSD_SUPPORT &&
|
|
|
+ IWL_UCODE_API(mvm->fw->ucode_ver) >= 9 &&
|
|
|
+ !iwlwifi_mod_params.uapsd_disable) {
|
|
|
+ hw->flags |= IEEE80211_HW_SUPPORTS_UAPSD;
|
|
|
+ hw->uapsd_queues = IWL_UAPSD_AC_INFO;
|
|
|
+ hw->uapsd_max_sp_len = IWL_UAPSD_MAX_SP;
|
|
|
+ }
|
|
|
|
|
|
hw->sta_data_size = sizeof(struct iwl_mvm_sta);
|
|
|
hw->vif_data_size = sizeof(struct iwl_mvm_vif);
|
|
@@ -772,7 +773,7 @@ static int iwl_mvm_set_tx_power(struct iwl_mvm *mvm, struct ieee80211_vif *vif,
|
|
|
.pwr_restriction = cpu_to_le16(tx_power),
|
|
|
};
|
|
|
|
|
|
- return iwl_mvm_send_cmd_pdu(mvm, REDUCE_TX_POWER_CMD, CMD_SYNC,
|
|
|
+ return iwl_mvm_send_cmd_pdu(mvm, REDUCE_TX_POWER_CMD, 0,
|
|
|
sizeof(reduce_txpwr_cmd),
|
|
|
&reduce_txpwr_cmd);
|
|
|
}
|
|
@@ -836,7 +837,7 @@ static int iwl_mvm_mac_add_interface(struct ieee80211_hw *hw,
|
|
|
goto out_release;
|
|
|
|
|
|
/* beacon filtering */
|
|
|
- ret = iwl_mvm_disable_beacon_filter(mvm, vif, CMD_SYNC);
|
|
|
+ ret = iwl_mvm_disable_beacon_filter(mvm, vif, 0);
|
|
|
if (ret)
|
|
|
goto out_remove_mac;
|
|
|
|
|
@@ -1243,7 +1244,7 @@ static int iwl_mvm_configure_bcast_filter(struct iwl_mvm *mvm,
|
|
|
if (!iwl_mvm_bcast_filter_build_cmd(mvm, &cmd))
|
|
|
return 0;
|
|
|
|
|
|
- return iwl_mvm_send_cmd_pdu(mvm, BCAST_FILTER_CMD, CMD_SYNC,
|
|
|
+ return iwl_mvm_send_cmd_pdu(mvm, BCAST_FILTER_CMD, 0,
|
|
|
sizeof(cmd), &cmd);
|
|
|
}
|
|
|
#else
|
|
@@ -1350,7 +1351,7 @@ static void iwl_mvm_bss_info_changed_station(struct iwl_mvm *mvm,
|
|
|
iwl_mvm_remove_time_event(mvm, mvmvif,
|
|
|
&mvmvif->time_event_data);
|
|
|
iwl_mvm_sf_update(mvm, vif, false);
|
|
|
- WARN_ON(iwl_mvm_enable_beacon_filter(mvm, vif, CMD_SYNC));
|
|
|
+ WARN_ON(iwl_mvm_enable_beacon_filter(mvm, vif, 0));
|
|
|
} else if (changes & (BSS_CHANGED_PS | BSS_CHANGED_P2P_PS |
|
|
|
BSS_CHANGED_QOS)) {
|
|
|
ret = iwl_mvm_power_update_mac(mvm, vif);
|
|
@@ -1364,16 +1365,16 @@ static void iwl_mvm_bss_info_changed_station(struct iwl_mvm *mvm,
|
|
|
}
|
|
|
|
|
|
if (changes & BSS_CHANGED_CQM) {
|
|
|
- IWL_DEBUG_MAC80211(mvm, "cqm info_changed");
|
|
|
+ IWL_DEBUG_MAC80211(mvm, "cqm info_changed\n");
|
|
|
/* reset cqm events tracking */
|
|
|
mvmvif->bf_data.last_cqm_event = 0;
|
|
|
- ret = iwl_mvm_update_beacon_filter(mvm, vif, false, CMD_SYNC);
|
|
|
+ ret = iwl_mvm_update_beacon_filter(mvm, vif, false, 0);
|
|
|
if (ret)
|
|
|
IWL_ERR(mvm, "failed to update CQM thresholds\n");
|
|
|
}
|
|
|
|
|
|
if (changes & BSS_CHANGED_ARP_FILTER) {
|
|
|
- IWL_DEBUG_MAC80211(mvm, "arp filter changed");
|
|
|
+ IWL_DEBUG_MAC80211(mvm, "arp filter changed\n");
|
|
|
iwl_mvm_configure_bcast_filter(mvm, vif);
|
|
|
}
|
|
|
}
|
|
@@ -1512,6 +1513,9 @@ static void iwl_mvm_bss_info_changed(struct ieee80211_hw *hw,
|
|
|
|
|
|
mutex_lock(&mvm->mutex);
|
|
|
|
|
|
+ if (changes & BSS_CHANGED_IDLE && !bss_conf->idle)
|
|
|
+ iwl_mvm_sched_scan_stop(mvm, true);
|
|
|
+
|
|
|
switch (vif->type) {
|
|
|
case NL80211_IFTYPE_STATION:
|
|
|
iwl_mvm_bss_info_changed_station(mvm, vif, bss_conf, changes);
|
|
@@ -1542,7 +1546,7 @@ static int iwl_mvm_mac_hw_scan(struct ieee80211_hw *hw,
|
|
|
|
|
|
switch (mvm->scan_status) {
|
|
|
case IWL_MVM_SCAN_SCHED:
|
|
|
- ret = iwl_mvm_sched_scan_stop(mvm);
|
|
|
+ ret = iwl_mvm_sched_scan_stop(mvm, true);
|
|
|
if (ret) {
|
|
|
ret = -EBUSY;
|
|
|
goto out;
|
|
@@ -1731,13 +1735,12 @@ static int iwl_mvm_mac_sta_state(struct ieee80211_hw *hw,
|
|
|
new_state == IEEE80211_STA_AUTHORIZED) {
|
|
|
/* enable beacon filtering */
|
|
|
if (vif->bss_conf.dtim_period)
|
|
|
- WARN_ON(iwl_mvm_enable_beacon_filter(mvm, vif,
|
|
|
- CMD_SYNC));
|
|
|
+ WARN_ON(iwl_mvm_enable_beacon_filter(mvm, vif, 0));
|
|
|
ret = 0;
|
|
|
} else if (old_state == IEEE80211_STA_AUTHORIZED &&
|
|
|
new_state == IEEE80211_STA_ASSOC) {
|
|
|
/* disable beacon filtering */
|
|
|
- WARN_ON(iwl_mvm_disable_beacon_filter(mvm, vif, CMD_SYNC));
|
|
|
+ WARN_ON(iwl_mvm_disable_beacon_filter(mvm, vif, 0));
|
|
|
ret = 0;
|
|
|
} else if (old_state == IEEE80211_STA_ASSOC &&
|
|
|
new_state == IEEE80211_STA_AUTH) {
|
|
@@ -1887,7 +1890,7 @@ static int iwl_mvm_mac_sched_scan_stop(struct ieee80211_hw *hw,
|
|
|
int ret;
|
|
|
|
|
|
mutex_lock(&mvm->mutex);
|
|
|
- ret = iwl_mvm_sched_scan_stop(mvm);
|
|
|
+ ret = iwl_mvm_sched_scan_stop(mvm, false);
|
|
|
mutex_unlock(&mvm->mutex);
|
|
|
iwl_mvm_wait_for_async_handlers(mvm);
|
|
|
|
|
@@ -2183,10 +2186,10 @@ static void iwl_mvm_change_chanctx(struct ieee80211_hw *hw,
|
|
|
return;
|
|
|
|
|
|
mutex_lock(&mvm->mutex);
|
|
|
+ iwl_mvm_bt_coex_vif_change(mvm);
|
|
|
iwl_mvm_phy_ctxt_changed(mvm, phy_ctxt, &ctx->min_def,
|
|
|
ctx->rx_chains_static,
|
|
|
ctx->rx_chains_dynamic);
|
|
|
- iwl_mvm_bt_coex_vif_change(mvm);
|
|
|
mutex_unlock(&mvm->mutex);
|
|
|
}
|
|
|
|
|
@@ -2363,9 +2366,8 @@ static int __iwl_mvm_mac_testmode_cmd(struct iwl_mvm *mvm,
|
|
|
return -EINVAL;
|
|
|
|
|
|
if (nla_get_u32(tb[IWL_MVM_TM_ATTR_BEACON_FILTER_STATE]))
|
|
|
- return iwl_mvm_enable_beacon_filter(mvm, vif,
|
|
|
- CMD_SYNC);
|
|
|
- return iwl_mvm_disable_beacon_filter(mvm, vif, CMD_SYNC);
|
|
|
+ return iwl_mvm_enable_beacon_filter(mvm, vif, 0);
|
|
|
+ return iwl_mvm_disable_beacon_filter(mvm, vif, 0);
|
|
|
}
|
|
|
|
|
|
return -EOPNOTSUPP;
|