Lines Matching defs:sta

31 void rate_control_rate_init(struct sta_info *sta)
33 struct ieee80211_local *local = sta->sdata->local;
34 struct rate_control_ref *ref = sta->rate_ctrl;
35 struct ieee80211_sta *ista = &sta->sta;
36 void *priv_sta = sta->rate_ctrl_priv;
40 ieee80211_sta_init_nss(&sta->deflink);
47 chanctx_conf = rcu_dereference(sta->sdata->vif.bss_conf.chanctx_conf);
57 ieee80211_s1g_sta_rate_init(sta);
62 spin_lock_bh(&sta->rate_ctrl_lock);
65 spin_unlock_bh(&sta->rate_ctrl_lock);
67 set_sta_flag(sta, WLAN_STA_RATE_CONTROL);
74 struct sta_info *sta = container_of(st->sta, struct sta_info, sta);
75 void *priv_sta = sta->rate_ctrl_priv;
78 if (!ref || !test_sta_flag(sta, WLAN_STA_RATE_CONTROL))
83 spin_lock_bh(&sta->rate_ctrl_lock);
87 ref->ops->tx_status(ref->priv, sband, st->sta, priv_sta, st->skb);
91 spin_unlock_bh(&sta->rate_ctrl_lock);
96 struct sta_info *sta, unsigned int link_id,
100 struct ieee80211_sta *ista = &sta->sta;
101 void *priv_sta = sta->rate_ctrl_priv;
109 chanctx_conf = rcu_dereference(sta->sdata->vif.bss_conf.chanctx_conf);
115 spin_lock_bh(&sta->rate_ctrl_lock);
118 spin_unlock_bh(&sta->rate_ctrl_lock);
122 if (sta->uploaded)
123 drv_sta_rc_update(local, sta->sdata, &sta->sta, changed);
348 struct ieee80211_sta *sta,
374 if (!rate_supported(sta, sband->band, i))
381 "no supported rates for sta %pM (0x%x, band %d) in rate_mask 0x%x with flags 0x%x\n",
382 sta ? sta->addr : NULL,
383 sta ? sta->deflink.supp_rates[sband->band] : -1,
400 struct sta_info *sta;
416 sta = container_of(pubsta, struct sta_info, sta);
417 if (ieee80211_vif_is_mesh(&sta->sdata->vif))
718 static void rate_control_fill_sta_table(struct ieee80211_sta *sta,
726 if (sta && !info->control.skip_table)
727 ratetbl = rcu_dereference(sta->rates);
729 /* Fill remaining rate slots with data from the sta rate table. */
758 struct ieee80211_sta *sta, u32 *mask,
788 if (sta) {
793 *mask &= sta->deflink.supp_rates[sband->band];
795 mcs_mask[i] &= sta->deflink.ht_cap.mcs.rx_mask[i];
797 sta_vht_cap = sta->deflink.vht_cap.vht_mcs.rx_mcs_map;
807 rate_control_apply_mask_ratetbl(struct sta_info *sta,
817 if (!rate_control_cap_mask(sta->sdata, sband, &sta->sta, &mask,
821 chan_width = sta->sdata->vif.bss_conf.chanreq.oper.width;
833 struct ieee80211_sta *sta,
849 if (!rate_control_cap_mask(sdata, sband, sta, &mask, mcs_mask,
872 struct ieee80211_sta *sta,
882 rate_control_fill_sta_table(sta, info, dest, max_rates);
891 rate_control_apply_mask(sdata, sta, sband, dest, max_rates);
897 __rate_control_send_low(&sdata->local->hw, sband, sta, info,
900 if (sta)
906 struct sta_info *sta,
921 if (rate_control_send_low(sta ? &sta->sta : NULL, txrc))
927 if (sta && test_sta_flag(sta, WLAN_STA_RATE_CONTROL)) {
928 ista = &sta->sta;
929 priv_sta = sta->rate_ctrl_priv;
933 spin_lock_bh(&sta->rate_ctrl_lock);
935 spin_unlock_bh(&sta->rate_ctrl_lock);
952 struct sta_info *sta = container_of(pubsta, struct sta_info, sta);
956 sband = ieee80211_get_sband(sta->sdata);
959 rate_control_apply_mask_ratetbl(sta, sband, rates);
971 if (sta->uploaded)
972 drv_sta_rate_tbl_update(hw_to_local(hw), sta->sdata, pubsta);
974 ieee80211_sta_set_expected_throughput(pubsta, sta_get_expected_throughput(sta));