Revert "wifi: mt76: mt7925: Update mt7925_mcu_uni_[tx,rx]_ba for MLO"
Subsystems (3)
PATCH v3 1/6 Revert "wifi: mt76: mt7925: Update mt7925_mcu_uni_[tx,rx]_ba for MLO"
From: Sean Wang <[email protected]>
For MLO, mac80211 will send the BA action for each link to the driver, so the driver does not need to handle it itself. Therefore, revert this patch.
---
v2:
1) generate the patch based on the latest mt76 tree
2) update the commit message
v3:
1) fixed the merge conflict
--- .../net/wireless/mediatek/mt76/mt7925/main.c | 10 ++-- .../net/wireless/mediatek/mt76/mt7925/mcu.c | 50 ++++--------------- .../wireless/mediatek/mt76/mt7925/mt7925.h | 2 - 3 files changed, 15 insertions(+), 47 deletions(-)
drivers/net/wireless/mediatek/mt76/mt7925/main.c +5 -5
@@ -1289,22 +1289,22 @@ mt7925_ampdu_action(struct ieee80211_hw *hw, struct ieee80211_vif *vif,case IEEE80211_AMPDU_RX_START :mt76_rx_aggr_start (&dev->mt76, &msta->deflink.wcid, tid, ssn, params->buf_size); -mt7925_mcu_uni_rx_ba (dev, vif, params, true); +mt7925_mcu_uni_rx_ba (dev, params, true);break ;case IEEE80211_AMPDU_RX_STOP :mt76_rx_aggr_stop (&dev->mt76, &msta->deflink.wcid, tid); -mt7925_mcu_uni_rx_ba (dev, vif, params, false); +mt7925_mcu_uni_rx_ba (dev, params, false);break ;case IEEE80211_AMPDU_TX_OPERATIONAL : mtxq->aggr = true; mtxq->send_bar = false; -mt7925_mcu_uni_tx_ba (dev, vif, params, true); +mt7925_mcu_uni_tx_ba (dev, params, true);break ;case IEEE80211_AMPDU_TX_STOP_FLUSH :case IEEE80211_AMPDU_TX_STOP_FLUSH_CONT : mtxq->aggr = false;clear_bit (tid, &msta->deflink.wcid.ampdu_state); -mt7925_mcu_uni_tx_ba (dev, vif, params, false); +mt7925_mcu_uni_tx_ba (dev, params, false);break ;case IEEE80211_AMPDU_TX_START :set_bit (tid, &msta->deflink.wcid.ampdu_state);
@@ -1313,7 +1313,7 @@ mt7925_ampdu_action(struct ieee80211_hw *hw, struct ieee80211_vif *vif,case IEEE80211_AMPDU_TX_STOP_CONT : mtxq->aggr = false;clear_bit (tid, &msta->deflink.wcid.ampdu_state); -mt7925_mcu_uni_tx_ba (dev, vif, params, false); +mt7925_mcu_uni_tx_ba (dev, params, false);ieee80211_stop_tx_ba_cb_irqsafe (vif, sta->addr, tid);break ; }
drivers/net/wireless/mediatek/mt76/mt7925/mcu.c +10 -40
70 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7925/mt7925.h +0 -2
@@ -263,11 +263,9 @@ int mt7925_mcu_set_beacon_filter(struct mt792x_dev *dev,struct ieee80211_vif *vif, bool enable);int mt7925_mcu_uni_tx_ba (struct mt792x_dev *dev, -struct ieee80211_vif *vif,struct ieee80211_ampdu_params *params,bool enable);int mt7925_mcu_uni_rx_ba (struct mt792x_dev *dev, -struct ieee80211_vif *vif,struct ieee80211_ampdu_params *params,bool enable);void mt7925_scan_work (struct work_struct *work);
Signature · 1 line
2.25.1
PATCH v3 2/6 wifi: mt76: mt7925: fix the wrong link_idx when has p2p_device
From: Ming Yen Hsieh <[email protected]>
When the p2p device and MLO station concurrent, the p2p device will occupy the wrong link_idx when the MLO secondary link is added.
---
v2, v3: generate the patch based on the latest mt76 tree
--- .../net/wireless/mediatek/mt76/Makefile.orig | 42 + drivers/net/wireless/mediatek/mt76/dma.c.orig | 994 +++++ .../wireless/mediatek/mt76/mac80211.c.orig | 1793 +++++++++ drivers/net/wireless/mediatek/mt76/mt76.h | 1 + .../net/wireless/mediatek/mt76/mt76.h.orig | 1876 +++++++++ .../mediatek/mt76/mt76_connac_mac.c.orig | 1196 ++++++ .../wireless/mediatek/mt76/mt76_connac_mcu.c | 4 +- .../mediatek/mt76/mt76_connac_mcu.c.orig | 3200 +++++++++++++++ .../wireless/mediatek/mt76/mt7921/dma.c.orig | 314 ++ .../wireless/mediatek/mt76/mt7921/init.c.orig | 326 ++ .../wireless/mediatek/mt76/mt7921/mac.c.orig | 1121 ++++++ .../wireless/mediatek/mt76/mt7921/main.c.orig | 1838 +++++++++ .../wireless/mediatek/mt76/mt7921/mcu.c.orig | 1357 +++++++ .../mediatek/mt76/mt7921/mt7921.h.orig | 561 +++ .../wireless/mediatek/mt76/mt7921/pci.c.orig | 497 +++ .../mediatek/mt76/mt7921/pci_mac.c.orig | 348 ++ .../wireless/mediatek/mt76/mt7921/sdio.c.orig | 322 ++ .../mediatek/mt76/mt7921/sdio_mac.c.orig | 142 + .../net/wireless/mediatek/mt76/mt7925/main.c | 14 +- .../wireless/mediatek/mt76/mt7925/main.c.orig | 2209 +++++++++++ .../wireless/mediatek/mt76/mt7925/mcu.c.orig | 3506 +++++++++++++++++ .../wireless/mediatek/mt76/mt7925/mcu.c.rej | 35 + 22 files changed, 21690 insertions(+), 6 deletions(-) create mode 100644 drivers/net/wireless/mediatek/mt76/Makefile.orig create mode 100644 drivers/net/wireless/mediatek/mt76/dma.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mac80211.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt76.h.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt76_connac_mac.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt76_connac_mcu.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/dma.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/init.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/mac.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/main.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/mcu.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/mt7921.h.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/pci.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/pci_mac.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/sdio.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/sdio_mac.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7925/main.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7925/mcu.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7925/mcu.c.rej
drivers/net/wireless/mediatek/mt76/Makefile.orig new file +42 -0
@@ -0,0 +1,42 @@ +# SPDX-License-Identifier: GPL-2.0-only +obj-$(CONFIG_MT76_CORE) += mt76.o +obj-$(CONFIG_MT76_USB) += mt76-usb.o +obj-$(CONFIG_MT76_SDIO) += mt76-sdio.o +obj-$(CONFIG_MT76x02_LIB) += mt76x02-lib.o +obj-$(CONFIG_MT76x02_USB) += mt76x02-usb.o +obj-$(CONFIG_MT76_CONNAC_LIB) += mt76-connac-lib.o + +mt76-y := \ + mmio.o util.o trace.o dma.o mac80211.o debugfs.o eeprom.o \ + tx.o agg-rx.o mcu.o + +mt76-$(CONFIG_PCI) += pci.o +mt76-$(CONFIG_NL80211_TESTMODE) += testmode.o + +mt76-usb-y := usb.o usb_trace.o +mt76-sdio-y := sdio.o sdio_txrx.o + +CFLAGS_trace.o := -I$(src) +CFLAGS_usb_trace.o := -I$(src) +CFLAGS_mt76x02_trace.o := -I$(src) + +mt76x02-lib-y := mt76x02_util.o mt76x02_mac.o mt76x02_mcu.o \ + mt76x02_eeprom.o mt76x02_phy.o mt76x02_mmio.o \ + mt76x02_txrx.o mt76x02_trace.o mt76x02_debugfs.o \ + mt76x02_dfs.o mt76x02_beacon.o + +mt76x02-usb-y := mt76x02_usb_mcu.o mt76x02_usb_core.o + +mt76-connac-lib-y := mt76_connac_mcu.o mt76_connac_mac.o + +obj-$(CONFIG_MT76x0_COMMON) += mt76x0/ +obj-$(CONFIG_MT76x2_COMMON) += mt76x2/ +obj-$(CONFIG_MT7603E) += mt7603/ +obj-$(CONFIG_MT7615_COMMON) += mt7615/ +obj-$(CONFIG_MT7915E) += mt7915/ +obj-$(CONFIG_MT7921_COMMON) += mt7921/ +<<<<<<< HEAD +======= +obj-$(CONFIG_MT7996E) += mt7996/ +obj-$(CONFIG_MT7925_COMMON) += mt7925/ +>>>>>>> dev: mt7925: build mt7925 pass
drivers/net/wireless/mediatek/mt76/dma.c.orig new file +994 -0
994 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mac80211.c.orig new file +1793 -0
1,793 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt76.h +1 -0
@@ -769,6 +769,7 @@ struct mt76_testmode_data {struct mt76_vif_link {u8 idx; +u8 link_idx;u8 omac_idx;u8 band_idx;u8 wmm_idx;
drivers/net/wireless/mediatek/mt76/mt76.h.orig new file +1876 -0
164 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt76_connac_mac.c.orig new file +1196 -0
1,196 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt76_connac_mcu.c +2 -2
Lines of this file are not shown. View the raw message.
drivers/net/wireless/mediatek/mt76/mt76_connac_mcu.c.orig new file +3200 -0
3,200 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7921/dma.c.orig new file +314 -0
314 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7921/init.c.orig new file +326 -0
326 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7921/mac.c.orig new file +1121 -0
1,121 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7921/main.c.orig new file +1838 -0
1,838 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7921/mcu.c.orig new file +1357 -0
1,357 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7921/mt7921.h.orig new file +561 -0
561 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7921/pci.c.orig new file +497 -0
497 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7921/pci_mac.c.orig new file +348 -0
348 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7921/sdio.c.orig new file +322 -0
322 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7921/sdio_mac.c.orig new file +142 -0
142 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7925/main.c +10 -4
Lines of this file are not shown. View the raw message.
drivers/net/wireless/mediatek/mt76/mt7925/main.c.orig new file +2209 -0
2,209 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7925/mcu.c.orig new file +3506 -0
3,506 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7925/mcu.c.rej new file +35 -0
Lines of this file are not shown. View the raw message.
The rest of this diff is not shown. View the raw message.
Signature · 1 line
2.25.1
Part of the diff is not shown here. View the raw message.
RE: [PATCH v3 2/6] wifi: mt76: mt7925: fix the wrong link_idx when has p2p_device
[email protected] <[email protected]> wrote:
[...]
Quoted 34 lines
.../net/wireless/mediatek/mt76/Makefile.orig | 42 + drivers/net/wireless/mediatek/mt76/dma.c.orig | 994 +++++ .../wireless/mediatek/mt76/mac80211.c.orig | 1793 +++++++++ drivers/net/wireless/mediatek/mt76/mt76.h | 1 + .../net/wireless/mediatek/mt76/mt76.h.orig | 1876 +++++++++ .../mediatek/mt76/mt76_connac_mac.c.orig | 1196 ++++++ .../wireless/mediatek/mt76/mt76_connac_mcu.c | 4 +- .../mediatek/mt76/mt76_connac_mcu.c.orig | 3200 +++++++++++++++ .../wireless/mediatek/mt76/mt7921/dma.c.orig | 314 ++ .../wireless/mediatek/mt76/mt7921/init.c.orig | 326 ++ .../wireless/mediatek/mt76/mt7921/mac.c.orig | 1121 ++++++ .../wireless/mediatek/mt76/mt7921/main.c.orig | 1838 +++++++++ .../wireless/mediatek/mt76/mt7921/mcu.c.orig | 1357 +++++++ .../mediatek/mt76/mt7921/mt7921.h.orig | 561 +++ .../wireless/mediatek/mt76/mt7921/pci.c.orig | 497 +++ .../mediatek/mt76/mt7921/pci_mac.c.orig | 348 ++ .../wireless/mediatek/mt76/mt7921/sdio.c.orig | 322 ++ .../mediatek/mt76/mt7921/sdio_mac.c.orig | 142 + .../net/wireless/mediatek/mt76/mt7925/main.c | 14 +- .../wireless/mediatek/mt76/mt7925/main.c.orig | 2209 +++++++++++ .../wireless/mediatek/mt76/mt7925/mcu.c.orig | 3506 +++++++++++++++++ .../wireless/mediatek/mt76/mt7925/mcu.c.rej | 35 + 22 files changed, 21690 insertions(+), 6 deletions(-) create mode 100644 drivers/net/wireless/mediatek/mt76/Makefile.orig create mode 100644 drivers/net/wireless/mediatek/mt76/dma.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mac80211.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt76.h.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt76_connac_mac.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt76_connac_mcu.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/dma.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/init.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/mac.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/main.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/mcu.c.orig
Quoted 8 lines
create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/mt7921.h.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/pci.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/pci_mac.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/sdio.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7921/sdio_mac.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7925/main.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7925/mcu.c.orig create mode 100644 drivers/net/wireless/mediatek/mt76/mt7925/mcu.c.rej
Obviously add wrong conflict files.
PATCH v3 3/6 wifi: mt76: mt7925: fix the wrong simultaneous cap for MLO
In reply to [email protected]From: Ming Yen Hsieh <[email protected]>
The mt7925 chip is only support a single radio, so the maximum number of simultaneous should be 0.
---
v2, v3: generate the patch based on the latest mt76 tree
--- drivers/net/wireless/mediatek/mt76/mt7925/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/wireless/mediatek/mt76/mt7925/main.c +1 -1
@@ -256,7 +256,7 @@ int mt7925_init_mlo_caps(struct mt792x_phy *phy) ext_capab[0 ].eml_capabilities = phy->eml_cap; ext_capab[0 ].mld_capa_and_ops = -u16_encode_bits (1 ,IEEE80211_MLD_CAP_OP_MAX_SIMUL_LINKS ); +u16_encode_bits (0 ,IEEE80211_MLD_CAP_OP_MAX_SIMUL_LINKS ); wiphy->flags |=WIPHY_FLAG_SUPPORTS_MLO ; wiphy->iftype_ext_capab = ext_capab;
Signature · 1 line
2.25.1
PATCH v3 4/6 wifi: mt76: mt7925: adjust rm BSS flow to prevent next connection failure
In reply to [email protected]From: Ming Yen Hsieh <[email protected]>
Removing BSS without removing STAREC first will cause firmware abnormal and next connection fail.
---
v2, v3: generate the patch based on the latest mt76 tree
--- .../net/wireless/mediatek/mt76/mt7925/main.c | 45 +++++++++++++++---- 1 file changed, 36 insertions(+), 9 deletions(-)
drivers/net/wireless/mediatek/mt76/mt7925/main.c +36 -9
@@ -1155,7 +1155,12 @@ static void mt7925_mac_link_sta_remove(struct mt76_dev *mdev,struct mt792x_bss_conf *mconf; mconf =mt792x_link_conf_to_mconf (link_conf); -mt792x_mac_link_bss_remove (dev, mconf, mlink); + +if (ieee80211_vif_is_mld (vif)) +mt792x_mac_link_bss_remove (dev, mconf, mlink); +else +mt7925_mcu_add_bss_info (&dev->phy, mconf->mt76.ctx, link_conf, + link_sta, false); }spin_lock_bh (&mdev->sta_poll_lock);
@@ -1175,6 +1180,31 @@ mt7925_mac_sta_remove_links(struct mt792x_dev *dev, struct ieee80211_vif *vif,struct mt76_wcid *wcid;unsigned int link_id; +/* clean up bss before starec */ +for_each_set_bit (link_id, &old_links,IEEE80211_MLD_MAX_NUM_LINKS ) { +struct ieee80211_link_sta *link_sta; +struct ieee80211_bss_conf *link_conf; +struct mt792x_bss_conf *mconf; +struct mt792x_link_sta *mlink; + + link_sta =mt792x_sta_to_link_sta (vif, sta, link_id); +if (!link_sta) +continue ; + + mlink =mt792x_sta_to_link (msta, link_id); +if (!mlink) +continue ; + + link_conf =mt792x_vif_to_bss_conf (vif, link_id); +if (!link_conf) +continue ; + + mconf =mt792x_link_conf_to_mconf (link_conf); + +mt7925_mcu_add_bss_info (&dev->phy, mconf->mt76.ctx, link_conf, + link_sta, false); + } +for_each_set_bit (link_id, &old_links,IEEE80211_MLD_MAX_NUM_LINKS ) {struct ieee80211_link_sta *link_sta;struct mt792x_link_sta *mlink;
@@ -1212,6 +1242,7 @@ void mt7925_mac_sta_remove(struct mt76_dev *mdev, struct ieee80211_vif *vif, { struct mt792x_dev *dev = container_of(mdev, struct mt792x_dev, mt76); struct mt792x_sta *msta = (struct mt792x_sta *)sta->drv_priv; + struct mt792x_vif *mvif = (struct mt792x_vif *)vif->drv_priv; struct { struct { u8 omac_idx;
@@ -1242,14 +1273,10 @@ void mt7925_mac_sta_remove(struct mt76_dev *mdev, struct ieee80211_vif *vif,mt7925_mac_sta_remove_links (dev, vif, sta, rem); -if (ieee80211_vif_is_mld (vif)) { -mt7925_mcu_set_dbdc (&dev->mphy, false); - -/* recovery omac address for the legacy interface */ -memcpy (dev_req.tlv.omac_addr, vif->addr,ETH_ALEN ); -mt76_mcu_send_msg (mdev,MCU_UNI_CMD (DEV_INFO_UPDATE ), - &dev_req,sizeof (dev_req), true); - } +/* recovery omac address for the legacy interface */ +memcpy (dev_req.tlv.omac_addr, vif->addr,ETH_ALEN ); +mt76_mcu_send_msg (mdev,MCU_UNI_CMD (DEV_INFO_UPDATE ), + &dev_req,sizeof (dev_req), true);if (vif->type ==NL80211_IFTYPE_STATION ) {struct mt792x_vif *mvif = (struct mt792x_vif *)vif->drv_priv;
Signature · 1 line
2.25.1
PATCH v3 5/6 wifi: mt76: mt7925: integrate *mlo_sta_cmd and *sta_cmd
In reply to [email protected]From: Ming Yen Hsieh <[email protected]>
Integrate *mlo_sta_cmd and *sta_cmd for the MLO firmware.
---
v2: generate the patch based on the latest mt76 tree
v3: fixed merge error
--- .../net/wireless/mediatek/mt76/mt7925/mcu.c | 64 +-------- .../wireless/mediatek/mt76/mt7925/mcu.c.rej | 131 +++++++++++++----- 2 files changed, 104 insertions(+), 91 deletions(-)
drivers/net/wireless/mediatek/mt76/mt7925/mcu.c +4 -60
@@ -1820,49 +1820,6 @@ mt7925_mcu_sta_mld_tlv(struct sk_buff *skb, } } -static int -mt7925_mcu_sta_cmd (struct mt76_phy *phy, -struct mt76_sta_cmd_info *info) -{ -struct mt76_vif_link *mvif = (struct mt76_vif_link *)info->vif->drv_priv; -struct mt76_dev *dev = phy->dev; -struct sk_buff *skb; -int conn_state; - - skb =__mt76_connac_mcu_alloc_sta_req (dev, mvif, info->wcid, -MT7925_STA_UPDATE_MAX_SIZE ); -if (IS_ERR (skb)) -return PTR_ERR (skb); - - conn_state = info->enable ?CONN_STATE_PORT_SECURE : -CONN_STATE_DISCONNECT ; -if (info->link_sta) -mt76_connac_mcu_sta_basic_tlv (dev, skb, info->link_conf, - info->link_sta, - conn_state, info->newly); -if (info->link_sta && info->enable) { -mt7925_mcu_sta_phy_tlv (skb, info->vif, info->link_sta); -mt7925_mcu_sta_ht_tlv (skb, info->link_sta); -mt7925_mcu_sta_vht_tlv (skb, info->link_sta); -mt76_connac_mcu_sta_uapsd (skb, info->vif, info->link_sta->sta); -mt7925_mcu_sta_amsdu_tlv (skb, info->vif, info->link_sta); -mt7925_mcu_sta_he_tlv (skb, info->link_sta); -mt7925_mcu_sta_he_6g_tlv (skb, info->link_sta); -mt7925_mcu_sta_eht_tlv (skb, info->link_sta); -mt7925_mcu_sta_rate_ctrl_tlv (skb, info->vif, - info->link_sta); -mt7925_mcu_sta_state_v2_tlv (phy, skb, info->link_sta, - info->vif, info->rcpi, - info->state); -mt7925_mcu_sta_mld_tlv (skb, info->vif, info->link_sta->sta); - } - -if (info->enable) -mt7925_mcu_sta_hdr_trans_tlv (skb, info->vif, info->link_sta); - -return mt76_mcu_skb_send_msg (dev, skb, info->cmd, true); -} -static void mt7925_mcu_sta_remove_tlv (struct sk_buff *skb) {
@@ -1875,8 +1832,8 @@ mt7925_mcu_sta_remove_tlv(struct sk_buff *skb) }static int -mt7925_mcu_mlo_sta_cmd (struct mt76_phy *phy, -struct mt76_sta_cmd_info *info) +mt7925_mcu_sta_cmd (struct mt76_phy *phy, +struct mt76_sta_cmd_info *info) {struct mt792x_vif *mvif = (struct mt792x_vif *)info->vif->drv_priv;struct mt76_dev *dev = phy->dev;
@@ -1890,12 +1847,10 @@ mt7925_mcu_mlo_sta_cmd(struct mt76_phy *phy,if (IS_ERR (skb))return PTR_ERR (skb); -if (info->enable) +if (info->enable && info->link_sta) {mt76_connac_mcu_sta_basic_tlv (dev, skb, info->link_conf, info->link_sta, info->enable, info->newly); - -if (info->enable && info->link_sta) {mt7925_mcu_sta_phy_tlv (skb, info->vif, info->link_sta);mt7925_mcu_sta_ht_tlv (skb, info->link_sta);mt7925_mcu_sta_vht_tlv (skb, info->link_sta);
@@ -1946,7 +1901,6 @@ int mt7925_mcu_sta_update(struct mt792x_dev *dev, };struct mt792x_sta *msta;struct mt792x_link_sta *mlink; -int err;if (link_sta) { msta = (struct mt792x_sta *)link_sta->sta->drv_priv;
@@ -1954,17 +1908,7 @@ int mt7925_mcu_sta_update(struct mt792x_dev *dev, } info.wcid = link_sta ? &mlink->wcid : &mvif->sta.deflink.wcid; -if (link_sta) - info.newly = state !=MT76_STA_INFO_STATE_ASSOC ; -else - info.newly = state ==MT76_STA_INFO_STATE_ASSOC ? false : true; - -if (ieee80211_vif_is_mld (vif)) - err =mt7925_mcu_mlo_sta_cmd (&dev->mphy, &info); -else - err =mt7925_mcu_sta_cmd (&dev->mphy, &info); - -return err; +return mt7925_mcu_sta_cmd (&dev->mphy, &info); } int mt7925_mcu_set_beacon_filter(struct mt792x_dev *dev,
drivers/net/wireless/mediatek/mt76/mt7925/mcu.c.rej +100 -31
135 lines not on this page · raw message
Signature · 1 line
2.25.1
PATCH v3 6/6 wifi: mt76: mt7925: update the power-saving flow
In reply to [email protected]From: Ming Yen Hsieh <[email protected]>
After joining MLO, ensure that all links are setup before enabling power-saving.
---
v2, v3: generate the patch based on the latest mt76 tree
--- .../net/wireless/mediatek/mt76/mt7925/init.c | 1 + .../net/wireless/mediatek/mt76/mt7925/main.c | 65 ++++++++++++++++--- .../wireless/mediatek/mt76/mt7925/mt7925.h | 1 + drivers/net/wireless/mediatek/mt76/mt792x.h | 9 +++ 4 files changed, 67 insertions(+), 9 deletions(-)
drivers/net/wireless/mediatek/mt76/mt7925/init.c +1 -0
@@ -244,6 +244,7 @@ int mt7925_register_device(struct mt792x_dev *dev) dev->mt76.tx_worker.fn = mt792x_tx_worker;INIT_DELAYED_WORK (&dev->pm.ps_work, mt792x_pm_power_save_work); +INIT_DELAYED_WORK (&dev->mlo_pm_work, mt7925_mlo_pm_work);INIT_WORK (&dev->pm.wake_work, mt792x_pm_wake_work);spin_lock_init (&dev->pm.wake.lock);mutex_init (&dev->pm.mutex);
drivers/net/wireless/mediatek/mt76/mt7925/main.c +56 -9
108 lines not on this page · raw message
drivers/net/wireless/mediatek/mt76/mt7925/mt7925.h +1 -0
@@ -268,6 +268,7 @@ int mt7925_mcu_uni_tx_ba(struct mt792x_dev *dev,int mt7925_mcu_uni_rx_ba (struct mt792x_dev *dev,struct ieee80211_ampdu_params *params,bool enable); +void mt7925_mlo_pm_work (struct work_struct *work);void mt7925_scan_work (struct work_struct *work);void mt7925_roc_work (struct work_struct *work); int mt7925_mcu_uni_bss_ps(struct mt792x_dev *dev,
drivers/net/wireless/mediatek/mt76/mt792x.h +9 -0
@@ -81,6 +81,13 @@ enum mt792x_reg_power_type { MT_AP_VLP, }; +enum mt792x_mlo_pm_state { + MT792x_MLO_LINK_DISASSOC, + MT792x_MLO_LINK_ASSOC, + MT792x_MLO_CHANGED_PS_PENDING, + MT792x_MLO_CHANGED_PS, +}; + DECLARE_EWMA(avg_signal, 10, 8)struct mt792x_link_sta {
@@ -134,6 +141,7 @@ struct mt792x_vif {struct mt792x_phy *phy;u16 valid_links;u8 deflink_id; +enum mt792x_mlo_pm_state mlo_pm_state;struct work_struct csa_work;struct timer_list csa_timer;
@@ -239,6 +247,7 @@ struct mt792x_dev {const struct mt792x_irq_map *irq_map;struct work_struct ipv6_ns_work; +struct delayed_work mlo_pm_work;/* IPv6 addresses for WoWLAN */ struct sk_buff_head ipv6_ns_list;
Signature · 1 line
2.25.1
Hi Sean,
Quoted 2 lines · [email protected] <[email protected]> wrote:
From: Sean Wang <[email protected]>
The "From" doesn't match one of s-o-b. I suppose here should be Ming Yen?
Quoted 10 lines
For MLO, mac80211 will send the BA action for each link to the driver, so the driver does not need to handle it itself. Therefore, revert this patch.
Fixes e38a82d25b08 ("wifi: mt76: connac: Extend mt76_connac_mcu_uni_add_dev for MLO")Signed-off-by Ming Yen Hsieh <[email protected]>Signed-off-by Sean Wang <[email protected]>