wifi: mt76: mt7996: Add mcu commands for getting sta tx statistic

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 <[email protected]>
Signed-off-by: Money Wang <[email protected]>
Signed-off-by: Peter Chiu <[email protected]>
Signed-off-by: Evelyn Tsai <[email protected]>
Signed-off-by: Ryder Lee <[email protected]>
Signed-off-by: Felix Fietkau <[email protected]>
This commit is contained in:
Yi-Chia Hsieh
2023-09-30 20:17:46 +02:00
committed by Felix Fietkau
parent c27f01c4c8
commit 30aba4c183
6 changed files with 130 additions and 0 deletions
+15
View File
@@ -1022,6 +1022,8 @@ enum {
MCU_UNI_EVENT_ROC = 0x27,
MCU_UNI_EVENT_TX_DONE = 0x2d,
MCU_UNI_EVENT_NIC_CAPAB = 0x43,
MCU_UNI_EVENT_PER_STA_INFO = 0x6d,
MCU_UNI_EVENT_ALL_STA_INFO = 0x6e,
};
#define MCU_UNI_CMD_EVENT BIT(1)
@@ -1240,6 +1242,8 @@ enum {
MCU_UNI_CMD_VOW = 0x37,
MCU_UNI_CMD_RRO = 0x57,
MCU_UNI_CMD_OFFCH_SCAN_CTRL = 0x58,
MCU_UNI_CMD_PER_STA_INFO = 0x6d,
MCU_UNI_CMD_ALL_STA_INFO = 0x6e,
MCU_UNI_CMD_ASSERT_DUMP = 0x6f,
};
@@ -1320,6 +1324,17 @@ enum {
UNI_OFFLOAD_OFFLOAD_BMC_RPY_DETECT,
};
enum UNI_ALL_STA_INFO_TAG {
UNI_ALL_STA_TX_RATE,
UNI_ALL_STA_TX_STAT,
UNI_ALL_STA_TXRX_ADM_STAT,
UNI_ALL_STA_TXRX_AIR_TIME,
UNI_ALL_STA_DATA_TX_RETRY_COUNT,
UNI_ALL_STA_GI_MODE,
UNI_ALL_STA_TXRX_MSDU_COUNT,
UNI_ALL_STA_MAX_NUM
};
enum {
MT_NIC_CAP_TX_RESOURCE,
MT_NIC_CAP_TX_EFUSE_ADDR,