diff options
| author | Sean Wang <sean.wang@mediatek.com> | 2024-07-06 01:27:44 -0700 |
|---|---|---|
| committer | Felix Fietkau <nbd@nbd.name> | 2024-07-09 23:02:01 +0200 |
| commit | 00e1ca0cad2e072df173ac6e8290109288352307 (patch) | |
| tree | 8255891423a3c594e16e0c6268d8c94f61a63996 /drivers/net/wireless/mediatek/mt76/mt792x.h | |
| parent | 882b97c16ab861d7e267262df48b32d6db4121f1 (diff) | |
| download | linux-00e1ca0cad2e072df173ac6e8290109288352307.tar.gz linux-00e1ca0cad2e072df173ac6e8290109288352307.tar.bz2 linux-00e1ca0cad2e072df173ac6e8290109288352307.zip | |
wifi: mt76: mt7925: set mt7925_mcu_sta_key_tlv according to link id
configure mt7925_mcu_sta_key_tlv according to link id
We created a link id field in the common structure mt76_wcid so that
mt7925_mcu_sta_key_tlv can access per-link STA/BSS. Additionally,
.link_id will be required when reporting the link information of Rx status
to mac80211. We will submit the changes for reporting the Rx status in
a separate patch.
Co-developed-by: Ming Yen Hsieh <mingyen.hsieh@mediatek.com>
Signed-off-by: Ming Yen Hsieh <mingyen.hsieh@mediatek.com>
Co-developed-by: Deren Wu <deren.wu@mediatek.com>
Signed-off-by: Deren Wu <deren.wu@mediatek.com>
Signed-off-by: Sean Wang <sean.wang@mediatek.com>
Link: https://patch.msgid.link/16d65aae010113f9be3c4e6e759b4226d396a1be.1720248331.git.sean.wang@kernel.org
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'drivers/net/wireless/mediatek/mt76/mt792x.h')
| -rw-r--r-- | drivers/net/wireless/mediatek/mt76/mt792x.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/drivers/net/wireless/mediatek/mt76/mt792x.h b/drivers/net/wireless/mediatek/mt76/mt792x.h index 69eb8dac0b70..fe5a6c932705 100644 --- a/drivers/net/wireless/mediatek/mt76/mt792x.h +++ b/drivers/net/wireless/mediatek/mt76/mt792x.h @@ -273,6 +273,17 @@ mt792x_vif_to_bss_conf(struct ieee80211_vif *vif, unsigned int link_id) return link_conf_dereference_protected(vif, link_id); } +static inline struct ieee80211_link_sta * +mt792x_sta_to_link_sta(struct ieee80211_vif *vif, struct ieee80211_sta *sta, + unsigned int link_id) +{ + if (!ieee80211_vif_is_mld(vif) || + link_id >= IEEE80211_LINK_UNSPECIFIED) + return &sta->deflink; + + return link_sta_dereference_protected(sta, link_id); +} + static inline struct mt792x_dev * mt792x_hw_dev(struct ieee80211_hw *hw) { |
