qcacmn: Add implementation of vdev 80211 cp stats

Add change to define vdev 80211 cp stats
structure and provide APIs to set/get cp stats
fields to/from within cp stats component

Change-Id: Ic600d4f83e3818c5cc3ace6c29a74fb75e2bd97d
CRs-Fixed: 2236328
This commit is contained in:
Naga
2018-05-03 15:43:14 +05:30
committed by nshrivas
父節點 6a72f69904
當前提交 4d11171075
共有 3 個文件被更改,包括 369 次插入18 次删除

查看文件

@@ -59,10 +59,134 @@ struct pdev_ic_cp_stats {
* used as interface structure with user space application
* make sure to align this structure with ieee80211_mac_stats
*
* @cs_rx_mgmt: rx mgmt
* @cs_tx_bcn_swba: tx beacon
* @cs_tx_offchan_mgmt: tx offchan mgmt
* @cs_tx_offchan_data: tx offchan data
* @cs_tx_offchan_fail: tx offchan fail
* @cs_rx_wrongbss: rx from wrong bssid
* @cs_rx_wrongdir: rx wrong direction
* @cs_rx_not_assoc: rx discard cuz sta !assoc
* @cs_rx_no_privacy: rx wep but privacy off
* @cs_rx_mgt_discard: rx mgmt frames discard
* @cs_rx_ctl: rx control frames discard
* @cs_rx_rs_too_big: rx rate set truncated
* @cs_rx_elem_missing: rx required element missing
* @cs_rx_elem_too_big: rx elem too big
* @cs_rx_chan_err: rx chan err
* @cs_rx_node_alloc: rx frame dropped
* @cs_rx_ssid_mismatch: rx ssid mismatch
* @cs_rx_auth_unsupported: rx auth unsupported algo
* @cs_rx_auth_fail: rx auth fail
* @cs_rx_auth_countermeasures: rx auth discard cuz counter measures
* @cs_rx_assoc_bss: rx assoc from wrong bss
* @cs_rx_assoc_notauth: rx assoc w/o auth
* @cs_rx_assoc_cap_mismatch: rx assoc w/ cap mismatch
* @cs_rx_assoc_norate: rx assoc w/ no rate match
* @cs_rx_assoc_wpaie_err: rx assoc w/ WPA err
* @cs_rx_action: rx action frames
* @cs_rx_auth_err: rx auth errors
* @cs_tx_nodefkey: tx nodefkey cuz no defkey
* @cs_tx_noheadroom: tx failed no headroom space
* @cs_rx_nocipherctx: rx no cipher context key
* @cs_rx_acl: rx acl
* @cs_rx_nowds: rx 4-addr packets with no wds enabled
* @cs_tx_nonode: tx tx failed for lack of buf
* @cs_tx_unknown_mgt: tx unkonwn mgmt
* @cs_tx_cipher_err: tx cipher error
* @cs_node_timeout: node timeout
* @cs_crypto_nomem: no memory for crypto ctx
* @cs_crypto_tkip: tkip crypto done in s/w
* @cs_crypto_tkipenmic: tkip en-MIC done in s/w
* @cs_crypto_tkipcm: crypto tkip counter measures
* @cs_crypto_ccmp: crypto ccmp done in s/w
* @cs_crypto_wep: crypto wep done in s/w
* @cs_crypto_setkey_cipher: crypto set key cipher
* @cs_crypto_setkey_nokey: crypto set key no key index
* @cs_crypto_delkey: crypto driver key delete failed
* @cs_crypto_cipher_err: crypto cipher err
* @cs_crypto_attach_fail: crypto attach fail
* @cs_crypto_swfallback: crypto sw fallback
* @cs_crypto_keyfail: crypto key fail
* @cs_ibss_capmismatch: ibss cap mismatch
* @cs_ps_unassoc: ps unassoc
* @cs_ps_aid_err: ps aid err
* @cs_padding: padding
* @cs_invalid_macaddr_nodealloc_failcnt: invalid mac node alloc failures
* @cs_tx_bcn_succ_cnt:tx beacon success
* @cs_tx_bcn_outage_cnt: tx beacon outage
* @total_num_offchan_tx_mgmt: total number of offchan TX mgmt frames
* @total_num_offchan_tx_data: total number of offchan TX data frames
* @num_offchan_tx_failed: number of offchan TX frames failed
* @sta_xceed_rlim: no of connections refused after radio limit
* @sta_xceed_vlim: no of connections refused after vap limit
* @mlme_auth_attempt: no of 802.11 MLME Auth Attempt
* @mlme_auth_success: no of 802.11 MLME Auth Success
* @authorize_attempt: no of Authorization Attempt
* @authorize_success: no of Authorization successful
*/
struct vdev_80211_stats {
uint64_t cs_rx_mgmt;
uint64_t cs_rx_wrongbss;
uint64_t cs_rx_wrongdir;
uint64_t cs_rx_mcast_echo;
uint64_t cs_rx_not_assoc;
uint64_t cs_rx_noprivacy;
uint64_t cs_rx_mgmt_discard;
uint64_t cs_rx_ctl;
uint64_t cs_rx_rs_too_big;
uint64_t cs_rx_elem_missing;
uint64_t cs_rx_elem_too_big;
uint64_t cs_rx_chan_err;
uint64_t cs_rx_node_alloc;
uint64_t cs_rx_ssid_mismatch;
uint64_t cs_rx_auth_unsupported;
uint64_t cs_rx_auth_fail;
uint64_t cs_rx_auth_countermeasures;
uint64_t cs_rx_assoc_bss;
uint64_t cs_rx_assoc_notauth;
uint64_t cs_rx_assoc_cap_mismatch;
uint64_t cs_rx_assoc_norate;
uint64_t cs_rx_assoc_wpaie_err;
uint64_t cs_rx_action;
uint64_t cs_rx_auth_err;
uint64_t cs_tx_nodefkey;
uint64_t cs_tx_noheadroom;
uint64_t cs_rx_acl;
uint64_t cs_rx_nowds;
uint64_t cs_tx_nobuf;
uint64_t cs_tx_nonode;
uint64_t cs_tx_cipher_err;
uint64_t cs_tx_not_ok;
uint64_t cs_tx_bcn_swba;
uint64_t cs_node_timeout;
uint64_t cs_crypto_nomem;
uint64_t cs_crypto_tkip;
uint64_t cs_crypto_tkipenmic;
uint64_t cs_crypto_tkipcm;
uint64_t cs_crypto_ccmp;
uint64_t cs_crypto_wep;
uint64_t cs_crypto_setkey_cipher;
uint64_t cs_crypto_setkey_nokey;
uint64_t cs_crypto_delkey;
uint64_t cs_crypto_cipher_err;
uint64_t cs_crypto_attach_fail;
uint64_t cs_crypto_swfallback;
uint64_t cs_crypto_keyfail;
uint64_t cs_ibss_capmismatch;
uint64_t cs_ps_unassoc;
uint64_t cs_ps_aid_err;
uint64_t cs_padding;
uint64_t cs_tx_offchan_mgmt;
uint64_t cs_tx_offchan_data;
uint64_t cs_tx_offchan_fail;
uint64_t cs_invalid_macaddr_nodealloc_fail;
uint64_t cs_tx_bcn_success;
uint64_t cs_tx_bcn_outage;
uint64_t cs_sta_xceed_rlim;
uint64_t cs_sta_xceed_vlim;
uint64_t cs_mlme_auth_attempt;
uint64_t cs_mlme_auth_success;
uint64_t cs_authorize_attempt;
uint64_t cs_authorize_success;
};
/**

查看文件

@@ -29,6 +29,129 @@
#include <wlan_cp_stats_ic_defs.h>
#include "../../core/src/wlan_cp_stats_defs.h"
#define UCFG_VDEV_CP_STATS_SET_FUNCS(field) \
static inline void \
ucfg_vdev_cp_stats_##field##_inc(struct wlan_objmgr_vdev *_vdev, \
uint64_t _val) \
{ \
struct vdev_cp_stats *_vdev_cs = \
wlan_cp_stats_get_vdev_stats_obj(_vdev); \
if (_vdev_cs) { \
struct vdev_ic_cp_stats *_vdev_ics = \
_vdev_cs->vdev_stats; \
if (_vdev_ics) { \
_vdev_ics->stats.cs_##field += _val;\
} \
} \
} \
static inline void \
ucfg_vdev_cp_stats_##field##_dec(struct wlan_objmgr_vdev *_vdev, \
uint64_t _val) \
{ \
struct vdev_cp_stats *_vdev_cs = \
wlan_cp_stats_get_vdev_stats_obj(_vdev); \
if (_vdev_cs) { \
struct vdev_ic_cp_stats *_vdev_ics = \
_vdev_cs->vdev_stats; \
if (_vdev_ics) { \
_vdev_ics->stats.cs_##field -= _val;\
} \
} \
} \
static inline void \
ucfg_vdev_cp_stats_##field##_update(struct wlan_objmgr_vdev *_vdev, \
uint64_t _val) \
{ \
struct vdev_cp_stats *_vdev_cs = \
wlan_cp_stats_get_vdev_stats_obj(_vdev); \
if (_vdev_cs) { \
struct vdev_ic_cp_stats *_vdev_ics = \
_vdev_cs->vdev_stats; \
if (_vdev_ics) { \
_vdev_ics->stats.cs_##field = _val;\
} \
} \
}
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_wrongbss);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_wrongdir);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_not_assoc);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_noprivacy);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_mgmt_discard);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_ctl);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_rs_too_big);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_elem_missing);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_elem_too_big);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_chan_err);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_node_alloc);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_ssid_mismatch);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_auth_unsupported);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_auth_fail);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_auth_countermeasures);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_assoc_bss);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_assoc_notauth);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_assoc_cap_mismatch);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_assoc_norate);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_assoc_wpaie_err);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_action);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_auth_err);
UCFG_VDEV_CP_STATS_SET_FUNCS(tx_nodefkey);
UCFG_VDEV_CP_STATS_SET_FUNCS(tx_noheadroom);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_acl);
UCFG_VDEV_CP_STATS_SET_FUNCS(rx_nowds);
UCFG_VDEV_CP_STATS_SET_FUNCS(tx_nobuf);
UCFG_VDEV_CP_STATS_SET_FUNCS(tx_nonode);
UCFG_VDEV_CP_STATS_SET_FUNCS(tx_cipher_err);
UCFG_VDEV_CP_STATS_SET_FUNCS(tx_not_ok);
UCFG_VDEV_CP_STATS_SET_FUNCS(tx_bcn_swba);
UCFG_VDEV_CP_STATS_SET_FUNCS(node_timeout);
UCFG_VDEV_CP_STATS_SET_FUNCS(crypto_nomem);
UCFG_VDEV_CP_STATS_SET_FUNCS(crypto_tkip);
UCFG_VDEV_CP_STATS_SET_FUNCS(crypto_tkipenmic);
UCFG_VDEV_CP_STATS_SET_FUNCS(crypto_tkipcm);
UCFG_VDEV_CP_STATS_SET_FUNCS(crypto_ccmp);
UCFG_VDEV_CP_STATS_SET_FUNCS(crypto_wep);
UCFG_VDEV_CP_STATS_SET_FUNCS(crypto_setkey_cipher);
UCFG_VDEV_CP_STATS_SET_FUNCS(crypto_setkey_nokey);
UCFG_VDEV_CP_STATS_SET_FUNCS(crypto_delkey);
UCFG_VDEV_CP_STATS_SET_FUNCS(crypto_cipher_err);
UCFG_VDEV_CP_STATS_SET_FUNCS(crypto_attach_fail);
UCFG_VDEV_CP_STATS_SET_FUNCS(crypto_swfallback);
UCFG_VDEV_CP_STATS_SET_FUNCS(crypto_keyfail);
UCFG_VDEV_CP_STATS_SET_FUNCS(ibss_capmismatch);
UCFG_VDEV_CP_STATS_SET_FUNCS(ps_unassoc);
UCFG_VDEV_CP_STATS_SET_FUNCS(ps_aid_err);
UCFG_VDEV_CP_STATS_SET_FUNCS(tx_offchan_mgmt);
UCFG_VDEV_CP_STATS_SET_FUNCS(tx_offchan_data);
UCFG_VDEV_CP_STATS_SET_FUNCS(tx_offchan_fail);
UCFG_VDEV_CP_STATS_SET_FUNCS(invalid_macaddr_nodealloc_fail);
UCFG_VDEV_CP_STATS_SET_FUNCS(tx_bcn_success);
UCFG_VDEV_CP_STATS_SET_FUNCS(tx_bcn_outage);
UCFG_VDEV_CP_STATS_SET_FUNCS(sta_xceed_rlim);
UCFG_VDEV_CP_STATS_SET_FUNCS(sta_xceed_vlim);
UCFG_VDEV_CP_STATS_SET_FUNCS(mlme_auth_attempt);
UCFG_VDEV_CP_STATS_SET_FUNCS(mlme_auth_success);
UCFG_VDEV_CP_STATS_SET_FUNCS(authorize_attempt);
UCFG_VDEV_CP_STATS_SET_FUNCS(authorize_success);
#define UCFG_VDEV_CP_STATS_GET_FUNCS(field) \
static inline uint64_t \
ucfg_vdev_cp_stats_##field##_get(struct wlan_objmgr_vdev *_vdev) { \
struct vdev_cp_stats *_vdev_cs = \
wlan_cp_stats_get_vdev_stats_obj(_vdev); \
struct vdev_ic_cp_stats *_vdev_ics; \
if (_vdev_cs) { \
_vdev_ics = _vdev_cs->vdev_stats; \
if (_vdev_ics) \
return _vdev_ics->stats.cs_##field; \
} \
return 0; \
}
UCFG_VDEV_CP_STATS_GET_FUNCS(rx_wrongbss);
UCFG_VDEV_CP_STATS_GET_FUNCS(rx_wrongdir);
UCFG_VDEV_CP_STATS_GET_FUNCS(rx_ssid_mismatch);
#define UCFG_VDEV_UCAST_CP_STATS_SET_FUNCS(field) \
static inline void \
ucfg_vdev_ucast_cp_stats_##field##_inc(struct wlan_objmgr_vdev *_vdev, \
@@ -137,7 +260,8 @@ UCFG_VDEV_UCAST_CP_STATS_GET_FUNCS(rx_wepfail);
} \
} \
static inline void ucfg_vdev_mcast_cp_stats_##field##_update( \
struct wlan_objmgr_vdev *_vdev, uint64_t _val) { \
struct wlan_objmgr_vdev *_vdev, uint64_t _val) \
{ \
struct vdev_cp_stats *_vdev_cs = \
wlan_cp_stats_get_vdev_stats_obj(_vdev); \
if (_vdev_cs) { \
@@ -158,11 +282,11 @@ UCFG_VDEV_MCAST_CP_STATS_SET_FUNCS(rx_tkipformat);
UCFG_VDEV_MCAST_CP_STATS_SET_FUNCS(rx_ccmpmic);
UCFG_VDEV_MCAST_CP_STATS_SET_FUNCS(rx_ccmpreplay);
UCFG_VDEV_MCAST_CP_STATS_SET_FUNCS(rx_ccmpformat);
UCFG_VDEV_MCAST_CP_STATS_SET_FUNCS(rx_countermeasure);
UCFG_VDEV_MCAST_CP_STATS_SET_FUNCS(rx_wpimic);
UCFG_VDEV_MCAST_CP_STATS_SET_FUNCS(rx_wpireplay);
UCFG_VDEV_MCAST_CP_STATS_SET_FUNCS(tx_mgmt);
UCFG_VDEV_MCAST_CP_STATS_SET_FUNCS(rx_countermeasure);
UCFG_VDEV_MCAST_CP_STATS_SET_FUNCS(rx_mgmt);
UCFG_VDEV_MCAST_CP_STATS_SET_FUNCS(tx_mgmt);
#define UCFG_VDEV_MCAST_CP_STATS_GET_FUNCS(field) \
static inline uint64_t \
@@ -174,7 +298,7 @@ UCFG_VDEV_MCAST_CP_STATS_SET_FUNCS(rx_mgmt);
if (_vdev_cs) { \
_vdev_ics = _vdev_cs->vdev_stats; \
if (_vdev_ics) \
return _vdev_ics->mcast_stats.cs_##field; \
return _vdev_ics->mcast_stats.cs_##field; \
} \
return 0; \
}

查看文件

@@ -130,6 +130,18 @@ VDEV_UCAST_CP_STATS_SET_FUNCS(rx_countermeasure);
VDEV_UCAST_CP_STATS_SET_FUNCS(rx_mgmt);
VDEV_UCAST_CP_STATS_SET_FUNCS(tx_mgmt);
#define VDEV_UCAST_CP_STATS_GET_FUNCS(field) \
static inline uint64_t \
vdev_ucast_cp_stats_##field##_get(struct wlan_objmgr_vdev *_vdev) \
{ \
return ucfg_vdev_ucast_cp_stats_##field##_get(_vdev); \
}
VDEV_UCAST_CP_STATS_GET_FUNCS(rx_wepfail);
VDEV_UCAST_CP_STATS_GET_FUNCS(rx_decryptok);
VDEV_UCAST_CP_STATS_GET_FUNCS(rx_ccmpmic);
VDEV_UCAST_CP_STATS_GET_FUNCS(rx_ccmpreplay);
#define VDEV_MCAST_CP_STATS_SET_FUNCS(field) \
static inline void \
vdev_mcast_cp_stats_##field##_inc(struct wlan_objmgr_vdev *_vdev, \
@@ -156,20 +168,9 @@ VDEV_MCAST_CP_STATS_SET_FUNCS(rx_ccmpformat);
VDEV_MCAST_CP_STATS_SET_FUNCS(rx_wpimic);
VDEV_MCAST_CP_STATS_SET_FUNCS(rx_wpireplay);
VDEV_MCAST_CP_STATS_SET_FUNCS(rx_countermeasure);
VDEV_MCAST_CP_STATS_SET_FUNCS(rx_mgmt);
VDEV_MCAST_CP_STATS_SET_FUNCS(tx_mgmt);
#define VDEV_UCAST_CP_STATS_GET_FUNCS(field) \
static inline uint64_t \
vdev_ucast_cp_stats_##field##_get(struct wlan_objmgr_vdev *_vdev) \
{ \
return ucfg_vdev_ucast_cp_stats_##field##_get(_vdev); \
}
VDEV_UCAST_CP_STATS_GET_FUNCS(rx_wepfail);
VDEV_UCAST_CP_STATS_GET_FUNCS(rx_decryptok);
VDEV_UCAST_CP_STATS_GET_FUNCS(rx_ccmpmic);
VDEV_UCAST_CP_STATS_GET_FUNCS(rx_ccmpreplay);
#define VDEV_MCAST_CP_STATS_GET_FUNCS(field) \
static inline uint64_t \
vdev_mcast_cp_stats_##field##_get(struct wlan_objmgr_vdev *_vdev) \
@@ -182,5 +183,107 @@ VDEV_MCAST_CP_STATS_GET_FUNCS(rx_decryptok);
VDEV_MCAST_CP_STATS_GET_FUNCS(rx_ccmpmic);
VDEV_MCAST_CP_STATS_GET_FUNCS(rx_ccmpreplay);
#define VDEV_CP_STATS_SET_FUNCS(field) \
static inline void \
vdev_cp_stats_##field##_inc(struct wlan_objmgr_vdev *_vdev, \
uint64_t _val) \
{ \
ucfg_vdev_cp_stats_##field##_inc(_vdev, _val); \
} \
static inline void \
vdev_cp_stats_##field##_update(struct wlan_objmgr_vdev *_vdev, \
uint64_t _val) \
{ \
ucfg_vdev_cp_stats_##field##_update(_vdev, _val); \
}
VDEV_CP_STATS_SET_FUNCS(rx_wrongbss);
VDEV_CP_STATS_SET_FUNCS(rx_wrongdir);
VDEV_CP_STATS_SET_FUNCS(rx_not_assoc);
VDEV_CP_STATS_SET_FUNCS(rx_noprivacy);
VDEV_CP_STATS_SET_FUNCS(rx_mgmt_discard);
VDEV_CP_STATS_SET_FUNCS(rx_ctl);
VDEV_CP_STATS_SET_FUNCS(rx_rs_too_big);
VDEV_CP_STATS_SET_FUNCS(rx_elem_missing);
VDEV_CP_STATS_SET_FUNCS(rx_elem_too_big);
VDEV_CP_STATS_SET_FUNCS(rx_chan_err);
VDEV_CP_STATS_SET_FUNCS(rx_node_alloc);
VDEV_CP_STATS_SET_FUNCS(rx_ssid_mismatch);
VDEV_CP_STATS_SET_FUNCS(rx_auth_unsupported);
VDEV_CP_STATS_SET_FUNCS(rx_auth_fail);
VDEV_CP_STATS_SET_FUNCS(rx_auth_countermeasures);
VDEV_CP_STATS_SET_FUNCS(rx_assoc_bss);
VDEV_CP_STATS_SET_FUNCS(rx_assoc_notauth);
VDEV_CP_STATS_SET_FUNCS(rx_assoc_cap_mismatch);
VDEV_CP_STATS_SET_FUNCS(rx_assoc_norate);
VDEV_CP_STATS_SET_FUNCS(rx_assoc_wpaie_err);
VDEV_CP_STATS_SET_FUNCS(rx_action);
VDEV_CP_STATS_SET_FUNCS(rx_auth_err);
VDEV_CP_STATS_SET_FUNCS(tx_nodefkey);
VDEV_CP_STATS_SET_FUNCS(tx_noheadroom);
VDEV_CP_STATS_SET_FUNCS(rx_acl);
VDEV_CP_STATS_SET_FUNCS(rx_nowds);
VDEV_CP_STATS_SET_FUNCS(tx_nobuf);
VDEV_CP_STATS_SET_FUNCS(tx_nonode);
VDEV_CP_STATS_SET_FUNCS(tx_cipher_err);
VDEV_CP_STATS_SET_FUNCS(tx_not_ok);
VDEV_CP_STATS_SET_FUNCS(tx_bcn_swba);
VDEV_CP_STATS_SET_FUNCS(node_timeout);
VDEV_CP_STATS_SET_FUNCS(crypto_nomem);
VDEV_CP_STATS_SET_FUNCS(crypto_tkip);
VDEV_CP_STATS_SET_FUNCS(crypto_tkipenmic);
VDEV_CP_STATS_SET_FUNCS(crypto_tkipcm);
VDEV_CP_STATS_SET_FUNCS(crypto_ccmp);
VDEV_CP_STATS_SET_FUNCS(crypto_wep);
VDEV_CP_STATS_SET_FUNCS(crypto_setkey_cipher);
VDEV_CP_STATS_SET_FUNCS(crypto_setkey_nokey);
VDEV_CP_STATS_SET_FUNCS(crypto_delkey);
VDEV_CP_STATS_SET_FUNCS(crypto_cipher_err);
VDEV_CP_STATS_SET_FUNCS(crypto_attach_fail);
VDEV_CP_STATS_SET_FUNCS(crypto_swfallback);
VDEV_CP_STATS_SET_FUNCS(crypto_keyfail);
VDEV_CP_STATS_SET_FUNCS(ibss_capmismatch);
VDEV_CP_STATS_SET_FUNCS(ps_unassoc);
VDEV_CP_STATS_SET_FUNCS(ps_aid_err);
VDEV_CP_STATS_SET_FUNCS(tx_offchan_mgmt);
VDEV_CP_STATS_SET_FUNCS(tx_offchan_data);
VDEV_CP_STATS_SET_FUNCS(tx_offchan_fail);
VDEV_CP_STATS_SET_FUNCS(invalid_macaddr_nodealloc_fail);
VDEV_CP_STATS_SET_FUNCS(tx_bcn_success);
VDEV_CP_STATS_SET_FUNCS(tx_bcn_outage);
VDEV_CP_STATS_SET_FUNCS(sta_xceed_rlim);
VDEV_CP_STATS_SET_FUNCS(sta_xceed_vlim);
VDEV_CP_STATS_SET_FUNCS(mlme_auth_attempt);
VDEV_CP_STATS_SET_FUNCS(mlme_auth_success);
VDEV_CP_STATS_SET_FUNCS(authorize_attempt);
VDEV_CP_STATS_SET_FUNCS(authorize_success);
#define VDEV_CP_STATS_GET_FUNCS(field) \
static inline uint64_t \
vdev_cp_stats_##field##_get(struct wlan_objmgr_vdev *_vdev) \
{ \
return ucfg_vdev_cp_stats_##field##_get(_vdev); \
}
VDEV_CP_STATS_GET_FUNCS(rx_wrongbss);
VDEV_CP_STATS_GET_FUNCS(rx_wrongdir);
VDEV_CP_STATS_GET_FUNCS(rx_ssid_mismatch);
static inline void vdev_cp_stats_reset(struct wlan_objmgr_vdev *vdev)
{
struct vdev_cp_stats *vdev_cps;
struct vdev_ic_cp_stats *vdev_cs;
if (!vdev)
return;
vdev_cps = wlan_cp_stats_get_vdev_stats_obj(vdev);
if (!vdev_cps)
return;
vdev_cs = vdev_cps->vdev_stats;
qdf_mem_set(vdev_cs, sizeof(struct vdev_ic_cp_stats), 0x0);
}
#endif /* QCA_SUPPORT_CP_STATS */
#endif /* __WLAN_CP_STATS_IC_UTILS_API_H__ */