On 01.09.23 08:30, Yi-Chia Hsieh wrote:
Per peer Tx/Rx statistic can only be obtained by querying WM when WED is
on. This patch switches to periodic event reporting in the case of WED
being enabled.
Signed-off-by: Yi-Chia Hsieh <yi-chia.hsieh@xxxxxxxxxxxx>
---
v2: split series
---
.../wireless/mediatek/mt76/mt76_connac_mcu.h | 15 ++++
.../net/wireless/mediatek/mt76/mt7996/mac.c | 5 ++
.../net/wireless/mediatek/mt76/mt7996/main.c | 15 ++++
.../net/wireless/mediatek/mt76/mt7996/mcu.c | 68 +++++++++++++++++++
.../net/wireless/mediatek/mt76/mt7996/mcu.h | 26 +++++++
.../wireless/mediatek/mt76/mt7996/mt7996.h | 1 +
6 files changed, 130 insertions(+)
diff --git a/drivers/net/wireless/mediatek/mt76/mt7996/mcu.h b/drivers/net/wireless/mediatek/mt76/mt7996/mcu.h
index 078f82858621..5aece2046a9d 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7996/mcu.h
+++ b/drivers/net/wireless/mediatek/mt76/mt7996/mcu.h
@@ -153,6 +153,32 @@ struct mt7996_mcu_mib {
__le64 data;
} __packed;
+struct mt7996_mcu_all_sta_info_event {
+ u8 rsv[4];
+ __le16 tag;
+ __le16 len;
+ u8 more;
+ u8 rsv2;
+ __le16 sta_num;
+ u8 rsv3[2];
+
+ union {
+ struct {
+ __le16 wlan_idx;
+ u8 rsv[2];
+ __le32 tx_bytes[IEEE80211_NUM_ACS];
+ __le32 rx_bytes[IEEE80211_NUM_ACS];
+ } adm_stat[];
+
+ struct {
+ __le16 wlan_idx;
+ u8 rsv[2];
+ __le32 tx_msdu_cnt;
+ __le32 rx_msdu_cnt;
+ } msdu_cnt[];
+ };
+} __packed;
With this, I'm getting compiler errors like this one:
mcu.h:171:19: error: flexible array member in union
- Felix