18e99ea8dSJohannes Berg /* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */ 28e99ea8dSJohannes Berg /* 3cb2b6ce8SMiri Korenblit * Copyright (C) 2012-2014, 2018, 2020 - 2021, 2023 - 2024 Intel Corporation 48e99ea8dSJohannes Berg * Copyright (C) 2013-2015 Intel Mobile Communications GmbH 58e99ea8dSJohannes Berg * Copyright (C) 2016-2017 Intel Deutschland GmbH 68e99ea8dSJohannes Berg */ 7d172a5efSJohannes Berg #ifndef __iwl_fw_api_stats_h__ 8d172a5efSJohannes Berg #define __iwl_fw_api_stats_h__ 9d172a5efSJohannes Berg #include "mac.h" 10b6e3d1baSAnjaneyulu #include "mac-cfg.h" 11d172a5efSJohannes Berg 12d172a5efSJohannes Berg struct mvm_statistics_dbg { 13d172a5efSJohannes Berg __le32 burst_check; 14d172a5efSJohannes Berg __le32 burst_count; 15d172a5efSJohannes Berg __le32 wait_for_silence_timeout_cnt; 16d172a5efSJohannes Berg u8 reserved[12]; 17d172a5efSJohannes Berg } __packed; /* STATISTICS_DEBUG_API_S_VER_2 */ 18d172a5efSJohannes Berg 19d172a5efSJohannes Berg struct mvm_statistics_div { 20d172a5efSJohannes Berg __le32 tx_on_a; 21d172a5efSJohannes Berg __le32 tx_on_b; 22d172a5efSJohannes Berg __le32 exec_time; 23d172a5efSJohannes Berg __le32 probe_time; 24d172a5efSJohannes Berg __le32 rssi_ant; 25d172a5efSJohannes Berg __le32 reserved2; 26d172a5efSJohannes Berg } __packed; /* STATISTICS_SLOW_DIV_API_S_VER_2 */ 27d172a5efSJohannes Berg 28d172a5efSJohannes Berg /** 29d172a5efSJohannes Berg * struct mvm_statistics_rx_non_phy 30d172a5efSJohannes Berg * @bogus_cts: CTS received when not expecting CTS 31d172a5efSJohannes Berg * @bogus_ack: ACK received when not expecting ACK 32d172a5efSJohannes Berg * @non_channel_beacons: beacons with our bss id but not on our serving channel 33d172a5efSJohannes Berg * @channel_beacons: beacons with our bss id and in our serving channel 34d172a5efSJohannes Berg * @num_missed_bcon: number of missed beacons 35d172a5efSJohannes Berg * @adc_rx_saturation_time: count in 0.8us units the time the ADC was in 36d172a5efSJohannes Berg * saturation 37d172a5efSJohannes Berg * @ina_detection_search_time: total time (in 0.8us) searched for INA 38d172a5efSJohannes Berg * @beacon_silence_rssi_a: RSSI silence after beacon frame 39d172a5efSJohannes Berg * @beacon_silence_rssi_b: RSSI silence after beacon frame 40d172a5efSJohannes Berg * @beacon_silence_rssi_c: RSSI silence after beacon frame 41d172a5efSJohannes Berg * @interference_data_flag: flag for interference data availability. 1 when data 42d172a5efSJohannes Berg * is available. 43d172a5efSJohannes Berg * @channel_load: counts RX Enable time in uSec 44d295a898SMordechay Goodstein * @beacon_rssi_a: beacon RSSI on antenna A 45d172a5efSJohannes Berg * @beacon_rssi_b: beacon RSSI on antenna B 46d172a5efSJohannes Berg * @beacon_rssi_c: beacon RSSI on antenna C 47d172a5efSJohannes Berg * @beacon_energy_a: beacon energy on antenna A 48d172a5efSJohannes Berg * @beacon_energy_b: beacon energy on antenna B 49d172a5efSJohannes Berg * @beacon_energy_c: beacon energy on antenna C 50d172a5efSJohannes Berg * @num_bt_kills: number of BT "kills" (frame TX aborts) 51d172a5efSJohannes Berg * @mac_id: mac ID 52d172a5efSJohannes Berg */ 53d172a5efSJohannes Berg struct mvm_statistics_rx_non_phy { 54d172a5efSJohannes Berg __le32 bogus_cts; 55d172a5efSJohannes Berg __le32 bogus_ack; 56d172a5efSJohannes Berg __le32 non_channel_beacons; 57d172a5efSJohannes Berg __le32 channel_beacons; 58d172a5efSJohannes Berg __le32 num_missed_bcon; 59d172a5efSJohannes Berg __le32 adc_rx_saturation_time; 60d172a5efSJohannes Berg __le32 ina_detection_search_time; 61d172a5efSJohannes Berg __le32 beacon_silence_rssi_a; 62d172a5efSJohannes Berg __le32 beacon_silence_rssi_b; 63d172a5efSJohannes Berg __le32 beacon_silence_rssi_c; 64d172a5efSJohannes Berg __le32 interference_data_flag; 65d172a5efSJohannes Berg __le32 channel_load; 66d172a5efSJohannes Berg __le32 beacon_rssi_a; 67d172a5efSJohannes Berg __le32 beacon_rssi_b; 68d172a5efSJohannes Berg __le32 beacon_rssi_c; 69d172a5efSJohannes Berg __le32 beacon_energy_a; 70d172a5efSJohannes Berg __le32 beacon_energy_b; 71d172a5efSJohannes Berg __le32 beacon_energy_c; 72d172a5efSJohannes Berg __le32 num_bt_kills; 73d172a5efSJohannes Berg __le32 mac_id; 74d172a5efSJohannes Berg } __packed; /* STATISTICS_RX_NON_PHY_API_S_VER_4 */ 75d172a5efSJohannes Berg 76d172a5efSJohannes Berg struct mvm_statistics_rx_non_phy_v3 { 77d172a5efSJohannes Berg __le32 bogus_cts; /* CTS received when not expecting CTS */ 78d172a5efSJohannes Berg __le32 bogus_ack; /* ACK received when not expecting ACK */ 79d172a5efSJohannes Berg __le32 non_bssid_frames; /* number of frames with BSSID that 80d172a5efSJohannes Berg * doesn't belong to the STA BSSID */ 81d172a5efSJohannes Berg __le32 filtered_frames; /* count frames that were dumped in the 82d172a5efSJohannes Berg * filtering process */ 83d172a5efSJohannes Berg __le32 non_channel_beacons; /* beacons with our bss id but not on 84d172a5efSJohannes Berg * our serving channel */ 85d172a5efSJohannes Berg __le32 channel_beacons; /* beacons with our bss id and in our 86d172a5efSJohannes Berg * serving channel */ 87d172a5efSJohannes Berg __le32 num_missed_bcon; /* number of missed beacons */ 88d172a5efSJohannes Berg __le32 adc_rx_saturation_time; /* count in 0.8us units the time the 89d172a5efSJohannes Berg * ADC was in saturation */ 90d172a5efSJohannes Berg __le32 ina_detection_search_time;/* total time (in 0.8us) searched 91d172a5efSJohannes Berg * for INA */ 92d172a5efSJohannes Berg __le32 beacon_silence_rssi_a; /* RSSI silence after beacon frame */ 93d172a5efSJohannes Berg __le32 beacon_silence_rssi_b; /* RSSI silence after beacon frame */ 94d172a5efSJohannes Berg __le32 beacon_silence_rssi_c; /* RSSI silence after beacon frame */ 95d172a5efSJohannes Berg __le32 interference_data_flag; /* flag for interference data 96d172a5efSJohannes Berg * availability. 1 when data is 97d172a5efSJohannes Berg * available. */ 98d172a5efSJohannes Berg __le32 channel_load; /* counts RX Enable time in uSec */ 99d172a5efSJohannes Berg __le32 dsp_false_alarms; /* DSP false alarm (both OFDM 100d172a5efSJohannes Berg * and CCK) counter */ 101d172a5efSJohannes Berg __le32 beacon_rssi_a; 102d172a5efSJohannes Berg __le32 beacon_rssi_b; 103d172a5efSJohannes Berg __le32 beacon_rssi_c; 104d172a5efSJohannes Berg __le32 beacon_energy_a; 105d172a5efSJohannes Berg __le32 beacon_energy_b; 106d172a5efSJohannes Berg __le32 beacon_energy_c; 107d172a5efSJohannes Berg __le32 num_bt_kills; 108d172a5efSJohannes Berg __le32 mac_id; 109d172a5efSJohannes Berg __le32 directed_data_mpdu; 110d172a5efSJohannes Berg } __packed; /* STATISTICS_RX_NON_PHY_API_S_VER_3 */ 111d172a5efSJohannes Berg 112d172a5efSJohannes Berg struct mvm_statistics_rx_phy { 113d172a5efSJohannes Berg __le32 unresponded_rts; 114d172a5efSJohannes Berg __le32 rxe_frame_lmt_overrun; 115d172a5efSJohannes Berg __le32 sent_ba_rsp_cnt; 116d172a5efSJohannes Berg __le32 dsp_self_kill; 117d172a5efSJohannes Berg __le32 reserved; 118d172a5efSJohannes Berg } __packed; /* STATISTICS_RX_PHY_API_S_VER_3 */ 119d172a5efSJohannes Berg 120d172a5efSJohannes Berg struct mvm_statistics_rx_phy_v2 { 121d172a5efSJohannes Berg __le32 ina_cnt; 122d172a5efSJohannes Berg __le32 fina_cnt; 123d172a5efSJohannes Berg __le32 plcp_err; 124d172a5efSJohannes Berg __le32 crc32_err; 125d172a5efSJohannes Berg __le32 overrun_err; 126d172a5efSJohannes Berg __le32 early_overrun_err; 127d172a5efSJohannes Berg __le32 crc32_good; 128d172a5efSJohannes Berg __le32 false_alarm_cnt; 129d172a5efSJohannes Berg __le32 fina_sync_err_cnt; 130d172a5efSJohannes Berg __le32 sfd_timeout; 131d172a5efSJohannes Berg __le32 fina_timeout; 132d172a5efSJohannes Berg __le32 unresponded_rts; 133d172a5efSJohannes Berg __le32 rxe_frame_lmt_overrun; 134d172a5efSJohannes Berg __le32 sent_ack_cnt; 135d172a5efSJohannes Berg __le32 sent_cts_cnt; 136d172a5efSJohannes Berg __le32 sent_ba_rsp_cnt; 137d172a5efSJohannes Berg __le32 dsp_self_kill; 138d172a5efSJohannes Berg __le32 mh_format_err; 139d172a5efSJohannes Berg __le32 re_acq_main_rssi_sum; 140d172a5efSJohannes Berg __le32 reserved; 141d172a5efSJohannes Berg } __packed; /* STATISTICS_RX_PHY_API_S_VER_2 */ 142d172a5efSJohannes Berg 143d172a5efSJohannes Berg struct mvm_statistics_rx_ht_phy_v1 { 144d172a5efSJohannes Berg __le32 plcp_err; 145d172a5efSJohannes Berg __le32 overrun_err; 146d172a5efSJohannes Berg __le32 early_overrun_err; 147d172a5efSJohannes Berg __le32 crc32_good; 148d172a5efSJohannes Berg __le32 crc32_err; 149d172a5efSJohannes Berg __le32 mh_format_err; 150d172a5efSJohannes Berg __le32 agg_crc32_good; 151d172a5efSJohannes Berg __le32 agg_mpdu_cnt; 152d172a5efSJohannes Berg __le32 agg_cnt; 153d172a5efSJohannes Berg __le32 unsupport_mcs; 154d172a5efSJohannes Berg } __packed; /* STATISTICS_HT_RX_PHY_API_S_VER_1 */ 155d172a5efSJohannes Berg 156d172a5efSJohannes Berg struct mvm_statistics_rx_ht_phy { 157d172a5efSJohannes Berg __le32 mh_format_err; 158d172a5efSJohannes Berg __le32 agg_mpdu_cnt; 159d172a5efSJohannes Berg __le32 agg_cnt; 160d172a5efSJohannes Berg __le32 unsupport_mcs; 161d172a5efSJohannes Berg } __packed; /* STATISTICS_HT_RX_PHY_API_S_VER_2 */ 162d172a5efSJohannes Berg 163d172a5efSJohannes Berg struct mvm_statistics_tx_non_phy_v3 { 164d172a5efSJohannes Berg __le32 preamble_cnt; 165d172a5efSJohannes Berg __le32 rx_detected_cnt; 166d172a5efSJohannes Berg __le32 bt_prio_defer_cnt; 167d172a5efSJohannes Berg __le32 bt_prio_kill_cnt; 168d172a5efSJohannes Berg __le32 few_bytes_cnt; 169d172a5efSJohannes Berg __le32 cts_timeout; 170d172a5efSJohannes Berg __le32 ack_timeout; 171d172a5efSJohannes Berg __le32 expected_ack_cnt; 172d172a5efSJohannes Berg __le32 actual_ack_cnt; 173d172a5efSJohannes Berg __le32 dump_msdu_cnt; 174d172a5efSJohannes Berg __le32 burst_abort_next_frame_mismatch_cnt; 175d172a5efSJohannes Berg __le32 burst_abort_missing_next_frame_cnt; 176d172a5efSJohannes Berg __le32 cts_timeout_collision; 177d172a5efSJohannes Berg __le32 ack_or_ba_timeout_collision; 178d172a5efSJohannes Berg } __packed; /* STATISTICS_TX_NON_PHY_API_S_VER_3 */ 179d172a5efSJohannes Berg 180d172a5efSJohannes Berg struct mvm_statistics_tx_non_phy { 181d172a5efSJohannes Berg __le32 bt_prio_defer_cnt; 182d172a5efSJohannes Berg __le32 bt_prio_kill_cnt; 183d172a5efSJohannes Berg __le32 few_bytes_cnt; 184d172a5efSJohannes Berg __le32 cts_timeout; 185d172a5efSJohannes Berg __le32 ack_timeout; 186d172a5efSJohannes Berg __le32 dump_msdu_cnt; 187d172a5efSJohannes Berg __le32 burst_abort_next_frame_mismatch_cnt; 188d172a5efSJohannes Berg __le32 burst_abort_missing_next_frame_cnt; 189d172a5efSJohannes Berg __le32 cts_timeout_collision; 190d172a5efSJohannes Berg __le32 ack_or_ba_timeout_collision; 191d172a5efSJohannes Berg } __packed; /* STATISTICS_TX_NON_PHY_API_S_VER_4 */ 192d172a5efSJohannes Berg 193d172a5efSJohannes Berg #define MAX_CHAINS 3 194d172a5efSJohannes Berg 195d172a5efSJohannes Berg struct mvm_statistics_tx_non_phy_agg { 196d172a5efSJohannes Berg __le32 ba_timeout; 197d172a5efSJohannes Berg __le32 ba_reschedule_frames; 198d172a5efSJohannes Berg __le32 scd_query_agg_frame_cnt; 199d172a5efSJohannes Berg __le32 scd_query_no_agg; 200d172a5efSJohannes Berg __le32 scd_query_agg; 201d172a5efSJohannes Berg __le32 scd_query_mismatch; 202d172a5efSJohannes Berg __le32 frame_not_ready; 203d172a5efSJohannes Berg __le32 underrun; 204d172a5efSJohannes Berg __le32 bt_prio_kill; 205d172a5efSJohannes Berg __le32 rx_ba_rsp_cnt; 206d172a5efSJohannes Berg __s8 txpower[MAX_CHAINS]; 207d172a5efSJohannes Berg __s8 reserved; 208d172a5efSJohannes Berg __le32 reserved2; 209d172a5efSJohannes Berg } __packed; /* STATISTICS_TX_NON_PHY_AGG_API_S_VER_1 */ 210d172a5efSJohannes Berg 211d172a5efSJohannes Berg struct mvm_statistics_tx_channel_width { 212d172a5efSJohannes Berg __le32 ext_cca_narrow_ch20[1]; 213d172a5efSJohannes Berg __le32 ext_cca_narrow_ch40[2]; 214d172a5efSJohannes Berg __le32 ext_cca_narrow_ch80[3]; 215d172a5efSJohannes Berg __le32 ext_cca_narrow_ch160[4]; 216d172a5efSJohannes Berg __le32 last_tx_ch_width_indx; 217d172a5efSJohannes Berg __le32 rx_detected_per_ch_width[4]; 218d172a5efSJohannes Berg __le32 success_per_ch_width[4]; 219d172a5efSJohannes Berg __le32 fail_per_ch_width[4]; 220d172a5efSJohannes Berg }; /* STATISTICS_TX_CHANNEL_WIDTH_API_S_VER_1 */ 221d172a5efSJohannes Berg 222d172a5efSJohannes Berg struct mvm_statistics_tx_v4 { 223d172a5efSJohannes Berg struct mvm_statistics_tx_non_phy_v3 general; 224d172a5efSJohannes Berg struct mvm_statistics_tx_non_phy_agg agg; 225d172a5efSJohannes Berg struct mvm_statistics_tx_channel_width channel_width; 226d172a5efSJohannes Berg } __packed; /* STATISTICS_TX_API_S_VER_4 */ 227d172a5efSJohannes Berg 228d172a5efSJohannes Berg struct mvm_statistics_tx { 229d172a5efSJohannes Berg struct mvm_statistics_tx_non_phy general; 230d172a5efSJohannes Berg struct mvm_statistics_tx_non_phy_agg agg; 231d172a5efSJohannes Berg struct mvm_statistics_tx_channel_width channel_width; 232d172a5efSJohannes Berg } __packed; /* STATISTICS_TX_API_S_VER_5 */ 233d172a5efSJohannes Berg 234d172a5efSJohannes Berg 235d172a5efSJohannes Berg struct mvm_statistics_bt_activity { 236d172a5efSJohannes Berg __le32 hi_priority_tx_req_cnt; 237d172a5efSJohannes Berg __le32 hi_priority_tx_denied_cnt; 238d172a5efSJohannes Berg __le32 lo_priority_tx_req_cnt; 239d172a5efSJohannes Berg __le32 lo_priority_tx_denied_cnt; 240d172a5efSJohannes Berg __le32 hi_priority_rx_req_cnt; 241d172a5efSJohannes Berg __le32 hi_priority_rx_denied_cnt; 242d172a5efSJohannes Berg __le32 lo_priority_rx_req_cnt; 243d172a5efSJohannes Berg __le32 lo_priority_rx_denied_cnt; 244d172a5efSJohannes Berg } __packed; /* STATISTICS_BT_ACTIVITY_API_S_VER_1 */ 245d172a5efSJohannes Berg 246d172a5efSJohannes Berg struct mvm_statistics_general_common_v19 { 247d172a5efSJohannes Berg __le32 radio_temperature; 248d172a5efSJohannes Berg __le32 radio_voltage; 249d172a5efSJohannes Berg struct mvm_statistics_dbg dbg; 250d172a5efSJohannes Berg __le32 sleep_time; 251d172a5efSJohannes Berg __le32 slots_out; 252d172a5efSJohannes Berg __le32 slots_idle; 253d172a5efSJohannes Berg __le32 ttl_timestamp; 254d172a5efSJohannes Berg struct mvm_statistics_div slow_div; 255d172a5efSJohannes Berg __le32 rx_enable_counter; 256d172a5efSJohannes Berg /* 257d172a5efSJohannes Berg * num_of_sos_states: 258d172a5efSJohannes Berg * count the number of times we have to re-tune 259d172a5efSJohannes Berg * in order to get out of bad PHY status 260d172a5efSJohannes Berg */ 261d172a5efSJohannes Berg __le32 num_of_sos_states; 262d172a5efSJohannes Berg __le32 beacon_filtered; 263d172a5efSJohannes Berg __le32 missed_beacons; 264d172a5efSJohannes Berg u8 beacon_filter_average_energy; 265d172a5efSJohannes Berg u8 beacon_filter_reason; 266d172a5efSJohannes Berg u8 beacon_filter_current_energy; 267d172a5efSJohannes Berg u8 beacon_filter_reserved; 268d172a5efSJohannes Berg __le32 beacon_filter_delta_time; 269d172a5efSJohannes Berg struct mvm_statistics_bt_activity bt_activity; 270d172a5efSJohannes Berg __le64 rx_time; 271d172a5efSJohannes Berg __le64 on_time_rf; 272d172a5efSJohannes Berg __le64 on_time_scan; 273d172a5efSJohannes Berg __le64 tx_time; 274d172a5efSJohannes Berg } __packed; 275d172a5efSJohannes Berg 276d172a5efSJohannes Berg struct mvm_statistics_general_common { 277d172a5efSJohannes Berg __le32 radio_temperature; 278d172a5efSJohannes Berg struct mvm_statistics_dbg dbg; 279d172a5efSJohannes Berg __le32 sleep_time; 280d172a5efSJohannes Berg __le32 slots_out; 281d172a5efSJohannes Berg __le32 slots_idle; 282d172a5efSJohannes Berg __le32 ttl_timestamp; 283d172a5efSJohannes Berg struct mvm_statistics_div slow_div; 284d172a5efSJohannes Berg __le32 rx_enable_counter; 285d172a5efSJohannes Berg /* 286d172a5efSJohannes Berg * num_of_sos_states: 287d172a5efSJohannes Berg * count the number of times we have to re-tune 288d172a5efSJohannes Berg * in order to get out of bad PHY status 289d172a5efSJohannes Berg */ 290d172a5efSJohannes Berg __le32 num_of_sos_states; 291d172a5efSJohannes Berg __le32 beacon_filtered; 292d172a5efSJohannes Berg __le32 missed_beacons; 293d172a5efSJohannes Berg u8 beacon_filter_average_energy; 294d172a5efSJohannes Berg u8 beacon_filter_reason; 295d172a5efSJohannes Berg u8 beacon_filter_current_energy; 296d172a5efSJohannes Berg u8 beacon_filter_reserved; 297d172a5efSJohannes Berg __le32 beacon_filter_delta_time; 298d172a5efSJohannes Berg struct mvm_statistics_bt_activity bt_activity; 299d172a5efSJohannes Berg __le64 rx_time; 300d172a5efSJohannes Berg __le64 on_time_rf; 301d172a5efSJohannes Berg __le64 on_time_scan; 302d172a5efSJohannes Berg __le64 tx_time; 303d172a5efSJohannes Berg } __packed; /* STATISTICS_GENERAL_API_S_VER_10 */ 304d172a5efSJohannes Berg 305d172a5efSJohannes Berg struct mvm_statistics_general_v8 { 306d172a5efSJohannes Berg struct mvm_statistics_general_common_v19 common; 307d172a5efSJohannes Berg __le32 beacon_counter[NUM_MAC_INDEX]; 308d172a5efSJohannes Berg u8 beacon_average_energy[NUM_MAC_INDEX]; 309d172a5efSJohannes Berg u8 reserved[4 - (NUM_MAC_INDEX % 4)]; 310d172a5efSJohannes Berg } __packed; /* STATISTICS_GENERAL_API_S_VER_8 */ 311d172a5efSJohannes Berg 312606b9ab6SEmmanuel Grumbach struct mvm_statistics_general { 313d172a5efSJohannes Berg struct mvm_statistics_general_common common; 314d172a5efSJohannes Berg __le32 beacon_counter[MAC_INDEX_AUX]; 315d172a5efSJohannes Berg u8 beacon_average_energy[MAC_INDEX_AUX]; 316d172a5efSJohannes Berg u8 reserved[8 - MAC_INDEX_AUX]; 317d172a5efSJohannes Berg } __packed; /* STATISTICS_GENERAL_API_S_VER_10 */ 318d172a5efSJohannes Berg 319d172a5efSJohannes Berg /** 320d172a5efSJohannes Berg * struct mvm_statistics_load - RX statistics for multi-queue devices 321d172a5efSJohannes Berg * @air_time: accumulated air time, per mac 322d172a5efSJohannes Berg * @byte_count: accumulated byte count, per mac 323d172a5efSJohannes Berg * @pkt_count: accumulated packet count, per mac 324d172a5efSJohannes Berg * @avg_energy: average RSSI, per station 325d172a5efSJohannes Berg */ 326d172a5efSJohannes Berg struct mvm_statistics_load { 327d172a5efSJohannes Berg __le32 air_time[MAC_INDEX_AUX]; 328d172a5efSJohannes Berg __le32 byte_count[MAC_INDEX_AUX]; 329d172a5efSJohannes Berg __le32 pkt_count[MAC_INDEX_AUX]; 330*b61ed2b8SMiri Korenblit u8 avg_energy[IWL_STATION_COUNT_MAX]; 331d172a5efSJohannes Berg } __packed; /* STATISTICS_RX_MAC_STATION_S_VER_3 */ 332d172a5efSJohannes Berg 333d172a5efSJohannes Berg struct mvm_statistics_load_v1 { 334d172a5efSJohannes Berg __le32 air_time[NUM_MAC_INDEX]; 335d172a5efSJohannes Berg __le32 byte_count[NUM_MAC_INDEX]; 336d172a5efSJohannes Berg __le32 pkt_count[NUM_MAC_INDEX]; 337*b61ed2b8SMiri Korenblit u8 avg_energy[IWL_STATION_COUNT_MAX]; 338d172a5efSJohannes Berg } __packed; /* STATISTICS_RX_MAC_STATION_S_VER_1 */ 339d172a5efSJohannes Berg 340d172a5efSJohannes Berg struct mvm_statistics_rx { 341d172a5efSJohannes Berg struct mvm_statistics_rx_phy ofdm; 342d172a5efSJohannes Berg struct mvm_statistics_rx_phy cck; 343d172a5efSJohannes Berg struct mvm_statistics_rx_non_phy general; 344d172a5efSJohannes Berg struct mvm_statistics_rx_ht_phy ofdm_ht; 345d172a5efSJohannes Berg } __packed; /* STATISTICS_RX_API_S_VER_4 */ 346d172a5efSJohannes Berg 347d172a5efSJohannes Berg struct mvm_statistics_rx_v3 { 348d172a5efSJohannes Berg struct mvm_statistics_rx_phy_v2 ofdm; 349d172a5efSJohannes Berg struct mvm_statistics_rx_phy_v2 cck; 350d172a5efSJohannes Berg struct mvm_statistics_rx_non_phy_v3 general; 351d172a5efSJohannes Berg struct mvm_statistics_rx_ht_phy_v1 ofdm_ht; 352d172a5efSJohannes Berg } __packed; /* STATISTICS_RX_API_S_VER_3 */ 353d172a5efSJohannes Berg 354d172a5efSJohannes Berg /* 355d172a5efSJohannes Berg * STATISTICS_NOTIFICATION = 0x9d (notification only, not a command) 356d172a5efSJohannes Berg * 357d172a5efSJohannes Berg * By default, uCode issues this notification after receiving a beacon 358d172a5efSJohannes Berg * while associated. To disable this behavior, set DISABLE_NOTIF flag in the 359d172a5efSJohannes Berg * STATISTICS_CMD (0x9c), below. 360d172a5efSJohannes Berg */ 361d172a5efSJohannes Berg 362d172a5efSJohannes Berg struct iwl_notif_statistics_v10 { 363d172a5efSJohannes Berg __le32 flag; 364d172a5efSJohannes Berg struct mvm_statistics_rx_v3 rx; 365d172a5efSJohannes Berg struct mvm_statistics_tx_v4 tx; 366d172a5efSJohannes Berg struct mvm_statistics_general_v8 general; 367d172a5efSJohannes Berg } __packed; /* STATISTICS_NTFY_API_S_VER_10 */ 368d172a5efSJohannes Berg 369d172a5efSJohannes Berg struct iwl_notif_statistics_v11 { 370d172a5efSJohannes Berg __le32 flag; 371d172a5efSJohannes Berg struct mvm_statistics_rx_v3 rx; 372d172a5efSJohannes Berg struct mvm_statistics_tx_v4 tx; 373d172a5efSJohannes Berg struct mvm_statistics_general_v8 general; 374d172a5efSJohannes Berg struct mvm_statistics_load_v1 load_stats; 375d172a5efSJohannes Berg } __packed; /* STATISTICS_NTFY_API_S_VER_11 */ 376d172a5efSJohannes Berg 377606b9ab6SEmmanuel Grumbach struct iwl_notif_statistics { 378d172a5efSJohannes Berg __le32 flag; 379d172a5efSJohannes Berg struct mvm_statistics_rx rx; 380d172a5efSJohannes Berg struct mvm_statistics_tx tx; 381606b9ab6SEmmanuel Grumbach struct mvm_statistics_general general; 382d172a5efSJohannes Berg struct mvm_statistics_load load_stats; 383d172a5efSJohannes Berg } __packed; /* STATISTICS_NTFY_API_S_VER_13 */ 384d172a5efSJohannes Berg 385d172a5efSJohannes Berg /** 386d172a5efSJohannes Berg * enum iwl_statistics_notif_flags - flags used in statistics notification 387d172a5efSJohannes Berg * @IWL_STATISTICS_REPLY_FLG_CLEAR: statistics were cleared after this report 388d172a5efSJohannes Berg */ 389d172a5efSJohannes Berg enum iwl_statistics_notif_flags { 390d172a5efSJohannes Berg IWL_STATISTICS_REPLY_FLG_CLEAR = 0x1, 391d172a5efSJohannes Berg }; 392d172a5efSJohannes Berg 393d172a5efSJohannes Berg /** 394d172a5efSJohannes Berg * enum iwl_statistics_cmd_flags - flags used in statistics command 395d172a5efSJohannes Berg * @IWL_STATISTICS_FLG_CLEAR: request to clear statistics after the report 396d172a5efSJohannes Berg * that's sent after this command 397d172a5efSJohannes Berg * @IWL_STATISTICS_FLG_DISABLE_NOTIF: disable unilateral statistics 398d172a5efSJohannes Berg * notifications 399d172a5efSJohannes Berg */ 400d172a5efSJohannes Berg enum iwl_statistics_cmd_flags { 401d172a5efSJohannes Berg IWL_STATISTICS_FLG_CLEAR = 0x1, 402d172a5efSJohannes Berg IWL_STATISTICS_FLG_DISABLE_NOTIF = 0x2, 403d172a5efSJohannes Berg }; 404d172a5efSJohannes Berg 405d172a5efSJohannes Berg /** 406d172a5efSJohannes Berg * struct iwl_statistics_cmd - statistics config command 407d172a5efSJohannes Berg * @flags: flags from &enum iwl_statistics_cmd_flags 408d172a5efSJohannes Berg */ 409d172a5efSJohannes Berg struct iwl_statistics_cmd { 410d172a5efSJohannes Berg __le32 flags; 411d172a5efSJohannes Berg } __packed; /* STATISTICS_CMD_API_S_VER_1 */ 412d172a5efSJohannes Berg 413853f4954SMordechay Goodstein #define MAX_BCAST_FILTER_NUM 8 414853f4954SMordechay Goodstein 415853f4954SMordechay Goodstein /** 416b6e3d1baSAnjaneyulu * enum iwl_statistics_notify_type_id - type_id used in system statistics 417b6e3d1baSAnjaneyulu * command 418b6e3d1baSAnjaneyulu * @IWL_STATS_NTFY_TYPE_ID_OPER: request legacy statistics 419b6e3d1baSAnjaneyulu * @IWL_STATS_NTFY_TYPE_ID_OPER_PART1: request operational part1 statistics 420b6e3d1baSAnjaneyulu * @IWL_STATS_NTFY_TYPE_ID_OPER_PART2: request operational part2 statistics 421b6e3d1baSAnjaneyulu * @IWL_STATS_NTFY_TYPE_ID_OPER_PART3: request operational part3 statistics 422b6e3d1baSAnjaneyulu * @IWL_STATS_NTFY_TYPE_ID_OPER_PART4: request operational part4 statistics 423b6e3d1baSAnjaneyulu */ 424b6e3d1baSAnjaneyulu enum iwl_statistics_notify_type_id { 425b6e3d1baSAnjaneyulu IWL_STATS_NTFY_TYPE_ID_OPER = BIT(0), 426b6e3d1baSAnjaneyulu IWL_STATS_NTFY_TYPE_ID_OPER_PART1 = BIT(1), 427b6e3d1baSAnjaneyulu IWL_STATS_NTFY_TYPE_ID_OPER_PART2 = BIT(2), 428b6e3d1baSAnjaneyulu IWL_STATS_NTFY_TYPE_ID_OPER_PART3 = BIT(3), 429b6e3d1baSAnjaneyulu IWL_STATS_NTFY_TYPE_ID_OPER_PART4 = BIT(4), 430b6e3d1baSAnjaneyulu }; 431b6e3d1baSAnjaneyulu 432b6e3d1baSAnjaneyulu /** 433b6e3d1baSAnjaneyulu * enum iwl_statistics_cfg_flags - cfg_mask used in system statistics command 434b6e3d1baSAnjaneyulu * @IWL_STATS_CFG_FLG_DISABLE_NTFY_MSK: 0 for enable, 1 for disable 435b6e3d1baSAnjaneyulu * @IWL_STATS_CFG_FLG_ON_DEMAND_NTFY_MSK: 0 for periodic, 1 for on-demand 436b6e3d1baSAnjaneyulu * @IWL_STATS_CFG_FLG_RESET_MSK: 0 for reset statistics after 437b6e3d1baSAnjaneyulu * sending the notification, 1 for do not reset statistics after sending 438b6e3d1baSAnjaneyulu * the notification 439b6e3d1baSAnjaneyulu */ 440b6e3d1baSAnjaneyulu enum iwl_statistics_cfg_flags { 441b6e3d1baSAnjaneyulu IWL_STATS_CFG_FLG_DISABLE_NTFY_MSK = BIT(0), 442b6e3d1baSAnjaneyulu IWL_STATS_CFG_FLG_ON_DEMAND_NTFY_MSK = BIT(1), 443b6e3d1baSAnjaneyulu IWL_STATS_CFG_FLG_RESET_MSK = BIT(2), 444b6e3d1baSAnjaneyulu }; 445b6e3d1baSAnjaneyulu 446b6e3d1baSAnjaneyulu /** 447b6e3d1baSAnjaneyulu * struct iwl_system_statistics_cmd - system statistics command 448b6e3d1baSAnjaneyulu * @cfg_mask: configuration mask, &enum iwl_statistics_cfg_flags 449b6e3d1baSAnjaneyulu * @config_time_sec: time in sec for periodic notification 450b6e3d1baSAnjaneyulu * @type_id_mask: type_id masks, &enum iwl_statistics_notify_type_id 451b6e3d1baSAnjaneyulu */ 452b6e3d1baSAnjaneyulu struct iwl_system_statistics_cmd { 453b6e3d1baSAnjaneyulu __le32 cfg_mask; 454b6e3d1baSAnjaneyulu __le32 config_time_sec; 455b6e3d1baSAnjaneyulu __le32 type_id_mask; 456b6e3d1baSAnjaneyulu } __packed; /* STATISTICS_FW_CMD_API_S_VER_1 */ 457b6e3d1baSAnjaneyulu 458b6e3d1baSAnjaneyulu /** 459853f4954SMordechay Goodstein * enum iwl_fw_statistics_type 460853f4954SMordechay Goodstein * 461853f4954SMordechay Goodstein * @FW_STATISTICS_OPERATIONAL: operational statistics 462853f4954SMordechay Goodstein * @FW_STATISTICS_PHY: phy statistics 463853f4954SMordechay Goodstein * @FW_STATISTICS_MAC: mac statistics 464853f4954SMordechay Goodstein * @FW_STATISTICS_RX: rx statistics 465853f4954SMordechay Goodstein * @FW_STATISTICS_TX: tx statistics 466853f4954SMordechay Goodstein * @FW_STATISTICS_DURATION: duration statistics 467853f4954SMordechay Goodstein * @FW_STATISTICS_HE: he statistics 468853f4954SMordechay Goodstein */ 469853f4954SMordechay Goodstein enum iwl_fw_statistics_type { 470853f4954SMordechay Goodstein FW_STATISTICS_OPERATIONAL, 471853f4954SMordechay Goodstein FW_STATISTICS_PHY, 472853f4954SMordechay Goodstein FW_STATISTICS_MAC, 473853f4954SMordechay Goodstein FW_STATISTICS_RX, 474853f4954SMordechay Goodstein FW_STATISTICS_TX, 475853f4954SMordechay Goodstein FW_STATISTICS_DURATION, 476853f4954SMordechay Goodstein FW_STATISTICS_HE, 477853f4954SMordechay Goodstein }; /* FW_STATISTICS_TYPE_API_E_VER_1 */ 478853f4954SMordechay Goodstein 4796324c173SMordechay Goodstein #define IWL_STATISTICS_TYPE_MSK 0x7f 480853f4954SMordechay Goodstein /** 481853f4954SMordechay Goodstein * struct iwl_statistics_ntfy_hdr 482853f4954SMordechay Goodstein * 483853f4954SMordechay Goodstein * @type: struct type 484853f4954SMordechay Goodstein * @version: version of the struct 485853f4954SMordechay Goodstein * @size: size in bytes 486853f4954SMordechay Goodstein */ 487853f4954SMordechay Goodstein struct iwl_statistics_ntfy_hdr { 488853f4954SMordechay Goodstein u8 type; 489853f4954SMordechay Goodstein u8 version; 490853f4954SMordechay Goodstein __le16 size; 491853f4954SMordechay Goodstein }; /* STATISTICS_NTFY_HDR_API_S_VER_1 */ 492853f4954SMordechay Goodstein 493853f4954SMordechay Goodstein /** 494b6e3d1baSAnjaneyulu * struct iwl_stats_ntfy_per_link 495b6e3d1baSAnjaneyulu * 496b6e3d1baSAnjaneyulu * @beacon_filter_average_energy: Average energy [-dBm] of the 2 497b6e3d1baSAnjaneyulu * antennas. 498b6e3d1baSAnjaneyulu * @air_time: air time 499b6e3d1baSAnjaneyulu * @beacon_counter: all beacons (both filtered and not filtered) 500b6e3d1baSAnjaneyulu * @beacon_average_energy: Average energy [-dBm] of all beacons 501b6e3d1baSAnjaneyulu * (both filtered and not filtered) 502b6e3d1baSAnjaneyulu * @beacon_rssi_a: beacon RSSI on antenna A 503b6e3d1baSAnjaneyulu * @beacon_rssi_b: beacon RSSI on antenna B 504b6e3d1baSAnjaneyulu * @rx_bytes: RX byte count 505b6e3d1baSAnjaneyulu */ 506b6e3d1baSAnjaneyulu struct iwl_stats_ntfy_per_link { 507b6e3d1baSAnjaneyulu __le32 beacon_filter_average_energy; 508b6e3d1baSAnjaneyulu __le32 air_time; 509b6e3d1baSAnjaneyulu __le32 beacon_counter; 510b6e3d1baSAnjaneyulu __le32 beacon_average_energy; 511b6e3d1baSAnjaneyulu __le32 beacon_rssi_a; 512b6e3d1baSAnjaneyulu __le32 beacon_rssi_b; 513b6e3d1baSAnjaneyulu __le32 rx_bytes; 514b6e3d1baSAnjaneyulu } __packed; /* STATISTICS_NTFY_PER_LINK_API_S_VER_1 */ 515b6e3d1baSAnjaneyulu 516b6e3d1baSAnjaneyulu /** 517b6e3d1baSAnjaneyulu * struct iwl_stats_ntfy_part1_per_link 518b6e3d1baSAnjaneyulu * 519b6e3d1baSAnjaneyulu * @rx_time: rx time 520b6e3d1baSAnjaneyulu * @tx_time: tx time 521b6e3d1baSAnjaneyulu * @rx_action: action frames handled by FW 522b6e3d1baSAnjaneyulu * @tx_action: action frames generated and transmitted by FW 523b6e3d1baSAnjaneyulu * @cca_defers: cca defer count 524b6e3d1baSAnjaneyulu * @beacon_filtered: filtered out beacons 525b6e3d1baSAnjaneyulu */ 526b6e3d1baSAnjaneyulu struct iwl_stats_ntfy_part1_per_link { 527b6e3d1baSAnjaneyulu __le64 rx_time; 528b6e3d1baSAnjaneyulu __le64 tx_time; 529b6e3d1baSAnjaneyulu __le32 rx_action; 530b6e3d1baSAnjaneyulu __le32 tx_action; 531b6e3d1baSAnjaneyulu __le32 cca_defers; 532b6e3d1baSAnjaneyulu __le32 beacon_filtered; 533b6e3d1baSAnjaneyulu } __packed; /* STATISTICS_FW_NTFY_OPERATIONAL_PART1_PER_LINK_API_S_VER_1 */ 534b6e3d1baSAnjaneyulu 535b6e3d1baSAnjaneyulu /** 536b6e3d1baSAnjaneyulu * struct iwl_stats_ntfy_per_mac 5376324c173SMordechay Goodstein * 5386324c173SMordechay Goodstein * @beacon_filter_average_energy: Average energy [-dBm] of the 2 5396324c173SMordechay Goodstein * antennas. 5406324c173SMordechay Goodstein * @air_time: air time 5416324c173SMordechay Goodstein * @beacon_counter: all beacons (both filtered and not filtered) 5426324c173SMordechay Goodstein * @beacon_average_energy: all beacons (both filtered and not 5436324c173SMordechay Goodstein * filtered) 5446324c173SMordechay Goodstein * @beacon_rssi_a: beacon RSSI on antenna A 5456324c173SMordechay Goodstein * @beacon_rssi_b: beacon RSSI on antenna B 5466324c173SMordechay Goodstein * @rx_bytes: RX byte count 5476324c173SMordechay Goodstein */ 548b6e3d1baSAnjaneyulu struct iwl_stats_ntfy_per_mac { 5496324c173SMordechay Goodstein __le32 beacon_filter_average_energy; 5506324c173SMordechay Goodstein __le32 air_time; 5516324c173SMordechay Goodstein __le32 beacon_counter; 5526324c173SMordechay Goodstein __le32 beacon_average_energy; 5536324c173SMordechay Goodstein __le32 beacon_rssi_a; 5546324c173SMordechay Goodstein __le32 beacon_rssi_b; 5556324c173SMordechay Goodstein __le32 rx_bytes; 5566324c173SMordechay Goodstein } __packed; /* STATISTICS_NTFY_PER_MAC_API_S_VER_1 */ 5576324c173SMordechay Goodstein 5586324c173SMordechay Goodstein #define IWL_STATS_MAX_BW_INDEX 5 559b6e3d1baSAnjaneyulu /** struct iwl_stats_ntfy_per_phy 5606324c173SMordechay Goodstein * @channel_load: channel load 5616324c173SMordechay Goodstein * @channel_load_by_us: device contribution to MCLM 5626324c173SMordechay Goodstein * @channel_load_not_by_us: other devices' contribution to MCLM 5636324c173SMordechay Goodstein * @clt: CLT HW timer (TIM_CH_LOAD2) 5646324c173SMordechay Goodstein * @act: active accumulator SW 5656324c173SMordechay Goodstein * @elp: elapsed time accumulator SW 5666324c173SMordechay Goodstein * @rx_detected_per_ch_width: number of deferred TX per channel width, 5676324c173SMordechay Goodstein * 0 - 20, 1/2/3 - 40/80/160 5686324c173SMordechay Goodstein * @success_per_ch_width: number of frames that got ACK/BACK/CTS 5696324c173SMordechay Goodstein * per channel BW. note, BACK counted as 1 5706324c173SMordechay Goodstein * @fail_per_ch_width: number of frames that didn't get ACK/BACK/CTS 5716324c173SMordechay Goodstein * per channel BW. note BACK counted as 1 5726324c173SMordechay Goodstein * @last_tx_ch_width_indx: last txed frame channel width index 5736324c173SMordechay Goodstein */ 574b6e3d1baSAnjaneyulu struct iwl_stats_ntfy_per_phy { 5756324c173SMordechay Goodstein __le32 channel_load; 5766324c173SMordechay Goodstein __le32 channel_load_by_us; 5776324c173SMordechay Goodstein __le32 channel_load_not_by_us; 5786324c173SMordechay Goodstein __le32 clt; 5796324c173SMordechay Goodstein __le32 act; 5806324c173SMordechay Goodstein __le32 elp; 5816324c173SMordechay Goodstein __le32 rx_detected_per_ch_width[IWL_STATS_MAX_BW_INDEX]; 5826324c173SMordechay Goodstein __le32 success_per_ch_width[IWL_STATS_MAX_BW_INDEX]; 5836324c173SMordechay Goodstein __le32 fail_per_ch_width[IWL_STATS_MAX_BW_INDEX]; 5846324c173SMordechay Goodstein __le32 last_tx_ch_width_indx; 5856324c173SMordechay Goodstein } __packed; /* STATISTICS_NTFY_PER_PHY_API_S_VER_1 */ 5866324c173SMordechay Goodstein 5876324c173SMordechay Goodstein /** 588b6e3d1baSAnjaneyulu * struct iwl_stats_ntfy_per_sta 5896324c173SMordechay Goodstein * 5906324c173SMordechay Goodstein * @average_energy: in fact it is minus the energy.. 5916324c173SMordechay Goodstein */ 592b6e3d1baSAnjaneyulu struct iwl_stats_ntfy_per_sta { 5936324c173SMordechay Goodstein __le32 average_energy; 5946324c173SMordechay Goodstein } __packed; /* STATISTICS_NTFY_PER_STA_API_S_VER_1 */ 5956324c173SMordechay Goodstein 596b6e3d1baSAnjaneyulu #define IWL_STATS_MAX_PHY_OPERATIONAL 3 597cb2b6ce8SMiri Korenblit #define IWL_STATS_MAX_FW_LINKS (IWL_FW_MAX_LINK_ID + 1) 598b6e3d1baSAnjaneyulu 599b6e3d1baSAnjaneyulu /** 600b6e3d1baSAnjaneyulu * struct iwl_system_statistics_notif_oper 601b6e3d1baSAnjaneyulu * 602b6e3d1baSAnjaneyulu * @time_stamp: time when the notification is sent from firmware 603b6e3d1baSAnjaneyulu * @per_link: per link statistics, &struct iwl_stats_ntfy_per_link 604b6e3d1baSAnjaneyulu * @per_phy: per phy statistics, &struct iwl_stats_ntfy_per_phy 605b6e3d1baSAnjaneyulu * @per_sta: per sta statistics, &struct iwl_stats_ntfy_per_sta 606b6e3d1baSAnjaneyulu */ 607b6e3d1baSAnjaneyulu struct iwl_system_statistics_notif_oper { 608b6e3d1baSAnjaneyulu __le32 time_stamp; 609b6e3d1baSAnjaneyulu struct iwl_stats_ntfy_per_link per_link[IWL_STATS_MAX_FW_LINKS]; 610b6e3d1baSAnjaneyulu struct iwl_stats_ntfy_per_phy per_phy[IWL_STATS_MAX_PHY_OPERATIONAL]; 611*b61ed2b8SMiri Korenblit struct iwl_stats_ntfy_per_sta per_sta[IWL_STATION_COUNT_MAX]; 612b6e3d1baSAnjaneyulu } __packed; /* STATISTICS_FW_NTFY_OPERATIONAL_API_S_VER_3 */ 613b6e3d1baSAnjaneyulu 614b6e3d1baSAnjaneyulu /** 615b6e3d1baSAnjaneyulu * struct iwl_system_statistics_part1_notif_oper 616b6e3d1baSAnjaneyulu * 617b6e3d1baSAnjaneyulu * @time_stamp: time when the notification is sent from firmware 618b6e3d1baSAnjaneyulu * @per_link: per link statistics &struct iwl_stats_ntfy_part1_per_link 619b6e3d1baSAnjaneyulu * @per_phy_crc_error_stats: per phy crc error statistics 620b6e3d1baSAnjaneyulu */ 621b6e3d1baSAnjaneyulu struct iwl_system_statistics_part1_notif_oper { 622b6e3d1baSAnjaneyulu __le32 time_stamp; 623b6e3d1baSAnjaneyulu struct iwl_stats_ntfy_part1_per_link per_link[IWL_STATS_MAX_FW_LINKS]; 624b6e3d1baSAnjaneyulu __le32 per_phy_crc_error_stats[IWL_STATS_MAX_PHY_OPERATIONAL]; 625b6e3d1baSAnjaneyulu } __packed; /* STATISTICS_FW_NTFY_OPERATIONAL_PART1_API_S_VER_4 */ 626b6e3d1baSAnjaneyulu 627b6e3d1baSAnjaneyulu /** 628b6e3d1baSAnjaneyulu * struct iwl_system_statistics_end_notif 629b6e3d1baSAnjaneyulu * 630b6e3d1baSAnjaneyulu * @time_stamp: time when the notification is sent from firmware 631b6e3d1baSAnjaneyulu */ 632b6e3d1baSAnjaneyulu struct iwl_system_statistics_end_notif { 633b6e3d1baSAnjaneyulu __le32 time_stamp; 634b6e3d1baSAnjaneyulu } __packed; /* STATISTICS_FW_NTFY_END_API_S_VER_1 */ 635b6e3d1baSAnjaneyulu 6366324c173SMordechay Goodstein /** 637853f4954SMordechay Goodstein * struct iwl_statistics_operational_ntfy 638853f4954SMordechay Goodstein * 639853f4954SMordechay Goodstein * @hdr: general statistics header 640853f4954SMordechay Goodstein * @flags: bitmap of possible notification structures 641b6e3d1baSAnjaneyulu * @per_mac: per mac statistics, &struct iwl_stats_ntfy_per_mac 642b6e3d1baSAnjaneyulu * @per_phy: per phy statistics, &struct iwl_stats_ntfy_per_phy 643b6e3d1baSAnjaneyulu * @per_sta: per sta statistics, &struct iwl_stats_ntfy_per_sta 6446324c173SMordechay Goodstein * @rx_time: rx time 6456324c173SMordechay Goodstein * @tx_time: usec the radio is transmitting. 6466324c173SMordechay Goodstein * @on_time_rf: The total time in usec the RF is awake. 6476324c173SMordechay Goodstein * @on_time_scan: usec the radio is awake due to scan. 6486324c173SMordechay Goodstein */ 6496324c173SMordechay Goodstein struct iwl_statistics_operational_ntfy { 6506324c173SMordechay Goodstein struct iwl_statistics_ntfy_hdr hdr; 6516324c173SMordechay Goodstein __le32 flags; 652b6e3d1baSAnjaneyulu struct iwl_stats_ntfy_per_mac per_mac[MAC_INDEX_AUX]; 653b6e3d1baSAnjaneyulu struct iwl_stats_ntfy_per_phy per_phy[IWL_STATS_MAX_PHY_OPERATIONAL]; 654*b61ed2b8SMiri Korenblit struct iwl_stats_ntfy_per_sta per_sta[IWL_STATION_COUNT_MAX]; 6556324c173SMordechay Goodstein __le64 rx_time; 6566324c173SMordechay Goodstein __le64 tx_time; 6576324c173SMordechay Goodstein __le64 on_time_rf; 6586324c173SMordechay Goodstein __le64 on_time_scan; 6596324c173SMordechay Goodstein } __packed; /* STATISTICS_OPERATIONAL_NTFY_API_S_VER_15 */ 6606324c173SMordechay Goodstein 6616324c173SMordechay Goodstein /** 6626324c173SMordechay Goodstein * struct iwl_statistics_operational_ntfy_ver_14 6636324c173SMordechay Goodstein * 6646324c173SMordechay Goodstein * @hdr: general statistics header 6656324c173SMordechay Goodstein * @flags: bitmap of possible notification structures 666853f4954SMordechay Goodstein * @mac_id: mac on which the beacon was received 667853f4954SMordechay Goodstein * @beacon_filter_average_energy: Average energy [-dBm] of the 2 668853f4954SMordechay Goodstein * antennas. 669853f4954SMordechay Goodstein * @beacon_filter_reason: beacon filter reason 670853f4954SMordechay Goodstein * @radio_temperature: radio temperature 671853f4954SMordechay Goodstein * @air_time: air time 672853f4954SMordechay Goodstein * @beacon_counter: all beacons (both filtered and not filtered) 673853f4954SMordechay Goodstein * @beacon_average_energy: all beacons (both filtered and not 674853f4954SMordechay Goodstein * filtered) 675853f4954SMordechay Goodstein * @beacon_rssi_a: beacon RSSI on antenna A 676853f4954SMordechay Goodstein * @beacon_rssi_b: beacon RSSI on antenna B 677853f4954SMordechay Goodstein * @rx_bytes: per MAC RX byte count 678853f4954SMordechay Goodstein * @rx_time: rx time 679853f4954SMordechay Goodstein * @tx_time: usec the radio is transmitting. 680853f4954SMordechay Goodstein * @on_time_rf: The total time in usec the RF is awake. 681853f4954SMordechay Goodstein * @on_time_scan: usec the radio is awake due to scan. 682853f4954SMordechay Goodstein * @average_energy: in fact it is minus the energy.. 683853f4954SMordechay Goodstein * @reserved: reserved 684853f4954SMordechay Goodstein */ 6856324c173SMordechay Goodstein struct iwl_statistics_operational_ntfy_ver_14 { 686853f4954SMordechay Goodstein struct iwl_statistics_ntfy_hdr hdr; 687853f4954SMordechay Goodstein __le32 flags; 688853f4954SMordechay Goodstein __le32 mac_id; 689853f4954SMordechay Goodstein __le32 beacon_filter_average_energy; 690853f4954SMordechay Goodstein __le32 beacon_filter_reason; 691853f4954SMordechay Goodstein __le32 radio_temperature; 692853f4954SMordechay Goodstein __le32 air_time[MAC_INDEX_AUX]; 693853f4954SMordechay Goodstein __le32 beacon_counter[MAC_INDEX_AUX]; 694853f4954SMordechay Goodstein __le32 beacon_average_energy[MAC_INDEX_AUX]; 695853f4954SMordechay Goodstein __le32 beacon_rssi_a; 696853f4954SMordechay Goodstein __le32 beacon_rssi_b; 697853f4954SMordechay Goodstein __le32 rx_bytes[MAC_INDEX_AUX]; 698853f4954SMordechay Goodstein __le64 rx_time; 699853f4954SMordechay Goodstein __le64 tx_time; 700853f4954SMordechay Goodstein __le64 on_time_rf; 701853f4954SMordechay Goodstein __le64 on_time_scan; 702*b61ed2b8SMiri Korenblit __le32 average_energy[IWL_STATION_COUNT_MAX]; 703853f4954SMordechay Goodstein __le32 reserved; 704853f4954SMordechay Goodstein } __packed; /* STATISTICS_OPERATIONAL_NTFY_API_S_VER_14 */ 705853f4954SMordechay Goodstein 706853f4954SMordechay Goodstein /** 707853f4954SMordechay Goodstein * struct iwl_statistics_phy_ntfy 708853f4954SMordechay Goodstein * 709853f4954SMordechay Goodstein * @hdr: general statistics header 710853f4954SMordechay Goodstein * RX PHY related statistics 711853f4954SMordechay Goodstein * @energy_and_config: ??? 712853f4954SMordechay Goodstein * @rssi_band: @31:24 rssiAllBand_B, 23:16 rssiInBand_B, 15:8 713853f4954SMordechay Goodstein * rssiAllBand_A, 7:0 rssiInBand_A 714853f4954SMordechay Goodstein * @agc_word: @31:16 agcWord_B, 15:0 agcWord_A 715853f4954SMordechay Goodstein * @agc_gain: @19:10 agcGain_B, 9:0 agcGain_A 716853f4954SMordechay Goodstein * @dfe_gain: @19:10 dfeGain_B, 9:0 dfeGain_A 717853f4954SMordechay Goodstein * @snr_calc_main: @18:0 snrCalcMain 718853f4954SMordechay Goodstein * @energy_calc_main: @18:0 energyCalcMain 719853f4954SMordechay Goodstein * @snr_calc_aux: @18:0 snrCalcAux 720853f4954SMordechay Goodstein * @dsp_dc_estim_a: @27:14 dspDcEstimQA, 13:0 dspDcEstimIA 721853f4954SMordechay Goodstein * @dsp_dc_estim_b: @27:14 dspDcEstimQB, 13:0 dspDcEstimIB 722853f4954SMordechay Goodstein * @ina_detec_type_and_ofdm_corr_comb: @31:31 inaDetectCckMrc, 723853f4954SMordechay Goodstein * 30:27 inaDetectType, 26:0 ofdmCorrComb 724853f4954SMordechay Goodstein * @cw_corr_comb: @26:0 cwCorrComb 725853f4954SMordechay Goodstein * @rssi_comb: @25:0 rssiComb 726853f4954SMordechay Goodstein * @auto_corr_cck: @23:12 autoCck, 11:00 crossCck 727853f4954SMordechay Goodstein * @ofdm_fine_freq_and_pina_freq_err: @18:7 ofdmFineFreq, 6:0 728853f4954SMordechay Goodstein * ofdmPinaFreqErr 729853f4954SMordechay Goodstein * @snrm_evm_main: @31:0 snrmEvmMain 730853f4954SMordechay Goodstein * @snrm_evm_aux: @31:0 snrmEvmAux 731853f4954SMordechay Goodstein * @rx_rate: @31:0 rate 732853f4954SMordechay Goodstein * TX PHY related statistics 733853f4954SMordechay Goodstein * @per_chain_enums_and_dsp_atten_a: @perChainEnumsAndDspAtten 734853f4954SMordechay Goodstein * (per version) 735853f4954SMordechay Goodstein * @target_power_and_power_meas_a: @31:16 targetPower_A, 15:0 736853f4954SMordechay Goodstein * powerMeasuredCalc_A 737853f4954SMordechay Goodstein * @tx_config_as_i_and_ac_a: @31:16 txConfigAsI_A, 15:0 738853f4954SMordechay Goodstein * txConfigAc_A 739853f4954SMordechay Goodstein * @predist_dcq_and_dci_a: @31:16 predist_dci_A, 15:0 740853f4954SMordechay Goodstein * predist_dcq_A 741853f4954SMordechay Goodstein * @per_chain_enums_and_dsp_atten_b: @perChainEnumsAndDspAtten 742853f4954SMordechay Goodstein * (per version) 743853f4954SMordechay Goodstein * @target_power_and_power_meas_b: @31:16 targetPower_B, 15:0 744853f4954SMordechay Goodstein * powerMeasuredCalc_B 745853f4954SMordechay Goodstein * @tx_config_as_i_and_ac_b: @31:16 txConfigAsI_B, 15:0 746853f4954SMordechay Goodstein * txConfigAc_B 747853f4954SMordechay Goodstein * @predist_dcq_and_dci_b: @31:16 predist_dci_B, 15:0 748853f4954SMordechay Goodstein * predist_dcq_B 749853f4954SMordechay Goodstein * @tx_rate: @31:0 rate 750853f4954SMordechay Goodstein * @tlc_backoff: @31:0 tlcBackoff 751853f4954SMordechay Goodstein * @mpapd_calib_mode_mpapd_calib_type_a: @31:16 752853f4954SMordechay Goodstein * mpapdCalibMode_A, 15:0 mpapdCalibType_A 753853f4954SMordechay Goodstein * @psat_and_phy_power_limit_a: @31:16 psat_A, 15:0 754853f4954SMordechay Goodstein * phyPowerLimit_A 755853f4954SMordechay Goodstein * @sar_and_regulatory_power_limit_a: @31:16 sarPowerLimit_A, 756853f4954SMordechay Goodstein * 15:0 regulatoryPowerLimit_A 757853f4954SMordechay Goodstein * @mpapd_calib_mode_mpapd_calib_type_b: @31:16 758853f4954SMordechay Goodstein * mpapdCalibMode_B, 15:0 mpapdCalibType_B 759853f4954SMordechay Goodstein * @psat_and_phy_power_limit_b: @31:16 psat_B, 15:0 760853f4954SMordechay Goodstein * phyPowerLimit_B 761853f4954SMordechay Goodstein * @sar_and_regulatory_power_limit_b: @31:16 sarPowerLimit_B, 762853f4954SMordechay Goodstein * 15:0 regulatoryPowerLimit_B 763853f4954SMordechay Goodstein * @srd_and_driver_power_limits: @31:16 srdPowerLimit, 15:0 764853f4954SMordechay Goodstein * driverPowerLimit 765853f4954SMordechay Goodstein * @reserved: reserved 766853f4954SMordechay Goodstein */ 767853f4954SMordechay Goodstein struct iwl_statistics_phy_ntfy { 768853f4954SMordechay Goodstein struct iwl_statistics_ntfy_hdr hdr; 769853f4954SMordechay Goodstein __le32 energy_and_config; 770853f4954SMordechay Goodstein __le32 rssi_band; 771853f4954SMordechay Goodstein __le32 agc_word; 772853f4954SMordechay Goodstein __le32 agc_gain; 773853f4954SMordechay Goodstein __le32 dfe_gain; 774853f4954SMordechay Goodstein __le32 snr_calc_main; 775853f4954SMordechay Goodstein __le32 energy_calc_main; 776853f4954SMordechay Goodstein __le32 snr_calc_aux; 777853f4954SMordechay Goodstein __le32 dsp_dc_estim_a; 778853f4954SMordechay Goodstein __le32 dsp_dc_estim_b; 779853f4954SMordechay Goodstein __le32 ina_detec_type_and_ofdm_corr_comb; 780853f4954SMordechay Goodstein __le32 cw_corr_comb; 781853f4954SMordechay Goodstein __le32 rssi_comb; 782853f4954SMordechay Goodstein __le32 auto_corr_cck; 783853f4954SMordechay Goodstein __le32 ofdm_fine_freq_and_pina_freq_err; 784853f4954SMordechay Goodstein __le32 snrm_evm_main; 785853f4954SMordechay Goodstein __le32 snrm_evm_aux; 786853f4954SMordechay Goodstein __le32 rx_rate; 787853f4954SMordechay Goodstein __le32 per_chain_enums_and_dsp_atten_a; 788853f4954SMordechay Goodstein __le32 target_power_and_power_meas_a; 789853f4954SMordechay Goodstein __le32 tx_config_as_i_and_ac_a; 790853f4954SMordechay Goodstein __le32 predist_dcq_and_dci_a; 791853f4954SMordechay Goodstein __le32 per_chain_enums_and_dsp_atten_b; 792853f4954SMordechay Goodstein __le32 target_power_and_power_meas_b; 793853f4954SMordechay Goodstein __le32 tx_config_as_i_and_ac_b; 794853f4954SMordechay Goodstein __le32 predist_dcq_and_dci_b; 795853f4954SMordechay Goodstein __le32 tx_rate; 796853f4954SMordechay Goodstein __le32 tlc_backoff; 797853f4954SMordechay Goodstein __le32 mpapd_calib_mode_mpapd_calib_type_a; 798853f4954SMordechay Goodstein __le32 psat_and_phy_power_limit_a; 799853f4954SMordechay Goodstein __le32 sar_and_regulatory_power_limit_a; 800853f4954SMordechay Goodstein __le32 mpapd_calib_mode_mpapd_calib_type_b; 801853f4954SMordechay Goodstein __le32 psat_and_phy_power_limit_b; 802853f4954SMordechay Goodstein __le32 sar_and_regulatory_power_limit_b; 803853f4954SMordechay Goodstein __le32 srd_and_driver_power_limits; 804853f4954SMordechay Goodstein __le32 reserved; 805853f4954SMordechay Goodstein } __packed; /* STATISTICS_PHY_NTFY_API_S_VER_1 */ 806853f4954SMordechay Goodstein 807853f4954SMordechay Goodstein /** 808853f4954SMordechay Goodstein * struct iwl_statistics_mac_ntfy 809853f4954SMordechay Goodstein * 810853f4954SMordechay Goodstein * @hdr: general statistics header 811853f4954SMordechay Goodstein * @bcast_filter_passed_per_mac: bcast filter passed per mac 812853f4954SMordechay Goodstein * @bcast_filter_dropped_per_mac: bcast filter dropped per mac 813853f4954SMordechay Goodstein * @bcast_filter_passed_per_filter: bcast filter passed per filter 814853f4954SMordechay Goodstein * @bcast_filter_dropped_per_filter: bcast filter dropped per filter 815853f4954SMordechay Goodstein * @reserved: reserved 816853f4954SMordechay Goodstein */ 817853f4954SMordechay Goodstein struct iwl_statistics_mac_ntfy { 818853f4954SMordechay Goodstein struct iwl_statistics_ntfy_hdr hdr; 819853f4954SMordechay Goodstein __le32 bcast_filter_passed_per_mac[NUM_MAC_INDEX_CDB]; 820853f4954SMordechay Goodstein __le32 bcast_filter_dropped_per_mac[NUM_MAC_INDEX_CDB]; 821853f4954SMordechay Goodstein __le32 bcast_filter_passed_per_filter[MAX_BCAST_FILTER_NUM]; 822853f4954SMordechay Goodstein __le32 bcast_filter_dropped_per_filter[MAX_BCAST_FILTER_NUM]; 823853f4954SMordechay Goodstein __le32 reserved; 824853f4954SMordechay Goodstein } __packed; /* STATISTICS_MAC_NTFY_API_S_VER_1 */ 825853f4954SMordechay Goodstein 826853f4954SMordechay Goodstein /** 827853f4954SMordechay Goodstein * struct iwl_statistics_rx_ntfy 828853f4954SMordechay Goodstein * 829853f4954SMordechay Goodstein * @hdr: general statistics header 830853f4954SMordechay Goodstein * @rx_agg_mpdu_cnt: aggregation frame count (number of 831853f4954SMordechay Goodstein * delimiters) 832853f4954SMordechay Goodstein * @rx_agg_cnt: number of RX Aggregations 833853f4954SMordechay Goodstein * @unsupported_mcs: number of PLCP headers that have rate which 834853f4954SMordechay Goodstein * is unsupported by DSP 835853f4954SMordechay Goodstein * @bogus_cts: CTS received when not expecting CTS 836853f4954SMordechay Goodstein * @bogus_ack: ACK received when not expecting ACK 837853f4954SMordechay Goodstein * @rx_byte_count: ??? 838853f4954SMordechay Goodstein * @rx_packet_count: ??? 839853f4954SMordechay Goodstein * @missed_beacons: ??? 840853f4954SMordechay Goodstein * @unresponded_rts: un-responded RTS, due to NAV not zero 841853f4954SMordechay Goodstein * @rxe_frame_limit_overrun: RXE got frame limit overrun 842853f4954SMordechay Goodstein * @sent_ba_rsp_cnt: BA response TX count 843853f4954SMordechay Goodstein * @late_rx_handle: count the number of times the RX path was 844853f4954SMordechay Goodstein * aborted due to late entry 845853f4954SMordechay Goodstein * @num_bt_kills: ??? 846853f4954SMordechay Goodstein * @reserved: reserved 847853f4954SMordechay Goodstein */ 848853f4954SMordechay Goodstein struct iwl_statistics_rx_ntfy { 849853f4954SMordechay Goodstein struct iwl_statistics_ntfy_hdr hdr; 850853f4954SMordechay Goodstein __le32 rx_agg_mpdu_cnt; 851853f4954SMordechay Goodstein __le32 rx_agg_cnt; 852853f4954SMordechay Goodstein __le32 unsupported_mcs; 853853f4954SMordechay Goodstein __le32 bogus_cts; 854853f4954SMordechay Goodstein __le32 bogus_ack; 855853f4954SMordechay Goodstein __le32 rx_byte_count[MAC_INDEX_AUX]; 856853f4954SMordechay Goodstein __le32 rx_packet_count[MAC_INDEX_AUX]; 857853f4954SMordechay Goodstein __le32 missed_beacons; 858853f4954SMordechay Goodstein __le32 unresponded_rts; 859853f4954SMordechay Goodstein __le32 rxe_frame_limit_overrun; 860853f4954SMordechay Goodstein __le32 sent_ba_rsp_cnt; 861853f4954SMordechay Goodstein __le32 late_rx_handle; 862853f4954SMordechay Goodstein __le32 num_bt_kills; 863853f4954SMordechay Goodstein __le32 reserved; 864853f4954SMordechay Goodstein } __packed; /* STATISTICS_RX_NTFY_API_S_VER_1 */ 865853f4954SMordechay Goodstein 866853f4954SMordechay Goodstein /** 867853f4954SMordechay Goodstein * struct iwl_statistics_tx_ntfy 868853f4954SMordechay Goodstein * 869853f4954SMordechay Goodstein * @hdr: general statistics header 870853f4954SMordechay Goodstein * @cts_timeout: timeout when waiting for CTS 871853f4954SMordechay Goodstein * @ack_timeout: timeout when waiting for ACK 872853f4954SMordechay Goodstein * @dump_msdu_cnt: number of MSDUs that were dumped due to any 873853f4954SMordechay Goodstein * reason 874853f4954SMordechay Goodstein * @burst_abort_missing_next_frame_cnt: number of times a burst 875853f4954SMordechay Goodstein * was aborted due to missing next frame bytes in txfifo 876853f4954SMordechay Goodstein * number of times got timeout when waiting for CTS/ACK/BA and energy was 877853f4954SMordechay Goodstein * detected just after sending the RTS/DATA. this statistics may help getting 878853f4954SMordechay Goodstein * interesting indicators, like the likelihood of collision (so the benefit of 879853f4954SMordechay Goodstein * protection may be estimated Vs. its cost). Or how many of the failures are 880853f4954SMordechay Goodstein * due to collision and how many due to SNR. 881853f4954SMordechay Goodstein * For Link-quality the CTS collision indication is more reliable then the ACK 882853f4954SMordechay Goodstein * collision indication as the RTS frame is short and has more chance that the 883853f4954SMordechay Goodstein * frame/s which caused the collision continue after the RTS was sent. 884853f4954SMordechay Goodstein * @cts_timeout_collision: ??? 885853f4954SMordechay Goodstein * ACK/BA failed and energy as detected after DATA 886853f4954SMordechay Goodstein * Note: to get the collision ratio need to: 887853f4954SMordechay Goodstein * ackOrBaTimeoutCollision / (ack_timeout + ba_timeout) 888853f4954SMordechay Goodstein * @ack_or_ba_timeout_collision: ??? 889853f4954SMordechay Goodstein * @ba_timeout: timeout when waiting for immediate BA response 890853f4954SMordechay Goodstein * @ba_reschedule_frames: failed to get BA response and 891853f4954SMordechay Goodstein * rescheduled all the non-ACKed frames 892853f4954SMordechay Goodstein * gives the avarage number of frames inside aggregation 893853f4954SMordechay Goodstein * @scd_query_agg_frame_cnt: ??? 894853f4954SMordechay Goodstein * @scd_query_no_agg: scheduler query prevented aggregation 895853f4954SMordechay Goodstein * @scd_query_agg: scheduler query allowed aggregation 896853f4954SMordechay Goodstein * @scd_query_mismatch: scheduler query inaccurate, either too 897853f4954SMordechay Goodstein * short or too long 898853f4954SMordechay Goodstein * @agg_terminated_underrun: aggregation was terminated due to 899853f4954SMordechay Goodstein * underrun 900853f4954SMordechay Goodstein * @agg_terminated_bt_prio_kill: aggregation was terminated due 901853f4954SMordechay Goodstein * to BT 902853f4954SMordechay Goodstein * @tx_kill_on_long_retry: count the tx frames dropped due to 903853f4954SMordechay Goodstein * long retry limit (DATA frame failed) 904853f4954SMordechay Goodstein * @tx_kill_on_short_retry: count the tx frames dropped due to 905853f4954SMordechay Goodstein * short retry limit (RTS frame failed) 906853f4954SMordechay Goodstein * TX deffer on energy. This counter is reset on each successful transmit. 907853f4954SMordechay Goodstein * When timer exceed TX deffer limit than will be uCode assert. 908853f4954SMordechay Goodstein * @tx_deffer_counter: ??? 909853f4954SMordechay Goodstein * @tx_deffer_base_time: Keep the time of the last successful 910853f4954SMordechay Goodstein * transmit 911853f4954SMordechay Goodstein * @tx_underrun: TX killed due to underrun 912853f4954SMordechay Goodstein * @bt_defer: TX deferred due to BT priority, so probably TX was 913853f4954SMordechay Goodstein * not started. 914853f4954SMordechay Goodstein * @tx_kill_on_dsp_timeout: TX killed on DSP problem detected 915853f4954SMordechay Goodstein * @tx_kill_on_immediate_quiet: TX killed due to immediate quiet 916853f4954SMordechay Goodstein * @kill_ba_cnt: number of times sending BA failed 917853f4954SMordechay Goodstein * @kill_ack_cnt: number of times sending ACK failed 918853f4954SMordechay Goodstein * @kill_cts_cnt: number of times sending CTS failed 919853f4954SMordechay Goodstein * @burst_terminated: Count burst or fragmentation termination 920853f4954SMordechay Goodstein * occurrence 921853f4954SMordechay Goodstein * @late_tx_vec_wr_cnt: ??? 922853f4954SMordechay Goodstein * TX is not sent because ucode failed to notify the TRM in SIFS-delta from 923853f4954SMordechay Goodstein * ON_AIR deassertion. 924853f4954SMordechay Goodstein * @late_rx2_tx_cnt: ??? 925853f4954SMordechay Goodstein * @scd_query_cnt: count the times SCD query was done to check 926853f4954SMordechay Goodstein * for TX AGG 927853f4954SMordechay Goodstein * @tx_frames_acked_in_agg: count the number of frames 928853f4954SMordechay Goodstein * transmitted inside AGG and were successful 929853f4954SMordechay Goodstein * @last_tx_ch_width_indx: ??? 930853f4954SMordechay Goodstein * number of deferred TX per channel width, 0 - 20, 1/2/3 - 40/80/160 931853f4954SMordechay Goodstein * @rx_detected_per_ch_width: ??? 932853f4954SMordechay Goodstein * @success_per_ch_width: ??? 933853f4954SMordechay Goodstein * @fail_per_ch_width: ??? 934853f4954SMordechay Goodstein * @reserved: reserved 935853f4954SMordechay Goodstein */ 936853f4954SMordechay Goodstein struct iwl_statistics_tx_ntfy { 937853f4954SMordechay Goodstein struct iwl_statistics_ntfy_hdr hdr; 938853f4954SMordechay Goodstein __le32 cts_timeout; 939853f4954SMordechay Goodstein __le32 ack_timeout; 940853f4954SMordechay Goodstein __le32 dump_msdu_cnt; 941853f4954SMordechay Goodstein __le32 burst_abort_missing_next_frame_cnt; 942853f4954SMordechay Goodstein __le32 cts_timeout_collision; 943853f4954SMordechay Goodstein __le32 ack_or_ba_timeout_collision; 944853f4954SMordechay Goodstein __le32 ba_timeout; 945853f4954SMordechay Goodstein __le32 ba_reschedule_frames; 946853f4954SMordechay Goodstein __le32 scd_query_agg_frame_cnt; 947853f4954SMordechay Goodstein __le32 scd_query_no_agg; 948853f4954SMordechay Goodstein __le32 scd_query_agg; 949853f4954SMordechay Goodstein __le32 scd_query_mismatch; 950853f4954SMordechay Goodstein __le32 agg_terminated_underrun; 951853f4954SMordechay Goodstein __le32 agg_terminated_bt_prio_kill; 952853f4954SMordechay Goodstein __le32 tx_kill_on_long_retry; 953853f4954SMordechay Goodstein __le32 tx_kill_on_short_retry; 954853f4954SMordechay Goodstein __le32 tx_deffer_counter; 955853f4954SMordechay Goodstein __le32 tx_deffer_base_time; 956853f4954SMordechay Goodstein __le32 tx_underrun; 957853f4954SMordechay Goodstein __le32 bt_defer; 958853f4954SMordechay Goodstein __le32 tx_kill_on_dsp_timeout; 959853f4954SMordechay Goodstein __le32 tx_kill_on_immediate_quiet; 960853f4954SMordechay Goodstein __le32 kill_ba_cnt; 961853f4954SMordechay Goodstein __le32 kill_ack_cnt; 962853f4954SMordechay Goodstein __le32 kill_cts_cnt; 963853f4954SMordechay Goodstein __le32 burst_terminated; 964853f4954SMordechay Goodstein __le32 late_tx_vec_wr_cnt; 965853f4954SMordechay Goodstein __le32 late_rx2_tx_cnt; 966853f4954SMordechay Goodstein __le32 scd_query_cnt; 967853f4954SMordechay Goodstein __le32 tx_frames_acked_in_agg; 968853f4954SMordechay Goodstein __le32 last_tx_ch_width_indx; 969853f4954SMordechay Goodstein __le32 rx_detected_per_ch_width[4]; 970853f4954SMordechay Goodstein __le32 success_per_ch_width[4]; 971853f4954SMordechay Goodstein __le32 fail_per_ch_width[4]; 972853f4954SMordechay Goodstein __le32 reserved; 973853f4954SMordechay Goodstein } __packed; /* STATISTICS_TX_NTFY_API_S_VER_1 */ 974853f4954SMordechay Goodstein 975853f4954SMordechay Goodstein /** 976853f4954SMordechay Goodstein * struct iwl_statistics_duration_ntfy 977853f4954SMordechay Goodstein * 978853f4954SMordechay Goodstein * @hdr: general statistics header 979853f4954SMordechay Goodstein * @cont_burst_chk_cnt: number of times continuation or 980853f4954SMordechay Goodstein * fragmentation or bursting was checked 981853f4954SMordechay Goodstein * @cont_burst_cnt: number of times continuation or fragmentation 982853f4954SMordechay Goodstein * or bursting was successful 983853f4954SMordechay Goodstein * @wait_for_silence_timeout_cnt: ??? 984853f4954SMordechay Goodstein * @reserved: reserved 985853f4954SMordechay Goodstein */ 986853f4954SMordechay Goodstein struct iwl_statistics_duration_ntfy { 987853f4954SMordechay Goodstein struct iwl_statistics_ntfy_hdr hdr; 988853f4954SMordechay Goodstein __le32 cont_burst_chk_cnt; 989853f4954SMordechay Goodstein __le32 cont_burst_cnt; 990853f4954SMordechay Goodstein __le32 wait_for_silence_timeout_cnt; 991853f4954SMordechay Goodstein __le32 reserved; 992853f4954SMordechay Goodstein } __packed; /* STATISTICS_DURATION_NTFY_API_S_VER_1 */ 993853f4954SMordechay Goodstein 994853f4954SMordechay Goodstein /** 995853f4954SMordechay Goodstein * struct iwl_statistics_he_ntfy 996853f4954SMordechay Goodstein * 997853f4954SMordechay Goodstein * @hdr: general statistics header 998853f4954SMordechay Goodstein * received HE frames 999853f4954SMordechay Goodstein * @rx_siga_valid_cnt: rx HE SIG-A valid 1000853f4954SMordechay Goodstein * @rx_siga_invalid_cnt: rx HE SIG-A invalid 1001853f4954SMordechay Goodstein * received HE frames w/ valid Sig-A 1002853f4954SMordechay Goodstein * @rx_trig_based_frame_cnt: rx HE-TB (trig-based) 1003853f4954SMordechay Goodstein * @rx_su_frame_cnt: rx HE-SU 1004853f4954SMordechay Goodstein * @rx_sigb_invalid_cnt: rx (suspected) HE-MU w/ bad SIG-B 1005853f4954SMordechay Goodstein * @rx_our_bss_color_cnt: rx valid HE SIG-A w/ our BSS color 1006853f4954SMordechay Goodstein * @rx_other_bss_color_cnt: rx valid HE SIG-A w/ other BSS color 1007853f4954SMordechay Goodstein * @rx_zero_bss_color_cnt: ??? 1008853f4954SMordechay Goodstein * received HE-MU frames w/ good Sig-B 1009853f4954SMordechay Goodstein * @rx_mu_for_us_cnt: match AID 1010853f4954SMordechay Goodstein * @rx_mu_not_for_us_cnt: no matched AID 1011853f4954SMordechay Goodstein * received HE-MU frames for us (w/ our AID) 1012853f4954SMordechay Goodstein * @rx_mu_nss_ar: 0 - SISO, 1 - MIMO2 1013853f4954SMordechay Goodstein * @rx_mu_mimo_cnt: full BW RU, compressed SIG-B 1014853f4954SMordechay Goodstein * @rx_mu_ru_bw_ar: MU alloc, MHz: 0 - 2, 1 - 5, 2 - 10, 3 - 20, 1015853f4954SMordechay Goodstein * 4 - 40, 5 - 80, 6 - 160 1016853f4954SMordechay Goodstein * received trigger frames 1017853f4954SMordechay Goodstein * @rx_trig_for_us_cnt: ??? 1018853f4954SMordechay Goodstein * @rx_trig_not_for_us_cnt: ??? 1019853f4954SMordechay Goodstein * trigger for us 1020853f4954SMordechay Goodstein * @rx_trig_with_cs_req_cnt: ??? 1021853f4954SMordechay Goodstein * @rx_trig_type_ar: ??? 1022853f4954SMordechay Goodstein * @rx_trig_in_agg_cnt: ??? 1023853f4954SMordechay Goodstein * basic trigger for us allocations 1024853f4954SMordechay Goodstein * @rx_basic_trig_alloc_nss_ar: ??? 1025853f4954SMordechay Goodstein * @rx_basic_trig_alloc_mu_mimo_cnt: ??? 1026853f4954SMordechay Goodstein * @rx_basic_trig_alloc_ru_bw_ar: ??? 1027853f4954SMordechay Goodstein * @rx_basic_trig_total_byte_cnt: ??? 1028853f4954SMordechay Goodstein * trig-based TX 1029853f4954SMordechay Goodstein * @tx_trig_based_cs_req_fail_cnt: ??? 1030853f4954SMordechay Goodstein * @tx_trig_based_sifs_ok_cnt: ??? 1031853f4954SMordechay Goodstein * @tx_trig_based_sifs_fail_cnt: ??? 1032853f4954SMordechay Goodstein * @tx_trig_based_byte_cnt: ??? 1033853f4954SMordechay Goodstein * @tx_trig_based_pad_byte_cnt: ??? 1034853f4954SMordechay Goodstein * @tx_trig_based_frame_cnt: ??? 1035853f4954SMordechay Goodstein * @tx_trig_based_acked_frame_cnt: ??? 1036853f4954SMordechay Goodstein * @tx_trig_based_ack_timeout_cnt: ??? 1037853f4954SMordechay Goodstein * HE-SU TX 1038853f4954SMordechay Goodstein * @tx_su_frame_cnt: ??? 1039853f4954SMordechay Goodstein * EDCA <--> MU-EDCA transitions 1040853f4954SMordechay Goodstein * @tx_edca_to_mu_edca_cnt: ??? 1041853f4954SMordechay Goodstein * @tx_mu_edca_to_edca_by_timeout_cnt: ??? 1042853f4954SMordechay Goodstein * @tx_mu_edca_to_edca_by_ack_fail_cnt: ??? 1043853f4954SMordechay Goodstein * @tx_mu_edca_to_edca_by_small_alloc_cnt: ??? 1044853f4954SMordechay Goodstein * @reserved: reserved 1045853f4954SMordechay Goodstein */ 1046853f4954SMordechay Goodstein struct iwl_statistics_he_ntfy { 1047853f4954SMordechay Goodstein struct iwl_statistics_ntfy_hdr hdr; 1048853f4954SMordechay Goodstein __le32 rx_siga_valid_cnt; 1049853f4954SMordechay Goodstein __le32 rx_siga_invalid_cnt; 1050853f4954SMordechay Goodstein __le32 rx_trig_based_frame_cnt; 1051853f4954SMordechay Goodstein __le32 rx_su_frame_cnt; 1052853f4954SMordechay Goodstein __le32 rx_sigb_invalid_cnt; 1053853f4954SMordechay Goodstein __le32 rx_our_bss_color_cnt; 1054853f4954SMordechay Goodstein __le32 rx_other_bss_color_cnt; 1055853f4954SMordechay Goodstein __le32 rx_zero_bss_color_cnt; 1056853f4954SMordechay Goodstein __le32 rx_mu_for_us_cnt; 1057853f4954SMordechay Goodstein __le32 rx_mu_not_for_us_cnt; 1058853f4954SMordechay Goodstein __le32 rx_mu_nss_ar[2]; 1059853f4954SMordechay Goodstein __le32 rx_mu_mimo_cnt; 1060853f4954SMordechay Goodstein __le32 rx_mu_ru_bw_ar[7]; 1061853f4954SMordechay Goodstein __le32 rx_trig_for_us_cnt; 1062853f4954SMordechay Goodstein __le32 rx_trig_not_for_us_cnt; 1063853f4954SMordechay Goodstein __le32 rx_trig_with_cs_req_cnt; 1064853f4954SMordechay Goodstein __le32 rx_trig_type_ar[8 + 1]; 1065853f4954SMordechay Goodstein __le32 rx_trig_in_agg_cnt; 1066853f4954SMordechay Goodstein __le32 rx_basic_trig_alloc_nss_ar[2]; 1067853f4954SMordechay Goodstein __le32 rx_basic_trig_alloc_mu_mimo_cnt; 1068853f4954SMordechay Goodstein __le32 rx_basic_trig_alloc_ru_bw_ar[7]; 1069853f4954SMordechay Goodstein __le32 rx_basic_trig_total_byte_cnt; 1070853f4954SMordechay Goodstein __le32 tx_trig_based_cs_req_fail_cnt; 1071853f4954SMordechay Goodstein __le32 tx_trig_based_sifs_ok_cnt; 1072853f4954SMordechay Goodstein __le32 tx_trig_based_sifs_fail_cnt; 1073853f4954SMordechay Goodstein __le32 tx_trig_based_byte_cnt; 1074853f4954SMordechay Goodstein __le32 tx_trig_based_pad_byte_cnt; 1075853f4954SMordechay Goodstein __le32 tx_trig_based_frame_cnt; 1076853f4954SMordechay Goodstein __le32 tx_trig_based_acked_frame_cnt; 1077853f4954SMordechay Goodstein __le32 tx_trig_based_ack_timeout_cnt; 1078853f4954SMordechay Goodstein __le32 tx_su_frame_cnt; 1079853f4954SMordechay Goodstein __le32 tx_edca_to_mu_edca_cnt; 1080853f4954SMordechay Goodstein __le32 tx_mu_edca_to_edca_by_timeout_cnt; 1081853f4954SMordechay Goodstein __le32 tx_mu_edca_to_edca_by_ack_fail_cnt; 1082853f4954SMordechay Goodstein __le32 tx_mu_edca_to_edca_by_small_alloc_cnt; 1083853f4954SMordechay Goodstein __le32 reserved; 1084853f4954SMordechay Goodstein } __packed; /* STATISTICS_HE_NTFY_API_S_VER_1 */ 1085853f4954SMordechay Goodstein 1086d172a5efSJohannes Berg #endif /* __iwl_fw_api_stats_h__ */ 1087