From fa6fe3611018e142e9b7755f791d6ba37ffa67db Mon Sep 17 00:00:00 2001 From: spuligil Date: Thu, 11 Jan 2024 18:01:33 -0800 Subject: [PATCH] fw-api: CL 25779296 - update fw common interface files WMI: add more stats in ctrl_path_awgn_stats_struct Also, piggyback fixes for the sar_flags TLV tag in READY_EXT2_EVENT, and the Windows definition of the WMI_VAR_LEN_ARRAY1 macro. Change-Id: I5211f043eaafc234a06a2cc91b530904b9d0b3d1 CRs-Fixed: 2262693 --- fw/wmi_tlv_defs.h | 2 +- fw/wmi_unified.h | 80 +++++++++++++++++++++++++++++++++++++++-------- fw/wmi_version.h | 2 +- 3 files changed, 69 insertions(+), 15 deletions(-) diff --git a/fw/wmi_tlv_defs.h b/fw/wmi_tlv_defs.h index f45980d0c8a9..36e090500fef 100644 --- a/fw/wmi_tlv_defs.h +++ b/fw/wmi_tlv_defs.h @@ -5630,7 +5630,7 @@ WMITLV_CREATE_PARAM_STRUC(WMI_SERVICE_READY_EXT_EVENTID); WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_aux_dev_capabilities, aux_dev_caps, WMITLV_SIZE_VAR) \ WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_enhanced_aoa_caps_param, aoa_caps_param, WMITLV_SIZE_VAR) \ WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_enhanced_aoa_per_band_caps_param, aoa_per_band_caps_param, WMITLV_SIZE_VAR) \ - WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_STRUC_wmi_sar_flags, wmi_sar_flag_tlv_param, sar_flags, WMITLV_SIZE_VAR) + WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_sar_flag_tlv_param, sar_flags, WMITLV_SIZE_VAR) WMITLV_CREATE_PARAM_STRUC(WMI_SERVICE_READY_EXT2_EVENTID); #define WMITLV_TABLE_WMI_SPECTRAL_CAPABILITIES_EVENTID(id,op,buf,len) \ diff --git a/fw/wmi_unified.h b/fw/wmi_unified.h index 5e6a2d5b378f..92a04aff7fa6 100644 --- a/fw/wmi_unified.h +++ b/fw/wmi_unified.h @@ -102,14 +102,18 @@ extern "C" { #define WMI_DUMMY_ZERO_LEN_FIELD struct {} dummy_zero_len_field #endif -#define WMI_VAR_LEN_ARRAY1(type, name) \ - union { \ - type name ## __first_elem; \ - struct { \ - WMI_DUMMY_ZERO_LEN_FIELD; \ - type name[]; \ - }; \ - } +#if defined(__WINDOWS__) + #define WMI_VAR_LEN_ARRAY1(type, name) type name[1] +#else + #define WMI_VAR_LEN_ARRAY1(type, name) \ + union { \ + type name ## __first_elem; \ + struct { \ + WMI_DUMMY_ZERO_LEN_FIELD; \ + type name[]; \ + }; \ + } +#endif #define ATH_MAC_LEN 6 /**< length of MAC in bytes */ #define WMI_EVENT_STATUS_SUCCESS 0 /* Success return status to host */ @@ -13217,13 +13221,63 @@ typedef struct { A_UINT32 awgn_cca_ack_reset_cnt; /* * AWGN int BW cnt used to store interference occurred at 20/40/80/160MHz - * bw_cnt[0] counts interference detections in 20 MHz BW, - * bw_cnt[1] counts interference detections in 40 MHz BW, - * bw_cnt[2] counts interference detections in 80 MHz BW, - * bw_cnt[3] counts interference detections in 160 MHz BW, - * bw_cnt[4] and bw_cnt[6] are reserved for 240 MHz and 320 MHz. + * awgn_int_bw_cnt[0] counts interference detections in 20 MHz BW, + * awgn_int_bw_cnt[1] counts interference detections in 40 MHz BW, + * awgn_int_bw_cnt[2] counts interference detections in 80 MHz BW, + * awgn_int_bw_cnt[3] counts interference detections in 160 MHz BW, + * awgn_int_bw_cnt[4] is reserved for 240 MHz BW, + * awgn_int_bw_cnt[5] counts interference detections in 320 MHz BW. */ A_UINT32 awgn_int_bw_cnt[WMI_AWGN_MAX_BW]; + + /* Number of OBSS interference occurred */ + A_UINT32 obss_int_cnt; + + /* Number of OBSS interference Sent to host */ + A_UINT32 obss_int_evt_sent_host_cnt; + + /* Number of OBSS interference skiped due to AWGN as high priority */ + A_UINT32 obss_int_evt_skip_awgn_cnt; + + /* Number of OBSS interference skiped due to duplicate OBSS interference */ + A_UINT32 obss_int_evt_skip_dup_cnt; + + /* Current OBSS interference segment details + * chan_bw_interference_bitmap: + * Indicates which 20MHz segments contain interference + * 320 MHz: bits 0-15 + * 160 MHz: bits 0-7 + * 80 MHz: bits 0-3 + * Within the bitmap, Bit-0 represents lowest 20Mhz, Bit-1 represents + * second lowest 20Mhz and so on. + * Each bit position will indicate 20MHz in which interference is seen. + * (Valid 16 bits out of 32 bit integer) + */ + A_UINT32 obss_int_cur_int_seg; + + /* Previous OBSS Int Segment details + * chan_bw_interference_bitmap: + * Indicates which 20MHz segments contain interference + * 320 MHz: bits 0-15 + * 160 MHz: bits 0-7 + * 80 MHz: bits 0-3 + * Within the bitmap, Bit-0 represents lowest 20Mhz, Bit-1 represents + * second lowest 20Mhz and so on. + * Each bit position will indicate 20MHz in which interference is seen. + * (Valid 16 bits out of 32 bit integer) + */ + A_UINT32 obss_int_prv_int_seg; + + /* + * OBSS int BW cnt used to store interference occurred at 20/40/80/160MHz + * obss_int_bw_cnt[0] counts interference detections in 20 MHz BW, + * obss_int_bw_cnt[1] counts interference detections in 40 MHz BW, + * obss_int_bw_cnt[2] counts interference detections in 80 MHz BW, + * obss_int_bw_cnt[3] counts interference detections in 160 MHz BW, + * obss_int_bw_cnt[4] counts interference detections in 240 MHz BW, + * obss_int_bw_cnt[5] counts interference detections in 320 MHz BW, + */ + A_UINT32 obss_int_bw_cnt[WMI_AWGN_MAX_BW]; } wmi_ctrl_path_awgn_stats_struct; typedef struct { diff --git a/fw/wmi_version.h b/fw/wmi_version.h index 4715829a36ca..eef411cda958 100644 --- a/fw/wmi_version.h +++ b/fw/wmi_version.h @@ -37,7 +37,7 @@ #define __WMI_VER_MINOR_ 0 /** WMI revision number has to be incremented when there is a * change that may or may not break compatibility. */ -#define __WMI_REVISION_ 1441 +#define __WMI_REVISION_ 1442 /** The Version Namespace should not be normally changed. Only * host and firmware of the same WMI namespace will work