Lines Matching refs:mvmvif
684 struct iwl_mvm_vif *mvmvif = in iwl_mvm_mac_tx() local
686 u8 ap_sta_id = READ_ONCE(mvmvif->ap_sta_id); in iwl_mvm_mac_tx()
873 struct iwl_mvm_vif *mvmvif; in iwl_mvm_mac_ampdu_action() local
878 mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_mac_ampdu_action()
879 cancel_delayed_work(&mvmvif->uapsd_nonagg_detected_wk); in iwl_mvm_mac_ampdu_action()
934 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_cleanup_iterator() local
936 mvmvif->uploaded = false; in iwl_mvm_cleanup_iterator()
937 mvmvif->ap_sta_id = IWL_MVM_INVALID_STA; in iwl_mvm_cleanup_iterator()
940 iwl_mvm_te_clear_data(mvm, &mvmvif->time_event_data); in iwl_mvm_cleanup_iterator()
943 mvmvif->phy_ctxt = NULL; in iwl_mvm_cleanup_iterator()
944 memset(&mvmvif->bf_data, 0, sizeof(mvmvif->bf_data)); in iwl_mvm_cleanup_iterator()
945 memset(&mvmvif->probe_resp_data, 0, sizeof(mvmvif->probe_resp_data)); in iwl_mvm_cleanup_iterator()
1259 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_post_channel_switch() local
1268 mvmvif->csa_bcn_pending = false; in iwl_mvm_post_channel_switch()
1270 mvmvif->ap_sta_id); in iwl_mvm_post_channel_switch()
1291 mvmvif->ps_disabled = false; in iwl_mvm_post_channel_switch()
1296 if (mvmvif->csa_failed) in iwl_mvm_post_channel_switch()
1307 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_abort_channel_switch() local
1309 .mac_id = cpu_to_le32(FW_CMD_ID_AND_COLOR(mvmvif->id, in iwl_mvm_abort_channel_switch()
1310 mvmvif->color)), in iwl_mvm_abort_channel_switch()
1323 IWL_DEBUG_MAC80211(mvm, "Abort CSA on mac %d\n", mvmvif->id); in iwl_mvm_abort_channel_switch()
1334 mvmvif->csa_failed = true; in iwl_mvm_abort_channel_switch()
1342 struct iwl_mvm_vif *mvmvif; in iwl_mvm_channel_switch_disconnect_wk() local
1345 mvmvif = container_of(wk, struct iwl_mvm_vif, csa_work.work); in iwl_mvm_channel_switch_disconnect_wk()
1346 vif = container_of((void *)mvmvif, struct ieee80211_vif, drv_priv); in iwl_mvm_channel_switch_disconnect_wk()
1356 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_mac_add_interface() local
1359 mvmvif->mvm = mvm; in iwl_mvm_mac_add_interface()
1360 RCU_INIT_POINTER(mvmvif->probe_resp_data, NULL); in iwl_mvm_mac_add_interface()
1372 mvmvif->beacon_stats.accu_num_beacons += in iwl_mvm_mac_add_interface()
1373 mvmvif->beacon_stats.num_beacons; in iwl_mvm_mac_add_interface()
1380 rcu_assign_pointer(mvm->vif_id_to_mac[mvmvif->id], vif); in iwl_mvm_mac_add_interface()
1405 ret = iwl_mvm_allocate_int_sta(mvm, &mvmvif->mcast_sta, in iwl_mvm_mac_add_interface()
1415 mvmvif->features |= hw->netdev_features; in iwl_mvm_mac_add_interface()
1432 mvm->bf_allowed_vif = mvmvif; in iwl_mvm_mac_add_interface()
1444 mvmvif->phy_ctxt = iwl_mvm_get_free_phy_ctxt(mvm); in iwl_mvm_mac_add_interface()
1445 if (!mvmvif->phy_ctxt) { in iwl_mvm_mac_add_interface()
1450 iwl_mvm_phy_ctxt_ref(mvm, mvmvif->phy_ctxt); in iwl_mvm_mac_add_interface()
1465 INIT_DELAYED_WORK(&mvmvif->csa_work, in iwl_mvm_mac_add_interface()
1486 iwl_mvm_phy_ctxt_unref(mvm, mvmvif->phy_ctxt); in iwl_mvm_mac_add_interface()
1488 if (mvm->bf_allowed_vif == mvmvif) { in iwl_mvm_mac_add_interface()
1494 mvmvif->phy_ctxt = NULL; in iwl_mvm_mac_add_interface()
1519 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_mac_remove_interface() local
1535 probe_data = rcu_dereference_protected(mvmvif->probe_resp_data, in iwl_mvm_mac_remove_interface()
1537 RCU_INIT_POINTER(mvmvif->probe_resp_data, NULL); in iwl_mvm_mac_remove_interface()
1541 if (mvm->bf_allowed_vif == mvmvif) { in iwl_mvm_mac_remove_interface()
1564 iwl_mvm_dealloc_int_sta(mvm, &mvmvif->mcast_sta); in iwl_mvm_mac_remove_interface()
1573 iwl_mvm_phy_ctxt_unref(mvm, mvmvif->phy_ctxt); in iwl_mvm_mac_remove_interface()
1574 mvmvif->phy_ctxt = NULL; in iwl_mvm_mac_remove_interface()
1580 RCU_INIT_POINTER(mvm->vif_id_to_mac[mvmvif->id], NULL); in iwl_mvm_mac_remove_interface()
1923 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_cfg_he_sta() local
1993 if (mvmvif->he_ru_2mhz_block) in iwl_mvm_cfg_he_sta()
2064 &mvmvif->queue_params[i].mu_edca_param_rec; in iwl_mvm_cfg_he_sta()
2067 if (!mvmvif->queue_params[i].mu_edca) { in iwl_mvm_cfg_he_sta()
2186 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_bss_info_changed_station() local
2197 iwl_mvm_cfg_he_sta(mvm, vif, mvmvif->ap_sta_id); in iwl_mvm_bss_info_changed_station()
2203 if (changes & BSS_CHANGED_QOS && mvmvif->associated && in iwl_mvm_bss_info_changed_station()
2206 iwl_mvm_cfg_he_sta(mvm, vif, mvmvif->ap_sta_id); in iwl_mvm_bss_info_changed_station()
2214 if (changes & BSS_CHANGED_BSSID && !mvmvif->associated) in iwl_mvm_bss_info_changed_station()
2215 memcpy(mvmvif->bssid, bss_conf->bssid, ETH_ALEN); in iwl_mvm_bss_info_changed_station()
2217 ret = iwl_mvm_mac_ctxt_changed(mvm, vif, false, mvmvif->bssid); in iwl_mvm_bss_info_changed_station()
2222 memcpy(mvmvif->bssid, bss_conf->bssid, ETH_ALEN); in iwl_mvm_bss_info_changed_station()
2223 mvmvif->associated = vif->cfg.assoc; in iwl_mvm_bss_info_changed_station()
2229 memset(&mvmvif->beacon_stats, 0, in iwl_mvm_bss_info_changed_station()
2230 sizeof(mvmvif->beacon_stats)); in iwl_mvm_bss_info_changed_station()
2287 } else if (mvmvif->ap_sta_id != IWL_MVM_INVALID_STA) { in iwl_mvm_bss_info_changed_station()
2314 mvmvif->ap_sta_id); in iwl_mvm_bss_info_changed_station()
2319 mvmvif->ap_sta_id = IWL_MVM_INVALID_STA; in iwl_mvm_bss_info_changed_station()
2350 mvmvif->bf_data.ave_beacon_signal = 0; in iwl_mvm_bss_info_changed_station()
2385 mvmvif->bf_data.last_cqm_event = 0; in iwl_mvm_bss_info_changed_station()
2386 if (mvmvif->bf_data.bf_enabled) { in iwl_mvm_bss_info_changed_station()
2403 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_start_ap_ibss() local
2421 mvmvif->ap_assoc_sta_count = 0; in iwl_mvm_start_ap_ibss()
2469 mvmvif->ap_ibss_active = true; in iwl_mvm_start_ap_ibss()
2472 for (i = 0; i < ARRAY_SIZE(mvmvif->ap_early_keys); i++) { in iwl_mvm_start_ap_ibss()
2473 struct ieee80211_key_conf *key = mvmvif->ap_early_keys[i]; in iwl_mvm_start_ap_ibss()
2478 mvmvif->ap_early_keys[i] = NULL; in iwl_mvm_start_ap_ibss()
2486 iwl_mvm_vif_set_low_latency(mvmvif, true, in iwl_mvm_start_ap_ibss()
2488 iwl_mvm_send_low_latency_cmd(mvm, true, mvmvif->id); in iwl_mvm_start_ap_ibss()
2514 mvmvif->ap_ibss_active = false; in iwl_mvm_start_ap_ibss()
2544 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_stop_ap_ibss() local
2552 iwl_mvm_remove_time_event(mvm, mvmvif, in iwl_mvm_stop_ap_ibss()
2553 &mvmvif->time_event_data); in iwl_mvm_stop_ap_ibss()
2555 mvmvif->csa_countdown = false; in iwl_mvm_stop_ap_ibss()
2563 mvmvif->ap_ibss_active = false; in iwl_mvm_stop_ap_ibss()
2567 iwl_mvm_vif_set_low_latency(mvmvif, false, in iwl_mvm_stop_ap_ibss()
2569 iwl_mvm_send_low_latency_cmd(mvm, false, mvmvif->id); in iwl_mvm_stop_ap_ibss()
2623 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_bss_info_changed_ap_ibss() local
2626 if (!mvmvif->ap_ibss_active) in iwl_mvm_bss_info_changed_ap_ibss()
2990 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_check_he_obss_narrow_bw_ru() local
2996 mvmvif->he_ru_2mhz_block = false; in iwl_mvm_check_he_obss_narrow_bw_ru()
3008 mvmvif->he_ru_2mhz_block = !iter_data.tolerated; in iwl_mvm_check_he_obss_narrow_bw_ru()
3049 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_mei_host_associated() local
3079 switch (mvmvif->rekey_data.akm) { in iwl_mvm_mei_host_associated()
3114 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_mac_sta_state() local
3122 if (WARN_ON_ONCE(!mvmvif->phy_ctxt)) in iwl_mvm_mac_sta_state()
3210 mvmvif->ap_assoc_sta_count++; in iwl_mvm_mac_sta_state()
3218 mvmvif->he_ru_2mhz_block = false; in iwl_mvm_mac_sta_state()
3225 iwl_mvm_rs_rate_init(mvm, sta, mvmvif->phy_ctxt->channel->band, in iwl_mvm_mac_sta_state()
3243 mvmvif->authorized = 1; in iwl_mvm_mac_sta_state()
3254 iwl_mvm_rs_rate_init(mvm, sta, mvmvif->phy_ctxt->channel->band, in iwl_mvm_mac_sta_state()
3261 iwl_mvm_rs_rate_init(mvm, sta, mvmvif->phy_ctxt->channel->band, in iwl_mvm_mac_sta_state()
3271 mvmvif->authorized = 0; in iwl_mvm_mac_sta_state()
3283 mvmvif->ap_assoc_sta_count--; in iwl_mvm_mac_sta_state()
3338 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_sta_rc_update() local
3343 iwl_mvm_rs_rate_init(mvm, sta, mvmvif->phy_ctxt->channel->band, in iwl_mvm_sta_rc_update()
3357 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_mac_conf_tx() local
3359 mvmvif->queue_params[ac] = *params; in iwl_mvm_mac_conf_tx()
3459 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in __iwl_mvm_mac_set_key() local
3508 rcu_assign_pointer(mvmvif->bcn_prot.keys[keyidx - 6], in __iwl_mvm_mac_set_key()
3534 if (!mvmvif->ap_ibss_active) { in __iwl_mvm_mac_set_key()
3536 i < ARRAY_SIZE(mvmvif->ap_early_keys); in __iwl_mvm_mac_set_key()
3538 if (!mvmvif->ap_early_keys[i]) { in __iwl_mvm_mac_set_key()
3539 mvmvif->ap_early_keys[i] = key; in __iwl_mvm_mac_set_key()
3544 if (i >= ARRAY_SIZE(mvmvif->ap_early_keys)) in __iwl_mvm_mac_set_key()
3622 RCU_INIT_POINTER(mvmvif->bcn_prot.keys[keyidx - 6], in __iwl_mvm_mac_set_key()
3626 for (i = 0; i < ARRAY_SIZE(mvmvif->ap_early_keys); i++) { in __iwl_mvm_mac_set_key()
3627 if (mvmvif->ap_early_keys[i] == key) { in __iwl_mvm_mac_set_key()
3628 mvmvif->ap_early_keys[i] = NULL; in __iwl_mvm_mac_set_key()
3741 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_send_aux_roc_cmd() local
3742 struct iwl_mvm_time_event_data *te_data = &mvmvif->hs_time_event_data; in iwl_mvm_send_aux_roc_cmd()
3863 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_roc() local
3913 if (phy_ctxt->ref == 0 || mvmvif->phy_ctxt == phy_ctxt) in iwl_mvm_roc()
3925 iwl_mvm_phy_ctxt_unref(mvm, mvmvif->phy_ctxt); in iwl_mvm_roc()
3928 mvmvif->phy_ctxt = phy_ctxt; in iwl_mvm_roc()
3934 iwl_mvm_phy_ctxt_ref(mvm, mvmvif->phy_ctxt); in iwl_mvm_roc()
3940 if (channel == mvmvif->phy_ctxt->channel) in iwl_mvm_roc()
3954 mvmvif->phy_ctxt->channel->band != chandef.chan->band; in iwl_mvm_roc()
3956 if (mvmvif->phy_ctxt->ref == 1 && !band_change_removal) { in iwl_mvm_roc()
3961 ret = iwl_mvm_phy_ctxt_changed(mvm, mvmvif->phy_ctxt, in iwl_mvm_roc()
3989 iwl_mvm_phy_ctxt_unref(mvm, mvmvif->phy_ctxt); in iwl_mvm_roc()
3992 mvmvif->phy_ctxt = phy_ctxt; in iwl_mvm_roc()
3998 iwl_mvm_phy_ctxt_ref(mvm, mvmvif->phy_ctxt); in iwl_mvm_roc()
4171 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in __iwl_mvm_assign_vif_chanctx() local
4176 mvmvif->phy_ctxt = phy_ctxt; in __iwl_mvm_assign_vif_chanctx()
4182 mvmvif->ap_ibss_active = true; in __iwl_mvm_assign_vif_chanctx()
4194 mvmvif->csa_bcn_pending = false; in __iwl_mvm_assign_vif_chanctx()
4198 mvmvif->ps_disabled = true; in __iwl_mvm_assign_vif_chanctx()
4220 mvmvif->monitor_active = true; in __iwl_mvm_assign_vif_chanctx()
4238 mvmvif->csa_bcn_pending = true; in __iwl_mvm_assign_vif_chanctx()
4262 mvmvif->phy_ctxt = NULL; in __iwl_mvm_assign_vif_chanctx()
4285 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in __iwl_mvm_unassign_vif_chanctx() local
4289 iwl_mvm_remove_time_event(mvm, mvmvif, &mvmvif->time_event_data); in __iwl_mvm_unassign_vif_chanctx()
4295 mvmvif->monitor_active = false; in __iwl_mvm_unassign_vif_chanctx()
4296 mvmvif->ps_disabled = false; in __iwl_mvm_unassign_vif_chanctx()
4301 if (!switching_chanctx || !mvmvif->ap_ibss_active) in __iwl_mvm_unassign_vif_chanctx()
4304 mvmvif->csa_countdown = false; in __iwl_mvm_unassign_vif_chanctx()
4307 iwl_mvm_modify_all_sta_disable_tx(mvm, mvmvif, true); in __iwl_mvm_unassign_vif_chanctx()
4312 mvmvif->ap_ibss_active = false; in __iwl_mvm_unassign_vif_chanctx()
4335 mvmvif->phy_ctxt = NULL; in __iwl_mvm_unassign_vif_chanctx()
4581 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_schedule_client_csa() local
4583 .mac_id = cpu_to_le32(FW_CMD_ID_AND_COLOR(mvmvif->id, in iwl_mvm_schedule_client_csa()
4584 mvmvif->color)), in iwl_mvm_schedule_client_csa()
4607 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_old_pre_chan_sw_sta() local
4626 if (mvmvif->bf_data.bf_enabled) { in iwl_mvm_old_pre_chan_sw_sta()
4646 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_pre_channel_switch() local
4651 mvmvif->csa_failed = false; in iwl_mvm_pre_channel_switch()
4680 if (WARN_ONCE(mvmvif->csa_countdown, in iwl_mvm_pre_channel_switch()
4686 mvmvif->csa_target_freq = chsw->chandef.chan->center_freq; in iwl_mvm_pre_channel_switch()
4710 schedule_delayed_work(&mvmvif->csa_work, 0); in iwl_mvm_pre_channel_switch()
4720 schedule_delayed_work(&mvmvif->csa_work, in iwl_mvm_pre_channel_switch()
4733 mvmvif->csa_count = chsw->count; in iwl_mvm_pre_channel_switch()
4734 mvmvif->csa_misbehave = false; in iwl_mvm_pre_channel_switch()
4740 mvmvif->ps_disabled = true; in iwl_mvm_pre_channel_switch()
4760 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_channel_switch_rx_beacon() local
4762 .mac_id = cpu_to_le32(FW_CMD_ID_AND_COLOR(mvmvif->id, in iwl_mvm_channel_switch_rx_beacon()
4763 mvmvif->color)), in iwl_mvm_channel_switch_rx_beacon()
4782 mvmvif->id, chsw->count, mvmvif->csa_count, chsw->block_tx); in iwl_mvm_channel_switch_rx_beacon()
4784 if (chsw->count >= mvmvif->csa_count && chsw->block_tx) { in iwl_mvm_channel_switch_rx_beacon()
4785 if (mvmvif->csa_misbehave) { in iwl_mvm_channel_switch_rx_beacon()
4789 mvmvif->csa_misbehave = false; in iwl_mvm_channel_switch_rx_beacon()
4792 mvmvif->csa_misbehave = true; in iwl_mvm_channel_switch_rx_beacon()
4794 mvmvif->csa_count = chsw->count; in iwl_mvm_channel_switch_rx_beacon()
4797 if (mvmvif->csa_failed) in iwl_mvm_channel_switch_rx_beacon()
4846 struct iwl_mvm_vif *mvmvif; in iwl_mvm_mac_flush() local
4864 mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_mac_flush()
4878 WARN_ON(i != mvmvif->ap_sta_id && !sta->tdls); in iwl_mvm_mac_flush()
5083 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_mac_sta_statistics() local
5107 if (mvmvif->ap_sta_id != mvmsta->sta_id) in iwl_mvm_mac_sta_statistics()
5113 sinfo->rx_beacon = mvmvif->beacon_stats.num_beacons + in iwl_mvm_mac_sta_statistics()
5114 mvmvif->beacon_stats.accu_num_beacons; in iwl_mvm_mac_sta_statistics()
5116 if (mvmvif->beacon_stats.avg_signal) { in iwl_mvm_mac_sta_statistics()
5118 sinfo->rx_beacon_signal_avg = mvmvif->beacon_stats.avg_signal; in iwl_mvm_mac_sta_statistics()
5319 struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif); in iwl_mvm_mac_get_ftm_responder_stats() local
5322 !mvmvif->ap_ibss_active || !vif->bss_conf.ftm_responder) in iwl_mvm_mac_get_ftm_responder_stats()