1
0
Fork 0
mirror of synced 2025-03-06 20:59:54 +01:00

wifi: mac80211: change QoS settings API to take link into account

Take the link into account in the QoS settings (EDCA parameters)
APIs.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
Johannes Berg 2022-06-24 15:40:11 +02:00
parent 8c7c6b5819
commit b3e2130bf5
55 changed files with 158 additions and 104 deletions

View file

@ -7814,7 +7814,8 @@ exit:
} }
static int ath10k_conf_tx(struct ieee80211_hw *hw, static int ath10k_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 ac, struct ieee80211_vif *vif,
unsigned int link_id, u16 ac,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct ath10k *ar = hw->priv; struct ath10k *ar = hw->priv;

View file

@ -4822,7 +4822,8 @@ exit:
} }
static int ath11k_mac_op_conf_tx(struct ieee80211_hw *hw, static int ath11k_mac_op_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 ac, struct ieee80211_vif *vif,
unsigned int link_id, u16 ac,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct ath11k *ar = hw->priv; struct ath11k *ar = hw->priv;

View file

@ -572,7 +572,8 @@ ath5k_get_stats(struct ieee80211_hw *hw,
static int static int
ath5k_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, u16 queue, ath5k_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct ath5k_hw *ah = hw->priv; struct ath5k_hw *ah = hw->priv;

View file

@ -1369,7 +1369,8 @@ static void ath9k_htc_sta_rc_update(struct ieee80211_hw *hw,
} }
static int ath9k_htc_conf_tx(struct ieee80211_hw *hw, static int ath9k_htc_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct ath9k_htc_priv *priv = hw->priv; struct ath9k_htc_priv *priv = hw->priv;

View file

@ -1712,7 +1712,8 @@ static void ath9k_sta_notify(struct ieee80211_hw *hw,
} }
static int ath9k_conf_tx(struct ieee80211_hw *hw, static int ath9k_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct ath_softc *sc = hw->priv; struct ath_softc *sc = hw->priv;

View file

@ -1365,7 +1365,8 @@ static int carl9170_op_sta_remove(struct ieee80211_hw *hw,
} }
static int carl9170_op_conf_tx(struct ieee80211_hw *hw, static int carl9170_op_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *param) const struct ieee80211_tx_queue_params *param)
{ {
struct ar9170 *ar = hw->priv; struct ar9170 *ar = hw->priv;

View file

@ -3783,7 +3783,8 @@ static void b43_qos_init(struct b43_wldev *dev)
} }
static int b43_op_conf_tx(struct ieee80211_hw *hw, static int b43_op_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 _queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 _queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct b43_wl *wl = hw_to_b43_wl(hw); struct b43_wl *wl = hw_to_b43_wl(hw);

View file

@ -2505,7 +2505,8 @@ static void b43legacy_op_tx(struct ieee80211_hw *hw,
} }
static int b43legacy_op_conf_tx(struct ieee80211_hw *hw, static int b43legacy_op_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
return 0; return 0;

View file

@ -787,7 +787,8 @@ static void brcms_ops_sw_scan_complete(struct ieee80211_hw *hw,
} }
static int static int
brcms_ops_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, u16 queue, brcms_ops_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct brcms_info *wl = hw->priv; struct brcms_info *wl = hw->priv;

View file

@ -4480,7 +4480,8 @@ il_clear_isr_stats(struct il_priv *il)
} }
int int
il_mac_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, u16 queue, il_mac_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct il_priv *il = hw->priv; struct il_priv *il = hw->priv;

View file

@ -1683,7 +1683,8 @@ struct il_cfg {
***************************/ ***************************/
int il_mac_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, int il_mac_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
u16 queue, const struct ieee80211_tx_queue_params *params); unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params);
int il_mac_tx_last_beacon(struct ieee80211_hw *hw); int il_mac_tx_last_beacon(struct ieee80211_hw *hw);
void il_set_rxon_hwcrypto(struct il_priv *il, int hw_decrypt); void il_set_rxon_hwcrypto(struct il_priv *il, int hw_decrypt);

View file

@ -2,7 +2,7 @@
/****************************************************************************** /******************************************************************************
* *
* Copyright(c) 2003 - 2014 Intel Corporation. All rights reserved. * Copyright(c) 2003 - 2014 Intel Corporation. All rights reserved.
* Copyright (C) 2018 - 2019 Intel Corporation * Copyright (C) 2018 - 2019, 2022 Intel Corporation
* *
* Portions of this file are derived from the ipw3945 project, as well * Portions of this file are derived from the ipw3945 project, as well
* as portions of the ieee80211 subsystem header files. * as portions of the ieee80211 subsystem header files.
@ -1153,7 +1153,8 @@ static int iwlagn_mac_set_tim(struct ieee80211_hw *hw,
} }
static int iwlagn_mac_conf_tx(struct ieee80211_hw *hw, static int iwlagn_mac_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct iwl_priv *priv = IWL_MAC80211_GET_DVM(hw); struct iwl_priv *priv = IWL_MAC80211_GET_DVM(hw);

View file

@ -3349,7 +3349,8 @@ static void iwl_mvm_sta_rc_update(struct ieee80211_hw *hw,
} }
static int iwl_mvm_mac_conf_tx(struct ieee80211_hw *hw, static int iwl_mvm_mac_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 ac, struct ieee80211_vif *vif,
unsigned int link_id, u16 ac,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct iwl_mvm *mvm = IWL_MAC80211_GET_MVM(hw); struct iwl_mvm *mvm = IWL_MAC80211_GET_MVM(hw);

View file

@ -404,7 +404,8 @@ static void p54_configure_filter(struct ieee80211_hw *dev,
} }
static int p54_conf_tx(struct ieee80211_hw *dev, static int p54_conf_tx(struct ieee80211_hw *dev,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct p54_common *priv = dev->priv; struct p54_common *priv = dev->priv;

View file

@ -2340,9 +2340,9 @@ static int mac80211_hwsim_set_tim(struct ieee80211_hw *hw,
return 0; return 0;
} }
static int mac80211_hwsim_conf_tx( static int mac80211_hwsim_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_hw *hw, struct ieee80211_vif *vif,
struct ieee80211_vif *vif, u16 queue, unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
wiphy_dbg(hw->wiphy, wiphy_dbg(hw->wiphy,

View file

@ -5365,7 +5365,8 @@ static int mwl8k_sta_add(struct ieee80211_hw *hw,
} }
static int mwl8k_conf_tx(struct ieee80211_hw *hw, static int mwl8k_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct mwl8k_priv *priv = hw->priv; struct mwl8k_priv *priv = hw->priv;
@ -6050,7 +6051,7 @@ static int mwl8k_reload_firmware(struct ieee80211_hw *hw, char *fw_image)
goto fail; goto fail;
for (i = 0; i < MWL8K_TX_WMM_QUEUES; i++) { for (i = 0; i < MWL8K_TX_WMM_QUEUES; i++) {
rc = mwl8k_conf_tx(hw, NULL, i, &priv->wmm_params[i]); rc = mwl8k_conf_tx(hw, NULL, 0, i, &priv->wmm_params[i]);
if (rc) if (rc)
goto fail; goto fail;
} }

View file

@ -527,7 +527,8 @@ mt7603_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd,
} }
static int static int
mt7603_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, u16 queue, mt7603_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct mt7603_dev *dev = hw->priv; struct mt7603_dev *dev = hw->priv;

View file

@ -494,7 +494,8 @@ static int mt7615_config(struct ieee80211_hw *hw, u32 changed)
} }
static int static int
mt7615_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, u16 queue, mt7615_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct mt76_vif *mvif = (struct mt76_vif *)vif->drv_priv; struct mt76_vif *mvif = (struct mt76_vif *)vif->drv_priv;

View file

@ -156,7 +156,8 @@ int mt76x02_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd,
struct ieee80211_vif *vif, struct ieee80211_sta *sta, struct ieee80211_vif *vif, struct ieee80211_sta *sta,
struct ieee80211_key_conf *key); struct ieee80211_key_conf *key);
int mt76x02_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, int mt76x02_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
u16 queue, const struct ieee80211_tx_queue_params *params); unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params);
void mt76x02_sta_rate_tbl_update(struct ieee80211_hw *hw, void mt76x02_sta_rate_tbl_update(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, struct ieee80211_vif *vif,
struct ieee80211_sta *sta); struct ieee80211_sta *sta);

View file

@ -487,7 +487,8 @@ int mt76x02_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd,
EXPORT_SYMBOL_GPL(mt76x02_set_key); EXPORT_SYMBOL_GPL(mt76x02_set_key);
int mt76x02_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, int mt76x02_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
u16 queue, const struct ieee80211_tx_queue_params *params) unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params)
{ {
struct mt76x02_dev *dev = hw->priv; struct mt76x02_dev *dev = hw->priv;
u8 cw_min = 5, cw_max = 10, qid; u8 cw_min = 5, cw_max = 10, qid;

View file

@ -478,7 +478,8 @@ static int mt7915_config(struct ieee80211_hw *hw, u32 changed)
} }
static int static int
mt7915_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, u16 queue, mt7915_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct mt7915_vif *mvif = (struct mt7915_vif *)vif->drv_priv; struct mt7915_vif *mvif = (struct mt7915_vif *)vif->drv_priv;

View file

@ -567,7 +567,8 @@ out:
} }
static int static int
mt7921_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, u16 queue, mt7921_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct mt7921_vif *mvif = (struct mt7921_vif *)vif->drv_priv; struct mt7921_vif *mvif = (struct mt7921_vif *)vif->drv_priv;

View file

@ -368,7 +368,8 @@ void mt7601u_mac_set_ampdu_factor(struct mt7601u_dev *dev);
void mt7601u_tx(struct ieee80211_hw *hw, struct ieee80211_tx_control *control, void mt7601u_tx(struct ieee80211_hw *hw, struct ieee80211_tx_control *control,
struct sk_buff *skb); struct sk_buff *skb);
int mt7601u_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, int mt7601u_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
u16 queue, const struct ieee80211_tx_queue_params *params); unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params);
void mt7601u_tx_status(struct mt7601u_dev *dev, struct sk_buff *skb); void mt7601u_tx_status(struct mt7601u_dev *dev, struct sk_buff *skb);
void mt7601u_tx_stat(struct work_struct *work); void mt7601u_tx_stat(struct work_struct *work);

View file

@ -258,7 +258,8 @@ void mt7601u_tx_stat(struct work_struct *work)
} }
int mt7601u_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, int mt7601u_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
u16 queue, const struct ieee80211_tx_queue_params *params) unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params)
{ {
struct mt7601u_dev *dev = hw->priv; struct mt7601u_dev *dev = hw->priv;
u8 cw_min = 5, cw_max = 10, hw_q = q2hwq(queue); u8 cw_min = 5, cw_max = 10, hw_q = q2hwq(queue);

View file

@ -1654,7 +1654,8 @@ static int rt2400pci_probe_hw(struct rt2x00_dev *rt2x00dev)
* IEEE80211 stack callback functions. * IEEE80211 stack callback functions.
*/ */
static int rt2400pci_conf_tx(struct ieee80211_hw *hw, static int rt2400pci_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct rt2x00_dev *rt2x00dev = hw->priv; struct rt2x00_dev *rt2x00dev = hw->priv;
@ -1667,7 +1668,7 @@ static int rt2400pci_conf_tx(struct ieee80211_hw *hw,
if (queue != 0) if (queue != 0)
return -EINVAL; return -EINVAL;
if (rt2x00mac_conf_tx(hw, vif, queue, params)) if (rt2x00mac_conf_tx(hw, vif, link_id, queue, params))
return -EINVAL; return -EINVAL;
/* /*

View file

@ -10395,7 +10395,8 @@ int rt2800_set_rts_threshold(struct ieee80211_hw *hw, u32 value)
EXPORT_SYMBOL_GPL(rt2800_set_rts_threshold); EXPORT_SYMBOL_GPL(rt2800_set_rts_threshold);
int rt2800_conf_tx(struct ieee80211_hw *hw, int rt2800_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue_idx, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue_idx,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct rt2x00_dev *rt2x00dev = hw->priv; struct rt2x00_dev *rt2x00dev = hw->priv;
@ -10411,7 +10412,7 @@ int rt2800_conf_tx(struct ieee80211_hw *hw,
* we are free to update the registers based on the value * we are free to update the registers based on the value
* in the queue parameter. * in the queue parameter.
*/ */
retval = rt2x00mac_conf_tx(hw, vif, queue_idx, params); retval = rt2x00mac_conf_tx(hw, vif, link_id, queue_idx, params);
if (retval) if (retval)
return retval; return retval;

View file

@ -245,7 +245,8 @@ void rt2800_get_key_seq(struct ieee80211_hw *hw,
struct ieee80211_key_seq *seq); struct ieee80211_key_seq *seq);
int rt2800_set_rts_threshold(struct ieee80211_hw *hw, u32 value); int rt2800_set_rts_threshold(struct ieee80211_hw *hw, u32 value);
int rt2800_conf_tx(struct ieee80211_hw *hw, int rt2800_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue_idx, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue_idx,
const struct ieee80211_tx_queue_params *params); const struct ieee80211_tx_queue_params *params);
u64 rt2800_get_tsf(struct ieee80211_hw *hw, struct ieee80211_vif *vif); u64 rt2800_get_tsf(struct ieee80211_hw *hw, struct ieee80211_vif *vif);
int rt2800_ampdu_action(struct ieee80211_hw *hw, struct ieee80211_vif *vif, int rt2800_ampdu_action(struct ieee80211_hw *hw, struct ieee80211_vif *vif,

View file

@ -1481,7 +1481,8 @@ void rt2x00mac_bss_info_changed(struct ieee80211_hw *hw,
struct ieee80211_bss_conf *bss_conf, struct ieee80211_bss_conf *bss_conf,
u64 changes); u64 changes);
int rt2x00mac_conf_tx(struct ieee80211_hw *hw, int rt2x00mac_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params); const struct ieee80211_tx_queue_params *params);
void rt2x00mac_rfkill_poll(struct ieee80211_hw *hw); void rt2x00mac_rfkill_poll(struct ieee80211_hw *hw);
void rt2x00mac_flush(struct ieee80211_hw *hw, struct ieee80211_vif *vif, void rt2x00mac_flush(struct ieee80211_hw *hw, struct ieee80211_vif *vif,

View file

@ -665,7 +665,8 @@ void rt2x00mac_bss_info_changed(struct ieee80211_hw *hw,
EXPORT_SYMBOL_GPL(rt2x00mac_bss_info_changed); EXPORT_SYMBOL_GPL(rt2x00mac_bss_info_changed);
int rt2x00mac_conf_tx(struct ieee80211_hw *hw, int rt2x00mac_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue_idx, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue_idx,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct rt2x00_dev *rt2x00dev = hw->priv; struct rt2x00_dev *rt2x00dev = hw->priv;

View file

@ -2799,7 +2799,8 @@ static int rt61pci_probe_hw(struct rt2x00_dev *rt2x00dev)
* IEEE80211 stack callback functions. * IEEE80211 stack callback functions.
*/ */
static int rt61pci_conf_tx(struct ieee80211_hw *hw, static int rt61pci_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue_idx, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue_idx,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct rt2x00_dev *rt2x00dev = hw->priv; struct rt2x00_dev *rt2x00dev = hw->priv;
@ -2815,7 +2816,7 @@ static int rt61pci_conf_tx(struct ieee80211_hw *hw,
* we are free to update the registers based on the value * we are free to update the registers based on the value
* in the queue parameter. * in the queue parameter.
*/ */
retval = rt2x00mac_conf_tx(hw, vif, queue_idx, params); retval = rt2x00mac_conf_tx(hw, vif, link_id, queue_idx, params);
if (retval) if (retval)
return retval; return retval;

View file

@ -2218,7 +2218,8 @@ static int rt73usb_probe_hw(struct rt2x00_dev *rt2x00dev)
* IEEE80211 stack callback functions. * IEEE80211 stack callback functions.
*/ */
static int rt73usb_conf_tx(struct ieee80211_hw *hw, static int rt73usb_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue_idx, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue_idx,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct rt2x00_dev *rt2x00dev = hw->priv; struct rt2x00_dev *rt2x00dev = hw->priv;
@ -2234,7 +2235,7 @@ static int rt73usb_conf_tx(struct ieee80211_hw *hw,
* we are free to update the registers based on the value * we are free to update the registers based on the value
* in the queue parameter. * in the queue parameter.
*/ */
retval = rt2x00mac_conf_tx(hw, vif, queue_idx, params); retval = rt2x00mac_conf_tx(hw, vif, link_id, queue_idx, params);
if (retval) if (retval)
return retval; return retval;

View file

@ -1424,7 +1424,8 @@ static void rtl8187se_conf_ac_parm(struct ieee80211_hw *dev, u8 queue)
} }
static int rtl8180_conf_tx(struct ieee80211_hw *dev, static int rtl8180_conf_tx(struct ieee80211_hw *dev,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct rtl8180_priv *priv = dev->priv; struct rtl8180_priv *priv = dev->priv;

View file

@ -1338,7 +1338,8 @@ static void rtl8187_configure_filter(struct ieee80211_hw *dev,
} }
static int rtl8187_conf_tx(struct ieee80211_hw *dev, static int rtl8187_conf_tx(struct ieee80211_hw *dev,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct rtl8187_priv *priv = dev->priv; struct rtl8187_priv *priv = dev->priv;

View file

@ -5957,7 +5957,8 @@ exit:
} }
static int rtl8xxxu_conf_tx(struct ieee80211_hw *hw, static int rtl8xxxu_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *param) const struct ieee80211_tx_queue_params *param)
{ {
struct rtl8xxxu_priv *priv = hw->priv; struct rtl8xxxu_priv *priv = hw->priv;

View file

@ -982,7 +982,8 @@ static int _rtl_get_hal_qnum(u16 queue)
*for rtl819x BE = 0, BK = 1, VI = 2, VO = 3 *for rtl819x BE = 0, BK = 1, VI = 2, VO = 3
*/ */
static int rtl_op_conf_tx(struct ieee80211_hw *hw, static int rtl_op_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *param) const struct ieee80211_tx_queue_params *param)
{ {
struct rtl_priv *rtlpriv = rtl_priv(hw); struct rtl_priv *rtlpriv = rtl_priv(hw);

View file

@ -443,7 +443,8 @@ static int rtw_ops_start_ap(struct ieee80211_hw *hw,
} }
static int rtw_ops_conf_tx(struct ieee80211_hw *hw, static int rtw_ops_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 ac, struct ieee80211_vif *vif,
unsigned int link_id, u16 ac,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct rtw_dev *rtwdev = hw->priv; struct rtw_dev *rtwdev = hw->priv;

View file

@ -427,7 +427,8 @@ static int rtw89_ops_set_tim(struct ieee80211_hw *hw, struct ieee80211_sta *sta,
} }
static int rtw89_ops_conf_tx(struct ieee80211_hw *hw, static int rtw89_ops_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 ac, struct ieee80211_vif *vif,
unsigned int link_id, u16 ac,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct rtw89_dev *rtwdev = hw->priv; struct rtw89_dev *rtwdev = hw->priv;

View file

@ -895,7 +895,8 @@ static void rsi_mac80211_conf_filter(struct ieee80211_hw *hw,
* Return: 0 on success, negative error code on failure. * Return: 0 on success, negative error code on failure.
*/ */
static int rsi_mac80211_conf_tx(struct ieee80211_hw *hw, static int rsi_mac80211_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct rsi_hw *adapter = hw->priv; struct rsi_hw *adapter = hw->priv;

View file

@ -216,7 +216,8 @@ int wfx_update_pm(struct wfx_vif *wvif)
} }
int wfx_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, int wfx_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
u16 queue, const struct ieee80211_tx_queue_params *params) unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params)
{ {
struct wfx_dev *wdev = hw->priv; struct wfx_dev *wdev = hw->priv;
struct wfx_vif *wvif = (struct wfx_vif *)vif->drv_priv; struct wfx_vif *wvif = (struct wfx_vif *)vif->drv_priv;

View file

@ -36,7 +36,8 @@ void wfx_stop_ap(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
int wfx_join_ibss(struct ieee80211_hw *hw, struct ieee80211_vif *vif); int wfx_join_ibss(struct ieee80211_hw *hw, struct ieee80211_vif *vif);
void wfx_leave_ibss(struct ieee80211_hw *hw, struct ieee80211_vif *vif); void wfx_leave_ibss(struct ieee80211_hw *hw, struct ieee80211_vif *vif);
int wfx_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif, int wfx_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
u16 queue, const struct ieee80211_tx_queue_params *params); unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params);
void wfx_bss_info_changed(struct ieee80211_hw *hw, struct ieee80211_vif *vif, void wfx_bss_info_changed(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
struct ieee80211_bss_conf *info, u64 changed); struct ieee80211_bss_conf *info, u64 changed);
int wfx_sta_add(struct ieee80211_hw *hw, struct ieee80211_vif *vif, struct ieee80211_sta *sta); int wfx_sta_add(struct ieee80211_hw *hw, struct ieee80211_vif *vif, struct ieee80211_sta *sta);

View file

@ -606,7 +606,8 @@ void cw1200_configure_filter(struct ieee80211_hw *dev,
} }
int cw1200_conf_tx(struct ieee80211_hw *dev, struct ieee80211_vif *vif, int cw1200_conf_tx(struct ieee80211_hw *dev, struct ieee80211_vif *vif,
u16 queue, const struct ieee80211_tx_queue_params *params) unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params)
{ {
struct cw1200_common *priv = dev->priv; struct cw1200_common *priv = dev->priv;
int ret = 0; int ret = 0;

View file

@ -28,7 +28,8 @@ void cw1200_configure_filter(struct ieee80211_hw *dev,
unsigned int *total_flags, unsigned int *total_flags,
u64 multicast); u64 multicast);
int cw1200_conf_tx(struct ieee80211_hw *dev, struct ieee80211_vif *vif, int cw1200_conf_tx(struct ieee80211_hw *dev, struct ieee80211_vif *vif,
u16 queue, const struct ieee80211_tx_queue_params *params); unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params);
int cw1200_get_stats(struct ieee80211_hw *dev, int cw1200_get_stats(struct ieee80211_hw *dev,
struct ieee80211_low_level_stats *stats); struct ieee80211_low_level_stats *stats);
int cw1200_set_key(struct ieee80211_hw *dev, enum set_key_cmd cmd, int cw1200_set_key(struct ieee80211_hw *dev, enum set_key_cmd cmd,

View file

@ -1282,7 +1282,8 @@ static struct ieee80211_channel wl1251_channels[] = {
}; };
static int wl1251_op_conf_tx(struct ieee80211_hw *hw, static int wl1251_op_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
enum wl1251_acx_ps_scheme ps_scheme; enum wl1251_acx_ps_scheme ps_scheme;

View file

@ -4864,7 +4864,8 @@ out:
} }
static int wl1271_op_conf_tx(struct ieee80211_hw *hw, static int wl1271_op_conf_tx(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 queue, struct ieee80211_vif *vif,
unsigned int link_id, u16 queue,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct wl1271 *wl = hw->priv; struct wl1271 *wl = hw->priv;

View file

@ -4174,7 +4174,8 @@ struct ieee80211_ops {
struct ieee80211_sta *sta, struct ieee80211_sta *sta,
struct station_info *sinfo); struct station_info *sinfo);
int (*conf_tx)(struct ieee80211_hw *hw, int (*conf_tx)(struct ieee80211_hw *hw,
struct ieee80211_vif *vif, u16 ac, struct ieee80211_vif *vif,
unsigned int link_id, u16 ac,
const struct ieee80211_tx_queue_params *params); const struct ieee80211_tx_queue_params *params);
u64 (*get_tsf)(struct ieee80211_hw *hw, struct ieee80211_vif *vif); u64 (*get_tsf)(struct ieee80211_hw *hw, struct ieee80211_vif *vif);
void (*set_tsf)(struct ieee80211_hw *hw, struct ieee80211_vif *vif, void (*set_tsf)(struct ieee80211_hw *hw, struct ieee80211_vif *vif,

View file

@ -2570,6 +2570,7 @@ static int ieee80211_set_txq_params(struct wiphy *wiphy,
{ {
struct ieee80211_local *local = wiphy_priv(wiphy); struct ieee80211_local *local = wiphy_priv(wiphy);
struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev); struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
struct ieee80211_link_data *link = &sdata->deflink;
struct ieee80211_tx_queue_params p; struct ieee80211_tx_queue_params p;
if (!local->ops->conf_tx) if (!local->ops->conf_tx)
@ -2592,15 +2593,15 @@ static int ieee80211_set_txq_params(struct wiphy *wiphy,
ieee80211_regulatory_limit_wmm_params(sdata, &p, params->ac); ieee80211_regulatory_limit_wmm_params(sdata, &p, params->ac);
sdata->tx_conf[params->ac] = p; link->tx_conf[params->ac] = p;
if (drv_conf_tx(local, sdata, params->ac, &p)) { if (drv_conf_tx(local, link, params->ac, &p)) {
wiphy_debug(local->hw.wiphy, wiphy_debug(local->hw.wiphy,
"failed to set TX queue parameters for AC %d\n", "failed to set TX queue parameters for AC %d\n",
params->ac); params->ac);
return -EINVAL; return -EINVAL;
} }
ieee80211_link_info_change_notify(sdata, &sdata->deflink, ieee80211_link_info_change_notify(sdata, link,
BSS_CHANGED_QOS); BSS_CHANGED_QOS);
return 0; return 0;

View file

@ -1,6 +1,7 @@
// SPDX-License-Identifier: GPL-2.0-only // SPDX-License-Identifier: GPL-2.0-only
/* /*
* Copyright 2015 Intel Deutschland GmbH * Copyright 2015 Intel Deutschland GmbH
* Copyright (C) 2022 Intel Corporation
*/ */
#include <net/mac80211.h> #include <net/mac80211.h>
#include "ieee80211_i.h" #include "ieee80211_i.h"
@ -180,9 +181,10 @@ void drv_sta_rc_update(struct ieee80211_local *local,
} }
int drv_conf_tx(struct ieee80211_local *local, int drv_conf_tx(struct ieee80211_local *local,
struct ieee80211_sub_if_data *sdata, u16 ac, struct ieee80211_link_data *link, u16 ac,
const struct ieee80211_tx_queue_params *params) const struct ieee80211_tx_queue_params *params)
{ {
struct ieee80211_sub_if_data *sdata = link->sdata;
int ret = -EOPNOTSUPP; int ret = -EOPNOTSUPP;
might_sleep(); might_sleep();
@ -201,10 +203,10 @@ int drv_conf_tx(struct ieee80211_local *local,
return -EINVAL; return -EINVAL;
} }
trace_drv_conf_tx(local, sdata, ac, params); trace_drv_conf_tx(local, sdata, link->link_id, ac, params);
if (local->ops->conf_tx) if (local->ops->conf_tx)
ret = local->ops->conf_tx(&local->hw, &sdata->vif, ret = local->ops->conf_tx(&local->hw, &sdata->vif,
ac, params); link->link_id, ac, params);
trace_drv_return_int(local, ret); trace_drv_return_int(local, ret);
return ret; return ret;
} }

View file

@ -590,7 +590,7 @@ static inline void drv_sta_statistics(struct ieee80211_local *local,
} }
int drv_conf_tx(struct ieee80211_local *local, int drv_conf_tx(struct ieee80211_local *local,
struct ieee80211_sub_if_data *sdata, u16 ac, struct ieee80211_link_data *link, u16 ac,
const struct ieee80211_tx_queue_params *params); const struct ieee80211_tx_queue_params *params);
u64 drv_get_tsf(struct ieee80211_local *local, u64 drv_get_tsf(struct ieee80211_local *local,

View file

@ -356,7 +356,7 @@ static void __ieee80211_sta_join_ibss(struct ieee80211_sub_if_data *sdata,
else else
sdata->flags &= ~IEEE80211_SDATA_OPERATING_GMODE; sdata->flags &= ~IEEE80211_SDATA_OPERATING_GMODE;
ieee80211_set_wmm_default(sdata, true, false); ieee80211_set_wmm_default(&sdata->deflink, true, false);
sdata->vif.cfg.ibss_joined = true; sdata->vif.cfg.ibss_joined = true;
sdata->vif.cfg.ibss_creator = creator; sdata->vif.cfg.ibss_creator = creator;

View file

@ -969,6 +969,8 @@ struct ieee80211_link_data {
struct ieee80211_link_data_ap ap; struct ieee80211_link_data_ap ap;
} u; } u;
struct ieee80211_tx_queue_params tx_conf[IEEE80211_NUM_ACS];
struct ieee80211_bss_conf *conf; struct ieee80211_bss_conf *conf;
}; };
@ -1012,7 +1014,6 @@ struct ieee80211_sub_if_data {
bool control_port_over_nl80211; bool control_port_over_nl80211;
atomic_t num_tx_queued; atomic_t num_tx_queued;
struct ieee80211_tx_queue_params tx_conf[IEEE80211_NUM_ACS];
struct mac80211_qos_map __rcu *qos_map; struct mac80211_qos_map __rcu *qos_map;
/* used to reconfigure hardware SM PS */ /* used to reconfigure hardware SM PS */
@ -2101,7 +2102,7 @@ int ieee80211_frame_duration(enum nl80211_band band, size_t len,
void ieee80211_regulatory_limit_wmm_params(struct ieee80211_sub_if_data *sdata, void ieee80211_regulatory_limit_wmm_params(struct ieee80211_sub_if_data *sdata,
struct ieee80211_tx_queue_params *qparam, struct ieee80211_tx_queue_params *qparam,
int ac); int ac);
void ieee80211_set_wmm_default(struct ieee80211_sub_if_data *sdata, void ieee80211_set_wmm_default(struct ieee80211_link_data *link,
bool bss_notify, bool enable_qos); bool bss_notify, bool enable_qos);
void ieee80211_xmit(struct ieee80211_sub_if_data *sdata, void ieee80211_xmit(struct ieee80211_sub_if_data *sdata,
struct sta_info *sta, struct sk_buff *skb); struct sta_info *sta, struct sk_buff *skb);

View file

@ -1539,7 +1539,7 @@ int ieee80211_do_open(struct wireless_dev *wdev, bool coming_up)
* doesn't start up with sane defaults. * doesn't start up with sane defaults.
* Enable QoS for anything but station interfaces. * Enable QoS for anything but station interfaces.
*/ */
ieee80211_set_wmm_default(sdata, true, ieee80211_set_wmm_default(&sdata->deflink, true,
sdata->vif.type != NL80211_IFTYPE_STATION); sdata->vif.type != NL80211_IFTYPE_STATION);
} }

View file

@ -2018,8 +2018,9 @@ __ieee80211_sta_handle_tspec_ac_params(struct ieee80211_sub_if_data *sdata)
switch (tx_tspec->action) { switch (tx_tspec->action) {
case TX_TSPEC_ACTION_STOP_DOWNGRADE: case TX_TSPEC_ACTION_STOP_DOWNGRADE:
/* take the original parameters */ /* take the original parameters */
if (drv_conf_tx(local, sdata, ac, &sdata->tx_conf[ac])) if (drv_conf_tx(local, &sdata->deflink, ac,
sdata_err(sdata, &sdata->deflink.tx_conf[ac]))
link_err(&sdata->deflink,
"failed to set TX queue parameters for queue %d\n", "failed to set TX queue parameters for queue %d\n",
ac); ac);
tx_tspec->action = TX_TSPEC_ACTION_NONE; tx_tspec->action = TX_TSPEC_ACTION_NONE;
@ -2047,9 +2048,9 @@ __ieee80211_sta_handle_tspec_ac_params(struct ieee80211_sub_if_data *sdata)
*/ */
if (non_acm_ac >= IEEE80211_NUM_ACS) if (non_acm_ac >= IEEE80211_NUM_ACS)
non_acm_ac = IEEE80211_AC_BK; non_acm_ac = IEEE80211_AC_BK;
if (drv_conf_tx(local, sdata, ac, if (drv_conf_tx(local, &sdata->deflink, ac,
&sdata->tx_conf[non_acm_ac])) &sdata->deflink.tx_conf[non_acm_ac]))
sdata_err(sdata, link_err(&sdata->deflink,
"failed to set TX queue parameters for queue %d\n", "failed to set TX queue parameters for queue %d\n",
ac); ac);
tx_tspec->action = TX_TSPEC_ACTION_NONE; tx_tspec->action = TX_TSPEC_ACTION_NONE;
@ -2085,10 +2086,11 @@ static void ieee80211_sta_handle_tspec_ac_params_wk(struct work_struct *work)
/* MLME */ /* MLME */
static bool static bool
ieee80211_sta_wmm_params(struct ieee80211_local *local, ieee80211_sta_wmm_params(struct ieee80211_local *local,
struct ieee80211_sub_if_data *sdata, struct ieee80211_link_data *link,
const u8 *wmm_param, size_t wmm_param_len, const u8 *wmm_param, size_t wmm_param_len,
const struct ieee80211_mu_edca_param_set *mu_edca) const struct ieee80211_mu_edca_param_set *mu_edca)
{ {
struct ieee80211_sub_if_data *sdata = link->sdata;
struct ieee80211_tx_queue_params params[IEEE80211_NUM_ACS]; struct ieee80211_tx_queue_params params[IEEE80211_NUM_ACS];
struct ieee80211_if_managed *ifmgd = &sdata->u.mgd; struct ieee80211_if_managed *ifmgd = &sdata->u.mgd;
size_t left; size_t left;
@ -2117,11 +2119,11 @@ ieee80211_sta_wmm_params(struct ieee80211_local *local,
* the driver about it. * the driver about it.
*/ */
mu_edca_count = mu_edca ? mu_edca->mu_qos_info & 0x0f : -1; mu_edca_count = mu_edca ? mu_edca->mu_qos_info & 0x0f : -1;
if (count == sdata->deflink.u.mgd.wmm_last_param_set && if (count == link->u.mgd.wmm_last_param_set &&
mu_edca_count == sdata->deflink.u.mgd.mu_edca_last_param_set) mu_edca_count == link->u.mgd.mu_edca_last_param_set)
return false; return false;
sdata->deflink.u.mgd.wmm_last_param_set = count; link->u.mgd.wmm_last_param_set = count;
sdata->deflink.u.mgd.mu_edca_last_param_set = mu_edca_count; link->u.mgd.mu_edca_last_param_set = mu_edca_count;
pos = wmm_param + 8; pos = wmm_param + 8;
left = wmm_param_len - 8; left = wmm_param_len - 8;
@ -2219,16 +2221,16 @@ ieee80211_sta_wmm_params(struct ieee80211_local *local,
params[ac].aifs, params[ac].cw_min, params[ac].cw_max, params[ac].aifs, params[ac].cw_min, params[ac].cw_max,
params[ac].txop, params[ac].uapsd, params[ac].txop, params[ac].uapsd,
ifmgd->tx_tspec[ac].downgraded); ifmgd->tx_tspec[ac].downgraded);
sdata->tx_conf[ac] = params[ac]; link->tx_conf[ac] = params[ac];
if (!ifmgd->tx_tspec[ac].downgraded && if (!ifmgd->tx_tspec[ac].downgraded &&
drv_conf_tx(local, sdata, ac, &params[ac])) drv_conf_tx(local, link, ac, &params[ac]))
sdata_err(sdata, link_err(link,
"failed to set TX queue parameters for AC %d\n", "failed to set TX queue parameters for AC %d\n",
ac); ac);
} }
/* enable WMM or activate new settings */ /* enable WMM or activate new settings */
sdata->vif.bss_conf.qos = true; link->conf->qos = true;
return true; return true;
} }
@ -2508,7 +2510,7 @@ static void ieee80211_set_disassoc(struct ieee80211_sub_if_data *sdata,
ieee80211_bss_info_change_notify(sdata, changed); ieee80211_bss_info_change_notify(sdata, changed);
/* disassociated - set to defaults now */ /* disassociated - set to defaults now */
ieee80211_set_wmm_default(sdata, false, false); ieee80211_set_wmm_default(&sdata->deflink, false, false);
del_timer_sync(&sdata->u.mgd.conn_mon_timer); del_timer_sync(&sdata->u.mgd.conn_mon_timer);
del_timer_sync(&sdata->u.mgd.bcn_mon_timer); del_timer_sync(&sdata->u.mgd.bcn_mon_timer);
@ -3766,12 +3768,13 @@ static bool ieee80211_assoc_success(struct ieee80211_sub_if_data *sdata,
sdata->deflink.u.mgd.mu_edca_last_param_set = -1; sdata->deflink.u.mgd.mu_edca_last_param_set = -1;
if (ifmgd->flags & IEEE80211_STA_DISABLE_WMM) { if (ifmgd->flags & IEEE80211_STA_DISABLE_WMM) {
ieee80211_set_wmm_default(sdata, false, false); ieee80211_set_wmm_default(&sdata->deflink, false, false);
} else if (!ieee80211_sta_wmm_params(local, sdata, elems->wmm_param, } else if (!ieee80211_sta_wmm_params(local, &sdata->deflink,
elems->wmm_param,
elems->wmm_param_len, elems->wmm_param_len,
elems->mu_edca_param_set)) { elems->mu_edca_param_set)) {
/* still enable QoS since we might have HT/VHT */ /* still enable QoS since we might have HT/VHT */
ieee80211_set_wmm_default(sdata, false, true); ieee80211_set_wmm_default(&sdata->deflink, false, true);
/* set the disable-WMM flag in this case to disable /* set the disable-WMM flag in this case to disable
* tracking WMM parameter changes in the beacon if * tracking WMM parameter changes in the beacon if
* the parameters weren't actually valid. Doing so * the parameters weren't actually valid. Doing so
@ -3938,7 +3941,7 @@ static void ieee80211_rx_mgmt_assoc_resp(struct ieee80211_sub_if_data *sdata,
/* get uapsd queues configuration */ /* get uapsd queues configuration */
uapsd_queues = 0; uapsd_queues = 0;
for (ac = 0; ac < IEEE80211_NUM_ACS; ac++) for (ac = 0; ac < IEEE80211_NUM_ACS; ac++)
if (sdata->tx_conf[ac].uapsd) if (sdata->deflink.tx_conf[ac].uapsd)
uapsd_queues |= ieee80211_ac_to_qos_mask[ac]; uapsd_queues |= ieee80211_ac_to_qos_mask[ac];
info.success = 1; info.success = 1;
@ -4363,7 +4366,7 @@ static void ieee80211_rx_mgmt_beacon(struct ieee80211_sub_if_data *sdata,
elems, true); elems, true);
if (!(ifmgd->flags & IEEE80211_STA_DISABLE_WMM) && if (!(ifmgd->flags & IEEE80211_STA_DISABLE_WMM) &&
ieee80211_sta_wmm_params(local, sdata, elems->wmm_param, ieee80211_sta_wmm_params(local, &sdata->deflink, elems->wmm_param,
elems->wmm_param_len, elems->wmm_param_len,
elems->mu_edca_param_set)) elems->mu_edca_param_set))
changed |= BSS_CHANGED_QOS; changed |= BSS_CHANGED_QOS;

View file

@ -293,7 +293,7 @@ static void ieee80211_tdls_add_wmm_param_ie(struct ieee80211_sub_if_data *sdata,
* doesn't support it, as mandated by 802.11-2012 section 10.22.4 * doesn't support it, as mandated by 802.11-2012 section 10.22.4
*/ */
for (i = 0; i < IEEE80211_NUM_ACS; i++) { for (i = 0; i < IEEE80211_NUM_ACS; i++) {
txq = &sdata->tx_conf[ieee80211_ac_from_wmm(i)]; txq = &sdata->deflink.tx_conf[ieee80211_ac_from_wmm(i)];
wmm->ac[i].aci_aifsn = ieee80211_wmm_aci_aifsn(txq->aifs, wmm->ac[i].aci_aifsn = ieee80211_wmm_aci_aifsn(txq->aifs,
txq->acm, i); txq->acm, i);
wmm->ac[i].cw = ieee80211_wmm_ecw(txq->cw_min, txq->cw_max); wmm->ac[i].cw = ieee80211_wmm_ecw(txq->cw_min, txq->cw_max);

View file

@ -1003,13 +1003,15 @@ DEFINE_EVENT(sta_event, drv_sta_rate_tbl_update,
TRACE_EVENT(drv_conf_tx, TRACE_EVENT(drv_conf_tx,
TP_PROTO(struct ieee80211_local *local, TP_PROTO(struct ieee80211_local *local,
struct ieee80211_sub_if_data *sdata, struct ieee80211_sub_if_data *sdata,
unsigned int link_id,
u16 ac, const struct ieee80211_tx_queue_params *params), u16 ac, const struct ieee80211_tx_queue_params *params),
TP_ARGS(local, sdata, ac, params), TP_ARGS(local, sdata, link_id, ac, params),
TP_STRUCT__entry( TP_STRUCT__entry(
LOCAL_ENTRY LOCAL_ENTRY
VIF_ENTRY VIF_ENTRY
__field(unsigned int, link_id)
__field(u16, ac) __field(u16, ac)
__field(u16, txop) __field(u16, txop)
__field(u16, cw_min) __field(u16, cw_min)
@ -1021,6 +1023,7 @@ TRACE_EVENT(drv_conf_tx,
TP_fast_assign( TP_fast_assign(
LOCAL_ASSIGN; LOCAL_ASSIGN;
VIF_ASSIGN; VIF_ASSIGN;
__entry->link_id = link_id;
__entry->ac = ac; __entry->ac = ac;
__entry->txop = params->txop; __entry->txop = params->txop;
__entry->cw_max = params->cw_max; __entry->cw_max = params->cw_max;
@ -1030,8 +1033,8 @@ TRACE_EVENT(drv_conf_tx,
), ),
TP_printk( TP_printk(
LOCAL_PR_FMT VIF_PR_FMT " AC:%d", LOCAL_PR_FMT VIF_PR_FMT " link_id: %d, AC:%d",
LOCAL_PR_ARG, VIF_PR_ARG, __entry->ac LOCAL_PR_ARG, VIF_PR_ARG, __entry->link_id, __entry->ac
) )
); );

View file

@ -1596,9 +1596,10 @@ void ieee80211_regulatory_limit_wmm_params(struct ieee80211_sub_if_data *sdata,
rcu_read_unlock(); rcu_read_unlock();
} }
void ieee80211_set_wmm_default(struct ieee80211_sub_if_data *sdata, void ieee80211_set_wmm_default(struct ieee80211_link_data *link,
bool bss_notify, bool enable_qos) bool bss_notify, bool enable_qos)
{ {
struct ieee80211_sub_if_data *sdata = link->sdata;
struct ieee80211_local *local = sdata->local; struct ieee80211_local *local = sdata->local;
struct ieee80211_tx_queue_params qparam; struct ieee80211_tx_queue_params qparam;
struct ieee80211_chanctx_conf *chanctx_conf; struct ieee80211_chanctx_conf *chanctx_conf;
@ -1616,7 +1617,7 @@ void ieee80211_set_wmm_default(struct ieee80211_sub_if_data *sdata,
memset(&qparam, 0, sizeof(qparam)); memset(&qparam, 0, sizeof(qparam));
rcu_read_lock(); rcu_read_lock();
chanctx_conf = rcu_dereference(sdata->vif.bss_conf.chanctx_conf); chanctx_conf = rcu_dereference(link->conf->chanctx_conf);
use_11b = (chanctx_conf && use_11b = (chanctx_conf &&
chanctx_conf->def.chan->band == NL80211_BAND_2GHZ) && chanctx_conf->def.chan->band == NL80211_BAND_2GHZ) &&
!(sdata->flags & IEEE80211_SDATA_OPERATING_GMODE); !(sdata->flags & IEEE80211_SDATA_OPERATING_GMODE);
@ -1693,17 +1694,16 @@ void ieee80211_set_wmm_default(struct ieee80211_sub_if_data *sdata,
qparam.uapsd = false; qparam.uapsd = false;
sdata->tx_conf[ac] = qparam; link->tx_conf[ac] = qparam;
drv_conf_tx(local, sdata, ac, &qparam); drv_conf_tx(local, link, ac, &qparam);
} }
if (sdata->vif.type != NL80211_IFTYPE_MONITOR && if (sdata->vif.type != NL80211_IFTYPE_MONITOR &&
sdata->vif.type != NL80211_IFTYPE_P2P_DEVICE && sdata->vif.type != NL80211_IFTYPE_P2P_DEVICE &&
sdata->vif.type != NL80211_IFTYPE_NAN) { sdata->vif.type != NL80211_IFTYPE_NAN) {
sdata->vif.bss_conf.qos = enable_qos; link->conf->qos = enable_qos;
if (bss_notify) if (bss_notify)
ieee80211_link_info_change_notify(sdata, ieee80211_link_info_change_notify(sdata, link,
&sdata->deflink,
BSS_CHANGED_QOS); BSS_CHANGED_QOS);
} }
} }
@ -2520,8 +2520,8 @@ int ieee80211_reconfig(struct ieee80211_local *local)
fallthrough; fallthrough;
case NL80211_IFTYPE_AP: /* AP stations are handled later */ case NL80211_IFTYPE_AP: /* AP stations are handled later */
for (i = 0; i < IEEE80211_NUM_ACS; i++) for (i = 0; i < IEEE80211_NUM_ACS; i++)
drv_conf_tx(local, sdata, i, drv_conf_tx(local, &sdata->deflink, i,
&sdata->tx_conf[i]); &sdata->deflink.tx_conf[i]);
break; break;
} }