Lines Matching refs:sta
317 if (tx->sta) in ieee80211_tx_h_check_assoc()
318 assoc = test_sta_flag(tx->sta, WLAN_STA_ASSOC); in ieee80211_tx_h_check_assoc()
352 struct sta_info *sta; in purge_old_ps_buffers() local
376 list_for_each_entry_rcu(sta, &local->sta_list, list) { in purge_old_ps_buffers()
380 skb = skb_dequeue(&sta->ps_tx_buf[ac]); in purge_old_ps_buffers()
381 total += skb_queue_len(&sta->ps_tx_buf[ac]); in purge_old_ps_buffers()
459 static int ieee80211_use_mfp(__le16 fc, struct sta_info *sta, in ieee80211_use_mfp() argument
465 if (sta == NULL || !test_sta_flag(sta, WLAN_STA_MFP)) in ieee80211_use_mfp()
477 struct sta_info *sta = tx->sta; in ieee80211_tx_h_unicast_ps_buf() local
482 if (unlikely(!sta)) in ieee80211_tx_h_unicast_ps_buf()
485 if (unlikely((test_sta_flag(sta, WLAN_STA_PS_STA) || in ieee80211_tx_h_unicast_ps_buf()
486 test_sta_flag(sta, WLAN_STA_PS_DRIVER) || in ieee80211_tx_h_unicast_ps_buf()
487 test_sta_flag(sta, WLAN_STA_PS_DELIVER)) && in ieee80211_tx_h_unicast_ps_buf()
497 ps_dbg(sta->sdata, "STA %pM aid %d: PS buffer for AC %d\n", in ieee80211_tx_h_unicast_ps_buf()
498 sta->sta.addr, sta->sta.aid, ac); in ieee80211_tx_h_unicast_ps_buf()
503 spin_lock(&sta->ps_lock); in ieee80211_tx_h_unicast_ps_buf()
509 if (!test_sta_flag(sta, WLAN_STA_PS_STA) && in ieee80211_tx_h_unicast_ps_buf()
510 !test_sta_flag(sta, WLAN_STA_PS_DRIVER) && in ieee80211_tx_h_unicast_ps_buf()
511 !test_sta_flag(sta, WLAN_STA_PS_DELIVER)) { in ieee80211_tx_h_unicast_ps_buf()
512 spin_unlock(&sta->ps_lock); in ieee80211_tx_h_unicast_ps_buf()
516 if (skb_queue_len(&sta->ps_tx_buf[ac]) >= STA_MAX_TX_BUFFER) { in ieee80211_tx_h_unicast_ps_buf()
517 struct sk_buff *old = skb_dequeue(&sta->ps_tx_buf[ac]); in ieee80211_tx_h_unicast_ps_buf()
520 sta->sta.addr, ac); in ieee80211_tx_h_unicast_ps_buf()
529 skb_queue_tail(&sta->ps_tx_buf[ac], tx->skb); in ieee80211_tx_h_unicast_ps_buf()
530 spin_unlock(&sta->ps_lock); in ieee80211_tx_h_unicast_ps_buf()
541 sta_info_recalc_tim(sta); in ieee80211_tx_h_unicast_ps_buf()
544 } else if (unlikely(test_sta_flag(sta, WLAN_STA_PS_STA))) { in ieee80211_tx_h_unicast_ps_buf()
547 sta->sta.addr); in ieee80211_tx_h_unicast_ps_buf()
621 if (tx->sta && in ieee80211_tx_h_select_key()
622 (key = rcu_dereference(tx->sta->ptk[tx->sta->ptk_idx]))) in ieee80211_tx_h_select_key()
649 !ieee80211_use_mfp(hdr->frame_control, tx->sta, in ieee80211_tx_h_select_key()
675 } else if (ieee80211_is_data_present(hdr->frame_control) && tx->sta && in ieee80211_tx_h_select_key()
676 test_sta_flag(tx->sta, WLAN_STA_USES_ENCRYPTION)) { in ieee80211_tx_h_select_key()
735 (tx->sta && test_sta_flag(tx->sta, WLAN_STA_SHORT_PREAMBLE)))) in ieee80211_tx_h_rate_ctrl()
744 if (tx->sta) in ieee80211_tx_h_rate_ctrl()
745 assoc = test_sta_flag(tx->sta, WLAN_STA_ASSOC); in ieee80211_tx_h_rate_ctrl()
752 !rate_usable_index_exists(sband, &tx->sta->sta), in ieee80211_tx_h_rate_ctrl()
765 rate_control_get_rate(tx->sdata, tx->sta, &txrc); in ieee80211_tx_h_rate_ctrl()
767 if (tx->sta && !info->control.skip_table) in ieee80211_tx_h_rate_ctrl()
768 ratetbl = rcu_dereference(tx->sta->sta.rates); in ieee80211_tx_h_rate_ctrl()
791 if (tx->sta && ieee80211_is_tx_data(tx->skb)) in ieee80211_tx_h_rate_ctrl()
792 tx->sta->deflink.tx_stats.last_rate = txrc.reported_rate; in ieee80211_tx_h_rate_ctrl()
793 } else if (tx->sta) in ieee80211_tx_h_rate_ctrl()
794 tx->sta->deflink.tx_stats.last_rate = txrc.reported_rate; in ieee80211_tx_h_rate_ctrl()
809 static __le16 ieee80211_tx_next_seq(struct sta_info *sta, int tid) in ieee80211_tx_next_seq() argument
811 u16 *seq = &sta->tid_seq[tid]; in ieee80211_tx_next_seq()
870 if (tx->sta) in ieee80211_tx_h_sequence()
871 tx->sta->deflink.tx_stats.msdu[IEEE80211_NUM_TIDS]++; in ieee80211_tx_h_sequence()
880 if (!tx->sta) in ieee80211_tx_h_sequence()
885 tx->sta->deflink.tx_stats.msdu[tid]++; in ieee80211_tx_h_sequence()
887 hdr->seq_ctrl = ieee80211_tx_next_seq(tx->sta, tid); in ieee80211_tx_h_sequence()
1033 if (!tx->sta) in ieee80211_tx_h_stats()
1038 tx->sta->deflink.tx_stats.bytes[ac] += skb->len; in ieee80211_tx_h_stats()
1041 tx->sta->deflink.tx_stats.packets[ac]++; in ieee80211_tx_h_stats()
1124 } else if (!tx->sta->sta.txq[tid]) { in ieee80211_tx_prep_agg()
1125 spin_lock(&tx->sta->lock); in ieee80211_tx_prep_agg()
1144 tid_tx = rcu_dereference_protected_tid_tx(tx->sta, tid); in ieee80211_tx_prep_agg()
1153 clear_sta_flag(tx->sta, WLAN_STA_SP); in ieee80211_tx_prep_agg()
1154 ps_dbg(tx->sta->sdata, in ieee80211_tx_prep_agg()
1156 tx->sta->sta.addr, tx->sta->sta.aid); in ieee80211_tx_prep_agg()
1165 spin_unlock(&tx->sta->lock); in ieee80211_tx_prep_agg()
1179 struct sta_info *sta, struct sk_buff *skb) in ieee80211_aggr_check() argument
1187 if (!sta || !sta->sta.deflink.ht_cap.ht_supported || in ieee80211_aggr_check()
1188 !sta->sta.wme || skb_get_queue_mapping(skb) == IEEE80211_AC_VO || in ieee80211_aggr_check()
1193 if (likely(sta->ampdu_mlme.tid_tx[tid])) in ieee80211_aggr_check()
1196 ieee80211_start_tx_ba_session(&sta->sta, tid, 0); in ieee80211_aggr_check()
1207 struct sta_info *sta, struct sk_buff *skb) in ieee80211_tx_prepare() argument
1230 if (likely(sta)) { in ieee80211_tx_prepare()
1231 if (!IS_ERR(sta)) in ieee80211_tx_prepare()
1232 tx->sta = sta; in ieee80211_tx_prepare()
1235 tx->sta = rcu_dereference(sdata->u.vlan.sta); in ieee80211_tx_prepare()
1236 if (!tx->sta && sdata->wdev.use_4addr) in ieee80211_tx_prepare()
1239 tx->sta = sta_info_get_bss(sdata, hdr->addr1); in ieee80211_tx_prepare()
1241 if (!tx->sta && !is_multicast_ether_addr(hdr->addr1)) { in ieee80211_tx_prepare()
1242 tx->sta = sta_info_get(sdata, hdr->addr1); in ieee80211_tx_prepare()
1247 if (tx->sta && ieee80211_is_data_qos(hdr->frame_control) && in ieee80211_tx_prepare()
1254 tid_tx = rcu_dereference(tx->sta->ampdu_mlme.tid_tx[tid]); in ieee80211_tx_prepare()
1256 ieee80211_aggr_check(sdata, tx->sta, skb); in ieee80211_tx_prepare()
1257 tid_tx = rcu_dereference(tx->sta->ampdu_mlme.tid_tx[tid]); in ieee80211_tx_prepare()
1284 if (!tx->sta) in ieee80211_tx_prepare()
1286 else if (test_and_clear_sta_flag(tx->sta, WLAN_STA_CLEAR_PS_FILT)) { in ieee80211_tx_prepare()
1288 ieee80211_check_fast_xmit(tx->sta); in ieee80211_tx_prepare()
1298 struct sta_info *sta, in ieee80211_get_txq() argument
1314 sta && sta->uploaded) { in ieee80211_get_txq()
1319 txq = sta->sta.txq[IEEE80211_NUM_TIDS]; in ieee80211_get_txq()
1321 } else if (sta) { in ieee80211_get_txq()
1324 if (!sta->uploaded) in ieee80211_get_txq()
1327 txq = sta->sta.txq[tid]; in ieee80211_get_txq()
1408 if (txqi->txq.sta) { in fq_tin_dequeue_func()
1409 struct sta_info *sta = container_of(txqi->txq.sta, in fq_tin_dequeue_func() local
1410 struct sta_info, sta); in fq_tin_dequeue_func()
1411 cparams = &sta->cparams; in fq_tin_dequeue_func()
1506 struct sta_info *sta, in ieee80211_txq_init() argument
1517 if (!sta) { in ieee80211_txq_init()
1541 txqi->txq.sta = &sta->sta; in ieee80211_txq_init()
1543 sta->sta.txq[tid] = &txqi->txq; in ieee80211_txq_init()
1645 struct sta_info *sta, in ieee80211_queue_skb() argument
1659 txqi = ieee80211_get_txq(local, vif, sta, skb); in ieee80211_queue_skb()
1673 struct sta_info *sta, in ieee80211_tx_frags() argument
1735 control.sta = sta ? &sta->sta : NULL; in ieee80211_tx_frags()
1748 struct sk_buff_head *skbs, struct sta_info *sta, in __ieee80211_tx() argument
1763 if (sta && !sta->uploaded) in __ieee80211_tx()
1764 sta = NULL; in __ieee80211_tx()
1792 result = ieee80211_tx_frags(local, vif, sta, skbs, txpending); in __ieee80211_tx()
1895 int band, struct ieee80211_sta **sta) in ieee80211_tx_prepare_skb() argument
1912 if (sta) { in ieee80211_tx_prepare_skb()
1913 if (tx.sta) in ieee80211_tx_prepare_skb()
1914 *sta = &tx.sta->sta; in ieee80211_tx_prepare_skb()
1916 *sta = NULL; in ieee80211_tx_prepare_skb()
1935 struct sta_info *sta, struct sk_buff *skb, in ieee80211_tx() argument
1950 res_prepare = ieee80211_tx_prepare(sdata, &tx, sta, skb); in ieee80211_tx()
1968 if (ieee80211_queue_skb(local, sdata, tx.sta, tx.skb)) in ieee80211_tx()
1972 result = __ieee80211_tx(local, &tx.skbs, tx.sta, txpending); in ieee80211_tx()
2023 struct sta_info *sta, struct sk_buff *skb) in ieee80211_xmit() argument
2064 ieee80211_tx(sdata, sta, skb, false); in ieee80211_xmit()
2458 struct sta_info *sta; in ieee80211_lookup_ra_sta() local
2462 sta = rcu_dereference(sdata->u.vlan.sta); in ieee80211_lookup_ra_sta()
2463 if (sta) { in ieee80211_lookup_ra_sta()
2464 *sta_out = sta; in ieee80211_lookup_ra_sta()
2477 sta = sta_info_get_bss(sdata, skb->data); in ieee80211_lookup_ra_sta()
2487 sta = sta_info_get(sdata, skb->data); in ieee80211_lookup_ra_sta()
2488 if (sta && test_sta_flag(sta, WLAN_STA_TDLS_PEER)) { in ieee80211_lookup_ra_sta()
2489 if (test_sta_flag(sta, in ieee80211_lookup_ra_sta()
2491 *sta_out = sta; in ieee80211_lookup_ra_sta()
2508 sta = sta_info_get(sdata, sdata->vif.cfg.ap_addr); in ieee80211_lookup_ra_sta()
2509 if (!sta) in ieee80211_lookup_ra_sta()
2516 *sta_out = sta ?: ERR_PTR(-ENOENT); in ieee80211_lookup_ra_sta()
2580 struct sta_info *sta, u32 ctrl_flags, in ieee80211_build_hdr() argument
2602 if (IS_ERR(sta)) in ieee80211_build_hdr()
2603 sta = NULL; in ieee80211_build_hdr()
2624 memcpy(hdr.addr1, sta->sta.addr, ETH_ALEN); in ieee80211_build_hdr()
2629 authorized = test_sta_flag(sta, WLAN_STA_AUTHORIZED); in ieee80211_build_hdr()
2630 wme_sta = sta->sta.wme; in ieee80211_build_hdr()
2650 if (ieee80211_vif_is_mld(&sdata->vif) && sta && !sta->sta.mlo) { in ieee80211_build_hdr()
2653 link_id = sta->deflink.link_id; in ieee80211_build_hdr()
2661 (sta && sta->sta.mlo)) { in ieee80211_build_hdr()
2755 tdls_peer = test_sta_flag(sta, WLAN_STA_TDLS_PEER); in ieee80211_build_hdr()
2759 int tdls_link_id = sta->sta.valid_links ? in ieee80211_build_hdr()
2760 __ffs(sta->sta.valid_links) : 0; in ieee80211_build_hdr()
2825 if (sta) { in ieee80211_build_hdr()
2826 authorized = test_sta_flag(sta, WLAN_STA_AUTHORIZED); in ieee80211_build_hdr()
2827 wme_sta = sta->sta.wme; in ieee80211_build_hdr()
3004 void ieee80211_check_fast_xmit(struct sta_info *sta) in ieee80211_check_fast_xmit() argument
3007 struct ieee80211_local *local = sta->local; in ieee80211_check_fast_xmit()
3008 struct ieee80211_sub_if_data *sdata = sta->sdata; in ieee80211_check_fast_xmit()
3017 mesh_fast_tx_flush_sta(sdata, sta); in ieee80211_check_fast_xmit()
3031 spin_lock_bh(&sta->lock); in ieee80211_check_fast_xmit()
3037 if (!test_sta_flag(sta, WLAN_STA_AUTHORIZED)) in ieee80211_check_fast_xmit()
3040 if (test_sta_flag(sta, WLAN_STA_PS_STA) || in ieee80211_check_fast_xmit()
3041 test_sta_flag(sta, WLAN_STA_PS_DRIVER) || in ieee80211_check_fast_xmit()
3042 test_sta_flag(sta, WLAN_STA_PS_DELIVER) || in ieee80211_check_fast_xmit()
3043 test_sta_flag(sta, WLAN_STA_CLEAR_PS_FILT)) in ieee80211_check_fast_xmit()
3080 if (test_sta_flag(sta, WLAN_STA_TDLS_PEER)) { in ieee80211_check_fast_xmit()
3082 int tdls_link_id = sta->sta.valid_links ? in ieee80211_check_fast_xmit()
3083 __ffs(sta->sta.valid_links) : 0; in ieee80211_check_fast_xmit()
3121 memcpy(hdr->addr1, sta->sta.addr, ETH_ALEN); in ieee80211_check_fast_xmit()
3133 if (sta->sta.mlo || !ieee80211_vif_is_mld(&sdata->vif)) { in ieee80211_check_fast_xmit()
3136 unsigned int link_id = sta->deflink.link_id; in ieee80211_check_fast_xmit()
3156 if (sta->sta.wme) { in ieee80211_check_fast_xmit()
3166 build.key = rcu_access_pointer(sta->ptk[sta->ptk_idx]); in ieee80211_check_fast_xmit()
3244 old = rcu_dereference_protected(sta->fast_tx, in ieee80211_check_fast_xmit()
3245 lockdep_is_held(&sta->lock)); in ieee80211_check_fast_xmit()
3246 rcu_assign_pointer(sta->fast_tx, fast_tx); in ieee80211_check_fast_xmit()
3249 spin_unlock_bh(&sta->lock); in ieee80211_check_fast_xmit()
3254 struct sta_info *sta; in ieee80211_check_fast_xmit_all() local
3257 list_for_each_entry_rcu(sta, &local->sta_list, list) in ieee80211_check_fast_xmit_all()
3258 ieee80211_check_fast_xmit(sta); in ieee80211_check_fast_xmit_all()
3265 struct sta_info *sta; in ieee80211_check_fast_xmit_iface() local
3269 list_for_each_entry_rcu(sta, &local->sta_list, list) { in ieee80211_check_fast_xmit_iface()
3270 if (sdata != sta->sdata && in ieee80211_check_fast_xmit_iface()
3271 (!sta->sdata->bss || sta->sdata->bss != sdata->bss)) in ieee80211_check_fast_xmit_iface()
3273 ieee80211_check_fast_xmit(sta); in ieee80211_check_fast_xmit_iface()
3279 void ieee80211_clear_fast_xmit(struct sta_info *sta) in ieee80211_clear_fast_xmit() argument
3283 spin_lock_bh(&sta->lock); in ieee80211_clear_fast_xmit()
3284 fast_tx = rcu_dereference_protected(sta->fast_tx, in ieee80211_clear_fast_xmit()
3285 lockdep_is_held(&sta->lock)); in ieee80211_clear_fast_xmit()
3286 RCU_INIT_POINTER(sta->fast_tx, NULL); in ieee80211_clear_fast_xmit()
3287 spin_unlock_bh(&sta->lock); in ieee80211_clear_fast_xmit()
3377 struct sta_info *sta, in ieee80211_amsdu_aggregate() argument
3387 struct ieee80211_txq *txq = sta->sta.txq[tid]; in ieee80211_amsdu_aggregate()
3391 u8 max_subframes = sta->sta.max_amsdu_subframes; in ieee80211_amsdu_aggregate()
3393 int max_amsdu_len = sta->sta.cur->max_amsdu_len; in ieee80211_amsdu_aggregate()
3422 if (sta->sta.cur->max_rc_amsdu_len) in ieee80211_amsdu_aggregate()
3424 sta->sta.cur->max_rc_amsdu_len); in ieee80211_amsdu_aggregate()
3426 if (sta->sta.cur->max_tid_amsdu_len[tid]) in ieee80211_amsdu_aggregate()
3428 sta->sta.cur->max_tid_amsdu_len[tid]); in ieee80211_amsdu_aggregate()
3528 struct sta_info *sta, u8 pn_offs, in ieee80211_xmit_fast_finish() argument
3548 hdr->seq_ctrl = ieee80211_tx_next_seq(sta, tid); in ieee80211_xmit_fast_finish()
3556 sta->deflink.tx_stats.msdu[tid] += in ieee80211_xmit_fast_finish()
3559 sta->deflink.tx_stats.msdu[tid]++; in ieee80211_xmit_fast_finish()
3566 sta->deflink.tx_stats.bytes[skb_get_queue_mapping(skb)] += skb->len; in ieee80211_xmit_fast_finish()
3567 sta->deflink.tx_stats.packets[skb_get_queue_mapping(skb)]++; in ieee80211_xmit_fast_finish()
3646 struct sta_info *sta, in __ieee80211_xmit_fast() argument
3664 ieee80211_amsdu_aggregate(sdata, sta, fast_tx, skb, da, sa)) in __ieee80211_xmit_fast()
3708 tx.sta = sta; in __ieee80211_xmit_fast()
3711 if (ieee80211_queue_skb(local, sdata, sta, skb)) in __ieee80211_xmit_fast()
3715 r = ieee80211_xmit_fast_finish(sdata, sta, fast_tx->pn_offs, in __ieee80211_xmit_fast()
3726 ieee80211_tx_frags(local, &sdata->vif, sta, &tx.skbs, false); in __ieee80211_xmit_fast()
3734 struct sta_info *sta, in ieee80211_xmit_fast() argument
3759 tid_tx = rcu_dereference(sta->ampdu_mlme.tid_tx[tid]); in ieee80211_xmit_fast()
3777 __ieee80211_xmit_fast(sdata, sta, fast_tx, skb, tid_tx, in ieee80211_xmit_fast()
3848 if (txq->sta) { in ieee80211_tx_dequeue()
3849 tx.sta = container_of(txq->sta, struct sta_info, sta); in ieee80211_tx_dequeue()
3859 !test_sta_flag(tx.sta, WLAN_STA_AUTHORIZED) && in ieee80211_tx_dequeue()
3896 struct sta_info *sta = container_of(txq->sta, struct sta_info, in ieee80211_tx_dequeue() local
3897 sta); in ieee80211_tx_dequeue()
3904 r = ieee80211_xmit_fast_finish(sta->sdata, sta, pn_offs, in ieee80211_tx_dequeue()
3961 if (tx.sta && in ieee80211_tx_dequeue()
3966 airtime = ieee80211_calc_expected_tx_airtime(hw, vif, txq->sta, in ieee80211_tx_dequeue()
3970 ieee80211_sta_update_pending_airtime(local, tx.sta, in ieee80211_tx_dequeue()
3986 static inline s32 ieee80211_sta_deficit(struct sta_info *sta, u8 ac) in ieee80211_sta_deficit() argument
3988 struct airtime_info *air_info = &sta->airtime[ac]; in ieee80211_sta_deficit()
3996 struct sta_info *sta; in ieee80211_txq_set_active() local
3998 if (!txqi->txq.sta) in ieee80211_txq_set_active()
4001 sta = container_of(txqi->txq.sta, struct sta_info, sta); in ieee80211_txq_set_active()
4002 sta->airtime[txqi->txq.ac].last_active = (u32)jiffies; in ieee80211_txq_set_active()
4008 struct sta_info *sta; in ieee80211_txq_keep_active() local
4011 if (!txqi->txq.sta) in ieee80211_txq_keep_active()
4014 sta = container_of(txqi->txq.sta, struct sta_info, sta); in ieee80211_txq_keep_active()
4015 if (ieee80211_sta_deficit(sta, txqi->txq.ac) >= 0) in ieee80211_txq_keep_active()
4018 diff = (u32)jiffies - sta->airtime[txqi->txq.ac].last_active; in ieee80211_txq_keep_active()
4052 if (txqi->txq.sta) { in ieee80211_next_txq()
4053 struct sta_info *sta = container_of(txqi->txq.sta, in ieee80211_next_txq() local
4054 struct sta_info, sta); in ieee80211_next_txq()
4056 s32 deficit = ieee80211_sta_deficit(sta, txqi->txq.ac); in ieee80211_next_txq()
4062 sta->airtime[txqi->txq.ac].deficit += in ieee80211_next_txq()
4063 sta->airtime_weight; in ieee80211_next_txq()
4105 if (txqi->txq.sta && local->airtime_flags && has_queue && in __ieee80211_schedule_txq()
4126 struct sta_info *sta; in ieee80211_txq_airtime_check() local
4135 if (!txq->sta) in ieee80211_txq_airtime_check()
4141 sta = container_of(txq->sta, struct sta_info, sta); in ieee80211_txq_airtime_check()
4142 if (atomic_read(&sta->airtime[txq->ac].aql_tx_pending) < in ieee80211_txq_airtime_check()
4143 sta->airtime[txq->ac].aql_limit_low) in ieee80211_txq_airtime_check()
4148 atomic_read(&sta->airtime[txq->ac].aql_tx_pending) < in ieee80211_txq_airtime_check()
4149 sta->airtime[txq->ac].aql_limit_high) in ieee80211_txq_airtime_check()
4180 struct sta_info *sta; in ieee80211_txq_may_transmit() local
4185 if (!txqi->txq.sta) in ieee80211_txq_may_transmit()
4199 if (!iter->txq.sta) { in ieee80211_txq_may_transmit()
4204 sta = container_of(iter->txq.sta, struct sta_info, sta); in ieee80211_txq_may_transmit()
4205 if (ieee80211_sta_deficit(sta, ac) < 0) in ieee80211_txq_may_transmit()
4206 sta->airtime[ac].deficit += sta->airtime_weight; in ieee80211_txq_may_transmit()
4210 sta = container_of(txqi->txq.sta, struct sta_info, sta); in ieee80211_txq_may_transmit()
4211 if (sta->airtime[ac].deficit >= 0) in ieee80211_txq_may_transmit()
4214 sta->airtime[ac].deficit += sta->airtime_weight; in ieee80211_txq_may_transmit()
4254 struct sta_info *sta; in __ieee80211_subif_start_xmit() local
4272 if (ieee80211_lookup_ra_sta(sdata, skb, &sta)) in __ieee80211_subif_start_xmit()
4275 if (IS_ERR(sta)) in __ieee80211_subif_start_xmit()
4276 sta = NULL; in __ieee80211_subif_start_xmit()
4278 skb_set_queue_mapping(skb, ieee80211_select_queue(sdata, sta, skb)); in __ieee80211_subif_start_xmit()
4279 ieee80211_aggr_check(sdata, sta, skb); in __ieee80211_subif_start_xmit()
4281 if (sta) { in __ieee80211_subif_start_xmit()
4284 fast_tx = rcu_dereference(sta->fast_tx); in __ieee80211_subif_start_xmit()
4287 ieee80211_xmit_fast(sdata, sta, fast_tx, skb)) in __ieee80211_subif_start_xmit()
4308 sta, ctrl_flags, cookie); in __ieee80211_subif_start_xmit()
4316 ieee80211_xmit(sdata, sta, skb); in __ieee80211_subif_start_xmit()
4328 static int ieee80211_change_da(struct sk_buff *skb, struct sta_info *sta) in ieee80211_change_da() argument
4338 ether_addr_copy(eth->h_dest, sta->sta.addr); in ieee80211_change_da()
4353 if (sdata->u.vlan.sta) in ieee80211_multicast_to_unicast()
4390 struct sta_info *sta, *first = NULL; in ieee80211_convert_to_unicast() local
4395 list_for_each_entry_rcu(sta, &local->sta_list, list) { in ieee80211_convert_to_unicast()
4396 if (sdata != sta->sdata) in ieee80211_convert_to_unicast()
4399 if (unlikely(ether_addr_equal(eth->h_source, sta->sta.addr))) in ieee80211_convert_to_unicast()
4403 first = sta; in ieee80211_convert_to_unicast()
4409 if (unlikely(ieee80211_change_da(cloned_skb, sta))) { in ieee80211_convert_to_unicast()
4519 struct sk_buff *skb, struct sta_info *sta, in __ieee80211_tx_8023() argument
4545 if (sta && sta->uploaded) in __ieee80211_tx_8023()
4546 pubsta = &sta->sta; in __ieee80211_tx_8023()
4548 control.sta = pubsta; in __ieee80211_tx_8023()
4556 struct sk_buff *skb, struct sta_info *sta, in ieee80211_tx_8023() argument
4563 if (ieee80211_queue_skb(local, sdata, sta, skb)) in ieee80211_tx_8023()
4568 if (!__ieee80211_tx_8023(sdata, skb, sta, txpending)) in ieee80211_tx_8023()
4576 struct net_device *dev, struct sta_info *sta, in ieee80211_8023_xmit() argument
4587 queue = ieee80211_select_queue(sdata, sta, skb); in ieee80211_8023_xmit()
4598 ieee80211_aggr_check(sdata, sta, skb); in ieee80211_8023_xmit()
4601 tid_tx = rcu_dereference(sta->ampdu_mlme.tid_tx[tid]); in ieee80211_8023_xmit()
4647 sta->deflink.tx_stats.packets[queue] += skbs; in ieee80211_8023_xmit()
4648 sta->deflink.tx_stats.bytes[queue] += len; in ieee80211_8023_xmit()
4652 ieee80211_tx_8023(sdata, skb, sta, false); in ieee80211_8023_xmit()
4666 struct sta_info *sta; in ieee80211_subif_start_xmit_8023() local
4675 if (ieee80211_lookup_ra_sta(sdata, skb, &sta)) { in ieee80211_subif_start_xmit_8023()
4680 if (unlikely(IS_ERR_OR_NULL(sta) || !sta->uploaded || in ieee80211_subif_start_xmit_8023()
4681 !test_sta_flag(sta, WLAN_STA_AUTHORIZED) || in ieee80211_subif_start_xmit_8023()
4685 key = rcu_dereference(sta->ptk[sta->ptk_idx]); in ieee80211_subif_start_xmit_8023()
4694 ieee80211_8023_xmit(sdata, dev, sta, key, skb); in ieee80211_subif_start_xmit_8023()
4714 struct sta_info *sta; in ieee80211_build_data_template() local
4718 if (ieee80211_lookup_ra_sta(sdata, skb, &sta)) { in ieee80211_build_data_template()
4724 skb = ieee80211_build_hdr(sdata, skb, info_flags, sta, in ieee80211_build_data_template()
4730 tx.sta = sta_info_get(sdata, hdr->addr1); in ieee80211_build_data_template()
4769 struct sta_info *sta; in ieee80211_tx_pending_skb() local
4789 if (ieee80211_lookup_ra_sta(sdata, skb, &sta)) { in ieee80211_tx_pending_skb()
4794 if (IS_ERR(sta) || (sta && !sta->uploaded)) in ieee80211_tx_pending_skb()
4795 sta = NULL; in ieee80211_tx_pending_skb()
4797 result = ieee80211_tx_8023(sdata, skb, sta, true); in ieee80211_tx_pending_skb()
4805 sta = sta_info_get(sdata, hdr->addr1); in ieee80211_tx_pending_skb()
4807 result = __ieee80211_tx(local, &skbs, sta, true); in ieee80211_tx_pending_skb()
5724 struct sta_info *sta; in ieee80211_nullfunc_get() local
5726 sta = sta_info_get(sdata, vif->cfg.ap_addr); in ieee80211_nullfunc_get()
5727 qos = sta && sta->sta.wme; in ieee80211_nullfunc_get()
5918 struct sta_info *sta = container_of(pubsta, struct sta_info, sta); in ieee80211_reserve_tid() local
5919 struct ieee80211_sub_if_data *sdata = sta->sdata; in ieee80211_reserve_tid()
5940 if (sta->reserved_tid == tid) { in ieee80211_reserve_tid()
5945 if (sta->reserved_tid != IEEE80211_TID_UNRESERVED) { in ieee80211_reserve_tid()
5958 set_sta_flag(sta, WLAN_STA_BLOCK_BA); in ieee80211_reserve_tid()
5959 __ieee80211_stop_tx_ba_session(sta, tid, in ieee80211_reserve_tid()
5966 sta->reserved_tid = tid; in ieee80211_reserve_tid()
5972 clear_sta_flag(sta, WLAN_STA_BLOCK_BA); in ieee80211_reserve_tid()
5982 struct sta_info *sta = container_of(pubsta, struct sta_info, sta); in ieee80211_unreserve_tid() local
5983 struct ieee80211_sub_if_data *sdata = sta->sdata; in ieee80211_unreserve_tid()
5998 if (tid != sta->reserved_tid) { in ieee80211_unreserve_tid()
6003 sta->reserved_tid = IEEE80211_TID_UNRESERVED; in ieee80211_unreserve_tid()
6099 struct sta_info *sta; in ieee80211_tx_control_port() local
6174 err = ieee80211_lookup_ra_sta(sdata, skb, &sta); in ieee80211_tx_control_port()
6181 if (!IS_ERR(sta)) { in ieee80211_tx_control_port()
6182 u16 queue = ieee80211_select_queue(sdata, sta, skb); in ieee80211_tx_control_port()
6190 if (sta && sta->sta.mlo) in ieee80211_tx_control_port()