qcacld-3.0: Add MLO Reconfig event support for logging

Introduce support for MLO Reconfig event for connectivity
logging.

In MLO reconfig event, ban and link id are sent for
logging.

Change-Id: I2de6edff91ae344e2d9e11fb89216dab17384980
CRs-Fixed: 3606709
This commit is contained in:
Vijay Raj
2023-09-04 12:42:34 -07:00
committed by Rahul Choudhary
parent 94f55718b5
commit 3a8a17e839
3 changed files with 61 additions and 0 deletions

View File

@@ -1212,6 +1212,16 @@ wlan_cdp_set_peer_freq(struct wlan_objmgr_psoc *psoc, uint8_t *peer_mac,
uint32_t freq, uint8_t vdev_id);
#ifdef WLAN_FEATURE_11BE_MLO
/**
* wlan_connectivity_mlo_reconfig_event() -API to log MLO reconfig event
* @vdev: vdev pointer
*
* Return: None
*/
void
wlan_connectivity_mlo_reconfig_event(struct wlan_objmgr_vdev *vdev);
/**
* wlan_connectivity_mlo_setup_event() - Fill and send MLO setup data
* @vdev: vdev pointer
@@ -1255,6 +1265,11 @@ wlan_connectivity_t2lm_req_resp_event(struct wlan_objmgr_vdev *vdev,
qdf_freq_t freq,
bool is_rx, uint8_t subtype)
{}
static inline void
wlan_connectivity_mlo_reconfig_event(struct wlan_objmgr_vdev *vdev)
{
}
#endif
/**
@@ -1482,6 +1497,11 @@ wlan_cdp_set_peer_freq(struct wlan_objmgr_psoc *psoc, uint8_t *peer_mac,
uint32_t freq, uint8_t vdev_id)
{}
static inline void
wlan_connectivity_mlo_reconfig_event(struct wlan_objmgr_vdev *vdev)
{
}
static inline void
wlan_connectivity_sta_info_event(struct wlan_objmgr_psoc *psoc,
uint8_t vdev_id)

View File

@@ -334,6 +334,43 @@ wlan_connectivity_t2lm_req_resp_event(struct wlan_objmgr_vdev *vdev,
EVENT_WLAN_MLO_T2LM_REQ_RESP);
}
void
wlan_connectivity_mlo_reconfig_event(struct wlan_objmgr_vdev *vdev)
{
struct mlo_link_info *link_info = NULL;
struct wlan_channel *chan_info = NULL;
uint8_t link_id;
WLAN_HOST_DIAG_EVENT_DEF(wlan_diag_event,
struct wlan_diag_mlo_reconfig);
wlan_diag_event.diag_cmn.ktime_us = qdf_ktime_to_us(qdf_ktime_get());
wlan_diag_event.diag_cmn.timestamp_us = qdf_get_time_of_the_day_us();
wlan_diag_event.version = DIAG_MLO_RECONFIG_VERSION;
link_id = wlan_vdev_get_link_id(vdev);
wlan_diag_event.mlo_cmn_info.link_id = link_id;
if (!vdev->mlo_dev_ctx)
return;
link_info = mlo_mgr_get_ap_link_by_link_id(vdev->mlo_dev_ctx, link_id);
if (!link_info) {
mlme_err("linl: %d Link info not found", link_id);
return;
}
chan_info = link_info->link_chan_info;
if (!chan_info) {
mlme_err("link: %d Chan info not found", link_id);
return;
}
wlan_diag_event.mlo_cmn_info.band =
wlan_convert_freq_to_diag_band(chan_info->ch_freq);
WLAN_HOST_DIAG_EVENT_REPORT(&wlan_diag_event, EVENT_WLAN_MLO_RECONFIG);
}
static QDF_STATUS
wlan_populate_link_addr(struct wlan_objmgr_vdev *vdev,
struct wlan_diag_sta_info *wlan_diag_event)

View File

@@ -46,6 +46,7 @@
#include "wlan_mlme_ucfg_api.h"
#include "wlan_p2p_ucfg_api.h"
#include "wlan_mlo_link_force.h"
#include "wlan_connectivity_logging.h"
/* invalid channel id. */
#define INVALID_CHANNEL_ID 0
@@ -8067,6 +8068,9 @@ void policy_mgr_handle_link_removal_on_vdev(struct wlan_objmgr_vdev *vdev)
vdev_id);
return;
}
wlan_connectivity_mlo_reconfig_event(vdev);
/* mark link removed for vdev */
wlan_set_vdev_link_removed_flag_by_vdev_id(psoc, vdev_id,
true);