qcacmn: Add support for Extended BSS IE

Add implementation to enhance structure
corresponding to WMI_DCS_INTERFERENCE_EVENT_ID
handler in cp stats component which hold
secondary 40 and 80MHz utilization
which are required parameters of Extended BSS IE

Change-Id: I1c471608394d5c395632742098d2c92fc02ec238
CRs-Fixed: 2298073
This commit is contained in:
Naga
2018-04-04 11:54:25 +05:30
committed by nshrivas
parent ffcaef4344
commit e85b72a4ae
4 changed files with 25 additions and 90 deletions

View File

@@ -43,14 +43,14 @@
* @dcs_sec_80_util: secondary 80MHz util
*/
struct pdev_dcs_chan_stats {
uint32_t dcs_total_util;
uint32_t dcs_ap_tx_util;
uint32_t dcs_ap_rx_util;
uint32_t dcs_self_bss_util;
uint32_t dcs_obss_util;
uint32_t dcs_obss_rx_util;
uint32_t dcs_free_medium;
uint32_t dcs_non_wifi_util;
uint8_t dcs_total_util;
uint8_t dcs_ap_tx_util;
uint8_t dcs_ap_rx_util;
uint8_t dcs_self_bss_util;
uint8_t dcs_obss_util;
uint8_t dcs_obss_rx_util;
uint8_t dcs_free_medium;
uint8_t dcs_non_wifi_util;
uint32_t dcs_ss_under_util;
uint32_t dcs_sec_20_util;
uint32_t dcs_sec_40_util;

View File

@@ -137,60 +137,8 @@ UCFG_PDEV_CP_STATS_GET_FUNCS(wmi_tx_mgmt_completion_err);
UCFG_PDEV_CP_STATS_GET_FUNCS(tgt_asserts);
UCFG_PDEV_CP_STATS_GET_FUNCS(rx_phy_err);
#define UCFG_PDEV_CHAN_STATS_SET_FUNCS(field) \
static inline void \
ucfg_pdev_chan_stats_##field##_inc(struct wlan_objmgr_pdev *_pdev, \
uint64_t _val) \
{ \
struct pdev_cp_stats *_pdev_cs = \
wlan_cp_stats_get_pdev_stats_obj(_pdev); \
if (_pdev_cs) { \
struct pdev_ic_cp_stats *_pdev_ic = \
_pdev_cs->pdev_stats; \
if (_pdev_ic) { \
_pdev_ic->stats.chan_stats.dcs_##field += _val;\
} \
} \
} \
static inline void \
ucfg_pdev_chan_stats_##field##_dec(struct wlan_objmgr_pdev *_pdev, \
uint64_t _val) \
{ \
struct pdev_cp_stats *_pdev_cs = \
wlan_cp_stats_get_pdev_stats_obj(_pdev); \
if (_pdev_cs) { \
struct pdev_ic_cp_stats *_pdev_ic = \
_pdev_cs->pdev_stats; \
if (_pdev_ic) { \
_pdev_ic->stats.chan_stats.dcs_##field -= _val;\
} \
} \
} \
static inline void \
ucfg_pdev_chan_stats_##field##_update(struct wlan_objmgr_pdev *_pdev, \
uint64_t _val) \
{ \
struct pdev_cp_stats *_pdev_cs = \
wlan_cp_stats_get_pdev_stats_obj(_pdev); \
if (_pdev_cs) { \
struct pdev_ic_cp_stats *_pdev_ic = \
_pdev_cs->pdev_stats; \
if (_pdev_ic) { \
_pdev_ic->stats.chan_stats.dcs_##field = _val;\
} \
} \
}
UCFG_PDEV_CHAN_STATS_SET_FUNCS(self_bss_util);
UCFG_PDEV_CHAN_STATS_SET_FUNCS(obss_util);
UCFG_PDEV_CHAN_STATS_SET_FUNCS(obss_rx_util);
UCFG_PDEV_CHAN_STATS_SET_FUNCS(ap_rx_util);
UCFG_PDEV_CHAN_STATS_SET_FUNCS(ap_tx_util);
UCFG_PDEV_CHAN_STATS_SET_FUNCS(free_medium);
UCFG_PDEV_CHAN_STATS_SET_FUNCS(non_wifi_util);
#define UCFG_PDEV_CHAN_STATS_GET_FUNCS(field) \
static inline uint8_t \
static inline uint32_t \
ucfg_pdev_chan_stats_##field##_get(struct wlan_objmgr_pdev *_pdev) \
{ \
struct pdev_cp_stats *_pdev_cs = \
@@ -210,6 +158,10 @@ UCFG_PDEV_CHAN_STATS_GET_FUNCS(ap_rx_util);
UCFG_PDEV_CHAN_STATS_GET_FUNCS(ap_tx_util);
UCFG_PDEV_CHAN_STATS_GET_FUNCS(free_medium);
UCFG_PDEV_CHAN_STATS_GET_FUNCS(non_wifi_util);
UCFG_PDEV_CHAN_STATS_GET_FUNCS(ss_under_util);
UCFG_PDEV_CHAN_STATS_GET_FUNCS(sec_20_util);
UCFG_PDEV_CHAN_STATS_GET_FUNCS(sec_40_util);
UCFG_PDEV_CHAN_STATS_GET_FUNCS(sec_80_util);
static inline void ucfg_pdev_cp_stats_reset(struct wlan_objmgr_pdev *_pdev)
{

View File

@@ -326,36 +326,8 @@ PDEV_CP_STATS_SET_FUNCS(cycle_count);
PDEV_CP_STATS_SET_FUNCS(phy_err_count);
PDEV_CP_STATS_SET_FUNCS(chan_tx_pwr);
#define PDEV_CHAN_STATS_SET_FUNCS(field) \
static inline void \
pdev_chan_stats_##field##_inc(struct wlan_objmgr_pdev *_pdev, \
uint8_t _val) \
{ \
ucfg_pdev_chan_stats_##field##_inc(_pdev, _val); \
} \
static inline void \
pdev_chan_stats_##field##_dec(struct wlan_objmgr_pdev *_pdev, \
uint8_t _val) \
{ \
ucfg_pdev_chan_stats_##field##_dec(_pdev, _val); \
} \
static inline void \
pdev_chan_stats_##field##_update(struct wlan_objmgr_pdev *_pdev, \
uint8_t _val) \
{ \
ucfg_pdev_chan_stats_##field##_update(_pdev, _val); \
}
PDEV_CHAN_STATS_SET_FUNCS(self_bss_util);
PDEV_CHAN_STATS_SET_FUNCS(obss_util);
PDEV_CHAN_STATS_SET_FUNCS(obss_rx_util);
PDEV_CHAN_STATS_SET_FUNCS(ap_rx_util);
PDEV_CHAN_STATS_SET_FUNCS(ap_tx_util);
PDEV_CHAN_STATS_SET_FUNCS(free_medium);
PDEV_CHAN_STATS_SET_FUNCS(non_wifi_util);
#define PDEV_CHAN_STATS_GET_FUNCS(field) \
static inline uint8_t \
static inline uint32_t \
pdev_chan_stats_##field##_get(struct wlan_objmgr_pdev *_pdev) \
{ \
return ucfg_pdev_chan_stats_##field##_get(_pdev); \
@@ -368,6 +340,10 @@ PDEV_CHAN_STATS_GET_FUNCS(ap_rx_util);
PDEV_CHAN_STATS_GET_FUNCS(ap_tx_util);
PDEV_CHAN_STATS_GET_FUNCS(free_medium);
PDEV_CHAN_STATS_GET_FUNCS(non_wifi_util);
PDEV_CHAN_STATS_GET_FUNCS(ss_under_util);
PDEV_CHAN_STATS_GET_FUNCS(sec_20_util);
PDEV_CHAN_STATS_GET_FUNCS(sec_40_util);
PDEV_CHAN_STATS_GET_FUNCS(sec_80_util);
#define PDEV_CP_STATS_GET_FUNCS(field) \
static inline uint64_t \