qcacld-3.0: Move rso related process to connection manager [PART 7]
Add new code to implement below functions for connection manager roam part: Filling below WMI cmd parameters related process: WMI_ROAM_CONFIGURE_MAWC_CMDID WMI_ROAM_BSS_LOAD_CONFIG_CMDID Rename file wlan_cm_roam_public_srtuct.h name to wlan_cm_roam_public_struct.h Change-Id: I64d54bb78b71dadc49d119b9083658347cc4f807 CRs-Fixed: 2758130
This commit is contained in:
@@ -30,7 +30,7 @@
|
||||
#include "qdf_status.h"
|
||||
#include "wlan_objmgr_psoc_obj.h"
|
||||
#include "wlan_policy_mgr_public_struct.h"
|
||||
#include "wlan_cm_roam_public_srtuct.h"
|
||||
#include "wlan_cm_roam_public_struct.h"
|
||||
#include "wlan_utility.h"
|
||||
#include "sir_types.h"
|
||||
|
||||
|
@@ -35,7 +35,7 @@
|
||||
#include "wlan_nan_api.h"
|
||||
#include "nan_public_structs.h"
|
||||
#include "wlan_reg_services_api.h"
|
||||
#include "wlan_cm_roam_public_srtuct.h"
|
||||
#include "wlan_cm_roam_public_struct.h"
|
||||
#include "csr_neighbor_roam.h"
|
||||
#include "wlan_mlme_main.h"
|
||||
|
||||
|
@@ -28,7 +28,7 @@
|
||||
#include <wlan_cmn.h>
|
||||
#include <wlan_objmgr_vdev_obj.h>
|
||||
#include <wlan_objmgr_peer_obj.h>
|
||||
#include "wlan_cm_roam_public_srtuct.h"
|
||||
#include "wlan_cm_roam_public_struct.h"
|
||||
|
||||
#define mlme_legacy_fatal(params...) QDF_TRACE_FATAL(QDF_MODULE_ID_MLME, params)
|
||||
#define mlme_legacy_err(params...) QDF_TRACE_ERROR(QDF_MODULE_ID_MLME, params)
|
||||
|
@@ -2781,4 +2781,127 @@ wlan_mlme_get_roam_bmiss_final_bcnt(struct wlan_objmgr_psoc *psoc,
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_roam_bmiss_first_bcnt(struct wlan_objmgr_psoc *psoc,
|
||||
uint8_t *val);
|
||||
|
||||
/**
|
||||
* wlan_mlme_get_mawc_enabled() - Get mawc enabled status
|
||||
* @psoc: pointer to psoc object
|
||||
* @val: Pointer to the value which will be filled for the caller
|
||||
*
|
||||
* Return: QDF Status
|
||||
*/
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_mawc_enabled(struct wlan_objmgr_psoc *psoc, bool *val);
|
||||
|
||||
/**
|
||||
* wlan_mlme_get_mawc_roam_enabled() - Get mawc roam enabled status
|
||||
* @psoc: pointer to psoc object
|
||||
* @val: Pointer to the value which will be filled for the caller
|
||||
*
|
||||
* Return: QDF Status
|
||||
*/
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_mawc_roam_enabled(struct wlan_objmgr_psoc *psoc, bool *val);
|
||||
|
||||
/**
|
||||
* wlan_mlme_get_mawc_roam_traffic_threshold() - Get mawc traffic threshold
|
||||
* @psoc: pointer to psoc object
|
||||
* @val: Pointer to the value which will be filled for the caller
|
||||
*
|
||||
* Return: QDF Status
|
||||
*/
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_mawc_roam_traffic_threshold(struct wlan_objmgr_psoc *psoc,
|
||||
uint32_t *val);
|
||||
|
||||
/**
|
||||
* wlan_mlme_get_mawc_roam_ap_rssi_threshold() - Get AP RSSI threshold for
|
||||
* MAWC roaming
|
||||
* @psoc: pointer to psoc object
|
||||
* @val: Pointer to the value which will be filled for the caller
|
||||
*
|
||||
* Return: QDF Status
|
||||
*/
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_mawc_roam_ap_rssi_threshold(struct wlan_objmgr_psoc *psoc,
|
||||
uint32_t *val);
|
||||
|
||||
/**
|
||||
* wlan_mlme_get_mawc_roam_rssi_high_adjust() - Get high adjustment value
|
||||
* for suppressing scan
|
||||
* @psoc: pointer to psoc object
|
||||
* @val: Pointer to the value which will be filled for the caller
|
||||
*
|
||||
* Return: QDF Status
|
||||
*/
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_mawc_roam_rssi_high_adjust(struct wlan_objmgr_psoc *psoc,
|
||||
uint8_t *val);
|
||||
|
||||
/**
|
||||
* wlan_mlme_get_mawc_roam_rssi_low_adjust() - Get low adjustment value
|
||||
* for suppressing scan
|
||||
* @psoc: pointer to psoc object
|
||||
* @val: Pointer to the value which will be filled for the caller
|
||||
*
|
||||
* Return: QDF Status
|
||||
*/
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_mawc_roam_rssi_low_adjust(struct wlan_objmgr_psoc *psoc,
|
||||
uint8_t *val);
|
||||
|
||||
/**
|
||||
* wlan_mlme_get_bss_load_enabled() - Get bss load based roam trigger
|
||||
* enabled status
|
||||
* @psoc: pointer to psoc object
|
||||
* @val: Pointer to the value which will be filled for the caller
|
||||
*
|
||||
* Return: QDF Status
|
||||
*/
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_bss_load_enabled(struct wlan_objmgr_psoc *psoc, bool *val);
|
||||
|
||||
/**
|
||||
* wlan_mlme_get_bss_load_threshold() - Get bss load threshold
|
||||
* @psoc: pointer to psoc object
|
||||
* @val: Pointer to the value which will be filled for the caller
|
||||
*
|
||||
* Return: QDF Status
|
||||
*/
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_bss_load_threshold(struct wlan_objmgr_psoc *psoc, uint32_t *val);
|
||||
|
||||
/**
|
||||
* wlan_mlme_get_bss_load_sample_time() - Get bss load sample time
|
||||
* @psoc: pointer to psoc object
|
||||
* @val: Pointer to the value which will be filled for the caller
|
||||
*
|
||||
* Return: QDF Status
|
||||
*/
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_bss_load_sample_time(struct wlan_objmgr_psoc *psoc,
|
||||
uint32_t *val);
|
||||
|
||||
/**
|
||||
* wlan_mlme_get_bss_load_rssi_threshold_5ghz() - Get bss load RSSI
|
||||
* threshold on 5G
|
||||
* @psoc: pointer to psoc object
|
||||
* @val: Pointer to the value which will be filled for the caller
|
||||
*
|
||||
* Return: QDF Status
|
||||
*/
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_bss_load_rssi_threshold_5ghz(struct wlan_objmgr_psoc *psoc,
|
||||
int32_t *val);
|
||||
|
||||
/**
|
||||
* wlan_mlme_get_bss_load_rssi_threshold_24ghz() - Get bss load RSSI
|
||||
* threshold on 2.4G
|
||||
* @psoc: pointer to psoc object
|
||||
* @val: Pointer to the value which will be filled for the caller
|
||||
*
|
||||
* Return: QDF Status
|
||||
*/
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_bss_load_rssi_threshold_24ghz(struct wlan_objmgr_psoc *psoc,
|
||||
int32_t *val);
|
||||
#endif /* _WLAN_MLME_API_H_ */
|
||||
|
@@ -1577,8 +1577,8 @@ struct wlan_mlme_lfr_cfg {
|
||||
bool wes_mode_enabled;
|
||||
uint32_t mawc_roam_traffic_threshold;
|
||||
uint32_t mawc_roam_ap_rssi_threshold;
|
||||
uint32_t mawc_roam_rssi_high_adjust;
|
||||
uint32_t mawc_roam_rssi_low_adjust;
|
||||
uint8_t mawc_roam_rssi_high_adjust;
|
||||
uint8_t mawc_roam_rssi_low_adjust;
|
||||
uint32_t roam_rssi_abs_threshold;
|
||||
uint8_t rssi_threshold_offset_5g;
|
||||
uint8_t early_stop_scan_min_threshold;
|
||||
|
@@ -4230,3 +4230,186 @@ wlan_mlme_get_roam_bmiss_first_bcnt(struct wlan_objmgr_psoc *psoc,
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_mawc_enabled(struct wlan_objmgr_psoc *psoc, bool *val)
|
||||
{
|
||||
struct wlan_mlme_psoc_ext_obj *mlme_obj;
|
||||
|
||||
mlme_obj = mlme_get_psoc_ext_obj(psoc);
|
||||
if (!mlme_obj) {
|
||||
*val = cfg_default(CFG_LFR_MAWC_FEATURE_ENABLED);
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
*val = mlme_obj->cfg.lfr.mawc_enabled;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_mawc_roam_enabled(struct wlan_objmgr_psoc *psoc, bool *val)
|
||||
{
|
||||
struct wlan_mlme_psoc_ext_obj *mlme_obj;
|
||||
|
||||
mlme_obj = mlme_get_psoc_ext_obj(psoc);
|
||||
if (!mlme_obj) {
|
||||
*val = cfg_default(CFG_LFR_MAWC_ROAM_ENABLED);
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
*val = mlme_obj->cfg.lfr.mawc_roam_enabled;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_mawc_roam_traffic_threshold(struct wlan_objmgr_psoc *psoc,
|
||||
uint32_t *val)
|
||||
{
|
||||
struct wlan_mlme_psoc_ext_obj *mlme_obj;
|
||||
|
||||
mlme_obj = mlme_get_psoc_ext_obj(psoc);
|
||||
if (!mlme_obj) {
|
||||
*val = cfg_default(CFG_LFR_MAWC_ROAM_TRAFFIC_THRESHOLD);
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
*val = mlme_obj->cfg.lfr.mawc_roam_traffic_threshold;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_mawc_roam_ap_rssi_threshold(struct wlan_objmgr_psoc *psoc,
|
||||
uint32_t *val)
|
||||
{
|
||||
struct wlan_mlme_psoc_ext_obj *mlme_obj;
|
||||
|
||||
mlme_obj = mlme_get_psoc_ext_obj(psoc);
|
||||
if (!mlme_obj) {
|
||||
*val = cfg_default(CFG_LFR_MAWC_ROAM_AP_RSSI_THRESHOLD);
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
*val = mlme_obj->cfg.lfr.mawc_roam_ap_rssi_threshold;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_mawc_roam_rssi_high_adjust(struct wlan_objmgr_psoc *psoc,
|
||||
uint8_t *val)
|
||||
{
|
||||
struct wlan_mlme_psoc_ext_obj *mlme_obj;
|
||||
|
||||
mlme_obj = mlme_get_psoc_ext_obj(psoc);
|
||||
if (!mlme_obj) {
|
||||
*val = cfg_default(CFG_LFR_MAWC_ROAM_RSSI_HIGH_ADJUST);
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
*val = mlme_obj->cfg.lfr.mawc_roam_rssi_high_adjust;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_mawc_roam_rssi_low_adjust(struct wlan_objmgr_psoc *psoc,
|
||||
uint8_t *val)
|
||||
{
|
||||
struct wlan_mlme_psoc_ext_obj *mlme_obj;
|
||||
|
||||
mlme_obj = mlme_get_psoc_ext_obj(psoc);
|
||||
if (!mlme_obj) {
|
||||
*val = cfg_default(CFG_LFR_MAWC_ROAM_RSSI_LOW_ADJUST);
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
*val = mlme_obj->cfg.lfr.mawc_roam_rssi_low_adjust;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_bss_load_enabled(struct wlan_objmgr_psoc *psoc, bool *val)
|
||||
{
|
||||
struct wlan_mlme_psoc_ext_obj *mlme_obj;
|
||||
|
||||
mlme_obj = mlme_get_psoc_ext_obj(psoc);
|
||||
if (!mlme_obj) {
|
||||
*val = cfg_default(CFG_ENABLE_BSS_LOAD_TRIGGERED_ROAM);
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
*val = mlme_obj->cfg.lfr.bss_load_trig.enabled;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_bss_load_threshold(struct wlan_objmgr_psoc *psoc, uint32_t *val)
|
||||
{
|
||||
struct wlan_mlme_psoc_ext_obj *mlme_obj;
|
||||
|
||||
mlme_obj = mlme_get_psoc_ext_obj(psoc);
|
||||
if (!mlme_obj) {
|
||||
*val = cfg_default(CFG_BSS_LOAD_THRESHOLD);
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
*val = mlme_obj->cfg.lfr.bss_load_trig.threshold;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_bss_load_sample_time(struct wlan_objmgr_psoc *psoc,
|
||||
uint32_t *val)
|
||||
{
|
||||
struct wlan_mlme_psoc_ext_obj *mlme_obj;
|
||||
|
||||
mlme_obj = mlme_get_psoc_ext_obj(psoc);
|
||||
if (!mlme_obj) {
|
||||
*val = cfg_default(CFG_BSS_LOAD_SAMPLE_TIME);
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
*val = mlme_obj->cfg.lfr.bss_load_trig.sample_time;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_bss_load_rssi_threshold_5ghz(struct wlan_objmgr_psoc *psoc,
|
||||
int32_t *val)
|
||||
{
|
||||
struct wlan_mlme_psoc_ext_obj *mlme_obj;
|
||||
|
||||
mlme_obj = mlme_get_psoc_ext_obj(psoc);
|
||||
if (!mlme_obj) {
|
||||
*val = cfg_default(CFG_BSS_LOAD_TRIG_5G_RSSI_THRES);
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
*val = mlme_obj->cfg.lfr.bss_load_trig.rssi_threshold_5ghz;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_bss_load_rssi_threshold_24ghz(struct wlan_objmgr_psoc *psoc,
|
||||
int32_t *val)
|
||||
{
|
||||
struct wlan_mlme_psoc_ext_obj *mlme_obj;
|
||||
|
||||
mlme_obj = mlme_get_psoc_ext_obj(psoc);
|
||||
if (!mlme_obj) {
|
||||
*val = cfg_default(CFG_BSS_LOAD_TRIG_2G_RSSI_THRES);
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
*val = mlme_obj->cfg.lfr.bss_load_trig.rssi_threshold_24ghz;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
@@ -21,7 +21,7 @@
|
||||
#ifndef TARGET_IF_CM_ROAM_OFFLOAD_H__
|
||||
#define TARGET_IF_CM_ROAM_OFFLOAD_H__
|
||||
|
||||
#include "wlan_cm_roam_public_srtuct.h"
|
||||
#include "wlan_cm_roam_public_struct.h"
|
||||
|
||||
/**
|
||||
* target_if_cm_roam_register_tx_ops - Target IF API to register roam
|
||||
|
@@ -600,6 +600,26 @@ target_if_cm_roam_scan_offload_ap_profile(
|
||||
return wmi_unified_send_roam_scan_offload_ap_cmd(wmi_handle, req);
|
||||
}
|
||||
|
||||
/**
|
||||
* target_if_cm_roam_scan_mawc_params() - send roam macw to
|
||||
* firmware
|
||||
* @wmi_handle: wmi handle
|
||||
* @req: roam macw parameters
|
||||
*
|
||||
* Send WMI_ROAM_CONFIGURE_MAWC_CMDID parameters to firmware
|
||||
*
|
||||
* Return: QDF status
|
||||
*/
|
||||
static QDF_STATUS
|
||||
target_if_cm_roam_scan_mawc_params(wmi_unified_t wmi_handle,
|
||||
struct wlan_roam_mawc_params *req)
|
||||
{
|
||||
if (!wmi_service_enabled(wmi_handle, wmi_service_hw_db2dbm_support))
|
||||
req->best_ap_rssi_threshold -= NOISE_FLOOR_DBM_DEFAULT;
|
||||
|
||||
return wmi_unified_roam_mawc_params_cmd(wmi_handle, req);
|
||||
}
|
||||
|
||||
/**
|
||||
* target_if_cm_roam_scan_filter() - send roam scan filter to firmware
|
||||
* @wmi_handle: wmi handle
|
||||
@@ -705,6 +725,42 @@ target_if_cm_roam_offload_11k_params(wmi_unified_t wmi_handle,
|
||||
return status;
|
||||
}
|
||||
|
||||
/**
|
||||
* target_if_cm_roam_bss_load_config() - send bss load config params to firmware
|
||||
* @wmi_handle: wmi handle
|
||||
* @req: bss load config parameters
|
||||
*
|
||||
* Send WMI_ROAM_BSS_LOAD_CONFIG_CMDID parameters to firmware
|
||||
*
|
||||
* Return: QDF status
|
||||
*/
|
||||
static void
|
||||
target_if_cm_roam_bss_load_config(wmi_unified_t wmi_handle,
|
||||
struct wlan_roam_bss_load_config *req)
|
||||
{
|
||||
QDF_STATUS status;
|
||||
bool db2dbm_enabled;
|
||||
|
||||
db2dbm_enabled = wmi_service_enabled(wmi_handle,
|
||||
wmi_service_hw_db2dbm_support);
|
||||
if (!db2dbm_enabled) {
|
||||
req->rssi_threshold_5ghz -= NOISE_FLOOR_DBM_DEFAULT;
|
||||
req->rssi_threshold_5ghz &= 0x000000ff;
|
||||
|
||||
req->rssi_threshold_24ghz -= NOISE_FLOOR_DBM_DEFAULT;
|
||||
req->rssi_threshold_24ghz &= 0x000000ff;
|
||||
}
|
||||
|
||||
target_if_debug("Bss load trig params vdev %u threshold %u sample_time: %u 5Ghz RSSI threshold:%d 2.4G rssi threshold:%d",
|
||||
req->vdev_id, req->bss_load_threshold,
|
||||
req->bss_load_sample_time, req->rssi_threshold_5ghz,
|
||||
req->rssi_threshold_24ghz);
|
||||
|
||||
status = wmi_unified_send_bss_load_config(wmi_handle, req);
|
||||
if (QDF_IS_STATUS_ERROR(status))
|
||||
target_if_err("failed to send bss load trigger config command");
|
||||
}
|
||||
|
||||
static uint32_t
|
||||
target_if_get_wmi_roam_offload_flag(uint32_t flag)
|
||||
{
|
||||
@@ -768,6 +824,8 @@ target_if_cm_roam_send_start(struct wlan_objmgr_vdev *vdev,
|
||||
{
|
||||
QDF_STATUS status = QDF_STATUS_SUCCESS;
|
||||
wmi_unified_t wmi_handle;
|
||||
struct wlan_objmgr_psoc *psoc;
|
||||
bool bss_load_enabled;
|
||||
|
||||
wmi_handle = target_if_cm_roam_get_wmi_handle_from_vdev(vdev);
|
||||
if (!wmi_handle)
|
||||
@@ -810,6 +868,17 @@ target_if_cm_roam_send_start(struct wlan_objmgr_vdev *vdev,
|
||||
if (QDF_IS_STATUS_ERROR(status))
|
||||
goto end;
|
||||
|
||||
if (wmi_service_enabled(wmi_handle, wmi_service_mawc_support)) {
|
||||
status = target_if_cm_roam_scan_mawc_params(wmi_handle,
|
||||
&req->mawc_params);
|
||||
if (QDF_IS_STATUS_ERROR(status)) {
|
||||
target_if_err("Sending roaming MAWC params failed");
|
||||
goto end;
|
||||
} else {
|
||||
target_if_debug("MAWC roaming not supported by firmware");
|
||||
}
|
||||
}
|
||||
|
||||
status = target_if_cm_roam_scan_filter(wmi_handle,
|
||||
ROAM_SCAN_OFFLOAD_START,
|
||||
&req->scan_filter_params);
|
||||
@@ -836,6 +905,17 @@ target_if_cm_roam_send_start(struct wlan_objmgr_vdev *vdev,
|
||||
goto end;
|
||||
}
|
||||
|
||||
psoc = wlan_vdev_get_psoc(vdev);
|
||||
if (!psoc) {
|
||||
target_if_err("psoc handle is NULL");
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
wlan_mlme_get_bss_load_enabled(psoc, &bss_load_enabled);
|
||||
if (bss_load_enabled)
|
||||
target_if_cm_roam_bss_load_config(wmi_handle,
|
||||
&req->bss_load_config);
|
||||
|
||||
target_if_cm_roam_disconnect_params(wmi_handle, ROAM_SCAN_OFFLOAD_START,
|
||||
&req->disconnect_params);
|
||||
|
||||
|
@@ -97,6 +97,29 @@ cm_roam_triggers(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id,
|
||||
¶ms->vendor_btm_param);
|
||||
}
|
||||
|
||||
/**
|
||||
* cm_roam_bss_load_config() - set bss load config
|
||||
* @psoc: psoc pointer
|
||||
* @vdev_id: vdev id
|
||||
* @params: bss load config parameters
|
||||
*
|
||||
* This function is used to set bss load config parameters
|
||||
*
|
||||
* Return: None
|
||||
*/
|
||||
static void
|
||||
cm_roam_bss_load_config(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id,
|
||||
struct wlan_roam_bss_load_config *params)
|
||||
{
|
||||
params->vdev_id = vdev_id;
|
||||
wlan_mlme_get_bss_load_threshold(psoc, ¶ms->bss_load_threshold);
|
||||
wlan_mlme_get_bss_load_sample_time(psoc, ¶ms->bss_load_sample_time);
|
||||
wlan_mlme_get_bss_load_rssi_threshold_5ghz(
|
||||
psoc, ¶ms->rssi_threshold_5ghz);
|
||||
wlan_mlme_get_bss_load_rssi_threshold_24ghz(
|
||||
psoc, ¶ms->rssi_threshold_24ghz);
|
||||
}
|
||||
|
||||
/**
|
||||
* cm_roam_disconnect_params() - set disconnect roam parameters
|
||||
* @psoc: psoc pointer
|
||||
@@ -150,6 +173,12 @@ cm_roam_triggers(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id,
|
||||
{
|
||||
}
|
||||
|
||||
static void
|
||||
cm_roam_bss_load_config(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id,
|
||||
struct wlan_roam_bss_load_config *params)
|
||||
{
|
||||
}
|
||||
|
||||
static void
|
||||
cm_roam_disconnect_params(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id,
|
||||
struct wlan_roam_disconnect_params *params)
|
||||
@@ -163,6 +192,37 @@ cm_roam_idle_params(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id,
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* cm_roam_mawc_params() - set roam mawc parameters
|
||||
* @psoc: psoc pointer
|
||||
* @vdev_id: vdev id
|
||||
* @params: roam mawc parameters
|
||||
*
|
||||
* This function is used to set roam mawc parameters
|
||||
*
|
||||
* Return: None
|
||||
*/
|
||||
static void
|
||||
cm_roam_mawc_params(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id,
|
||||
struct wlan_roam_mawc_params *params)
|
||||
{
|
||||
bool mawc_enabled;
|
||||
bool mawc_roam_enabled;
|
||||
|
||||
params->vdev_id = vdev_id;
|
||||
wlan_mlme_get_mawc_enabled(psoc, &mawc_enabled);
|
||||
wlan_mlme_get_mawc_roam_enabled(psoc, &mawc_roam_enabled);
|
||||
params->enable = mawc_enabled && mawc_roam_enabled;
|
||||
wlan_mlme_get_mawc_roam_traffic_threshold(
|
||||
psoc, ¶ms->traffic_load_threshold);
|
||||
wlan_mlme_get_mawc_roam_ap_rssi_threshold(
|
||||
psoc, ¶ms->best_ap_rssi_threshold);
|
||||
wlan_mlme_get_mawc_roam_rssi_high_adjust(
|
||||
psoc, ¶ms->rssi_stationary_high_adjust);
|
||||
wlan_mlme_get_mawc_roam_rssi_low_adjust(
|
||||
psoc, ¶ms->rssi_stationary_low_adjust);
|
||||
}
|
||||
|
||||
/**
|
||||
* cm_roam_init_req() - roam init request handling
|
||||
* @psoc: psoc pointer
|
||||
@@ -214,6 +274,8 @@ cm_roam_start_req(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id,
|
||||
cm_roam_scan_bmiss_cnt(psoc, vdev_id, &start_req->beacon_miss_cnt);
|
||||
cm_roam_reason_vsie(psoc, vdev_id, &start_req->reason_vsie_enable);
|
||||
cm_roam_triggers(psoc, vdev_id, &start_req->roam_triggers);
|
||||
cm_roam_mawc_params(psoc, vdev_id, &start_req->mawc_params);
|
||||
cm_roam_bss_load_config(psoc, vdev_id, &start_req->bss_load_config);
|
||||
cm_roam_disconnect_params(psoc, vdev_id, &start_req->disconnect_params);
|
||||
cm_roam_idle_params(psoc, vdev_id, &start_req->idle_params);
|
||||
|
||||
|
@@ -25,7 +25,7 @@
|
||||
#ifndef _WLAN_CM_ROAM_OFFLOAD_H_
|
||||
#define _WLAN_CM_ROAM_OFFLOAD_H_
|
||||
|
||||
#include "wlan_cm_roam_public_srtuct.h"
|
||||
#include "wlan_cm_roam_public_struct.h"
|
||||
|
||||
#if defined(WLAN_FEATURE_HOST_ROAM) || defined(WLAN_FEATURE_ROAM_OFFLOAD)
|
||||
|
||||
|
@@ -24,7 +24,7 @@
|
||||
#define WLAN_CM_ROAM_API_H__
|
||||
|
||||
#include "wlan_mlme_dbg.h"
|
||||
#include "wlan_cm_roam_public_srtuct.h"
|
||||
#include "wlan_cm_roam_public_struct.h"
|
||||
#include "wlan_mlme_main.h"
|
||||
#include "wlan_mlme_api.h"
|
||||
|
||||
|
@@ -216,7 +216,8 @@ struct ap_profile {
|
||||
* ap over the roam score of the current ap
|
||||
* @roam_trigger_bitmap: bitmap of roam triggers on which roam_score_delta
|
||||
* will be applied
|
||||
* @vendor_roam_score_algorithm: Preferred algorithm for roam candidate selection
|
||||
* @vendor_roam_score_algorithm: Preferred algorithm for roam candidate
|
||||
* selection
|
||||
* @cand_min_roam_score_delta: candidate min roam score delta value
|
||||
* @rssi_scoring: RSSI scoring information.
|
||||
* @esp_qbss_scoring: ESP/QBSS scoring percentage information
|
||||
@@ -353,6 +354,24 @@ struct ap_profile_params {
|
||||
struct roam_trigger_score_delta score_delta_param[NUM_OF_ROAM_TRIGGERS];
|
||||
};
|
||||
|
||||
/**
|
||||
* struct wlan_roam_mawc_params - Motion Aided wireless connectivity params
|
||||
* @vdev_id: VDEV on which the parameters should be applied
|
||||
* @enable: MAWC roaming feature enable/disable
|
||||
* @traffic_load_threshold: Traffic threshold in kBps for MAWC roaming
|
||||
* @best_ap_rssi_threshold: AP RSSI Threshold for MAWC roaming
|
||||
* @rssi_stationary_high_adjust: High RSSI adjustment value to suppress scan
|
||||
* @rssi_stationary_low_adjust: Low RSSI adjustment value to suppress scan
|
||||
*/
|
||||
struct wlan_roam_mawc_params {
|
||||
uint8_t vdev_id;
|
||||
bool enable;
|
||||
uint32_t traffic_load_threshold;
|
||||
uint32_t best_ap_rssi_threshold;
|
||||
uint8_t rssi_stationary_high_adjust;
|
||||
uint8_t rssi_stationary_low_adjust;
|
||||
};
|
||||
|
||||
#define MAX_SSID_ALLOWED_LIST 4
|
||||
#define MAX_BSSID_AVOID_LIST 16
|
||||
#define MAX_BSSID_FAVORED 16
|
||||
@@ -445,7 +464,6 @@ struct wlan_roam_btm_config {
|
||||
uint32_t btm_candidate_min_score;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* struct wlan_roam_neighbor_report_params -neighbour report params
|
||||
* @time_offset: time offset after 11k offload command to trigger a neighbor
|
||||
@@ -486,6 +504,27 @@ struct wlan_roam_11k_offload_params {
|
||||
struct wlan_roam_neighbor_report_params neighbor_report_params;
|
||||
};
|
||||
|
||||
/**
|
||||
* struct wlan_roam_bss_load_config - BSS load trigger parameters
|
||||
* @vdev_id: VDEV on which the parameters should be applied
|
||||
* @bss_load_threshold: BSS load threshold after which roam scan should trigger
|
||||
* @bss_load_sample_time: Time duration in milliseconds for which the bss load
|
||||
* trigger needs to be enabled
|
||||
* @rssi_threshold_5ghz: RSSI threshold of the current connected AP below which
|
||||
* roam should be triggered if bss load threshold exceeds the configured value.
|
||||
* This value is applicable only when we are connected in 5GHz band.
|
||||
* @rssi_threshold_24ghz: RSSI threshold of the current connected AP below which
|
||||
* roam should be triggered if bss load threshold exceeds the configured value.
|
||||
* This value is applicable only when we are connected in 2.4GHz band.
|
||||
*/
|
||||
struct wlan_roam_bss_load_config {
|
||||
uint32_t vdev_id;
|
||||
uint32_t bss_load_threshold;
|
||||
uint32_t bss_load_sample_time;
|
||||
int32_t rssi_threshold_5ghz;
|
||||
int32_t rssi_threshold_24ghz;
|
||||
};
|
||||
|
||||
/**
|
||||
* struct roam_disable_cfg - Firmware roam module disable parameters
|
||||
* @vdev_id: vdev for which the roaming has to be enabled/disabled
|
||||
@@ -698,9 +737,11 @@ struct wlan_roam_scan_period_params {
|
||||
* @roam_triggers: roam triggers parameters
|
||||
* @scan_period_params: roam scan period parameters
|
||||
* @profile_params: ap profile parameters
|
||||
* @mawc_params: mawc parameters
|
||||
* @scan_filter_params: roam scan filter parameters
|
||||
* @btm_config: btm configuration
|
||||
* @roam_11k_params: 11k params
|
||||
* @bss_load_config: bss load config
|
||||
* @disconnect_params: disconnect params
|
||||
* @idle_params: idle params
|
||||
*/
|
||||
@@ -711,9 +752,11 @@ struct wlan_roam_start_config {
|
||||
struct wlan_roam_triggers roam_triggers;
|
||||
struct wlan_roam_scan_period_params scan_period_params;
|
||||
struct ap_profile_params profile_params;
|
||||
struct wlan_roam_mawc_params mawc_params;
|
||||
struct wlan_roam_scan_filter_params scan_filter_params;
|
||||
struct wlan_roam_btm_config btm_config;
|
||||
struct wlan_roam_11k_offload_params roam_11k_params;
|
||||
struct wlan_roam_bss_load_config bss_load_config;
|
||||
struct wlan_roam_disconnect_params disconnect_params;
|
||||
struct wlan_roam_idle_params idle_params;
|
||||
/* other wmi cmd structures */
|
||||
@@ -884,11 +927,13 @@ struct wlan_cm_roam_tx_ops {
|
||||
struct wlan_roam_start_config *req);
|
||||
QDF_STATUS (*send_roam_stop_offload)(struct wlan_objmgr_vdev *vdev,
|
||||
struct wlan_roam_stop_config *req);
|
||||
QDF_STATUS (*send_roam_update_config)(struct wlan_objmgr_vdev *vdev,
|
||||
QDF_STATUS (*send_roam_update_config)(
|
||||
struct wlan_objmgr_vdev *vdev,
|
||||
struct wlan_roam_update_config *req);
|
||||
QDF_STATUS (*send_roam_abort)(struct wlan_objmgr_vdev *vdev,
|
||||
uint8_t vdev_id);
|
||||
QDF_STATUS (*send_roam_per_config)(struct wlan_objmgr_vdev *vdev,
|
||||
QDF_STATUS (*send_roam_per_config)(
|
||||
struct wlan_objmgr_vdev *vdev,
|
||||
struct wlan_per_roam_config_req *req);
|
||||
#endif
|
||||
};
|
@@ -23,7 +23,7 @@
|
||||
#ifndef CM_TGT_IF_TX_API_H__
|
||||
#define CM_TGT_IF_TX_API_H__
|
||||
|
||||
#include "wlan_cm_roam_public_srtuct.h"
|
||||
#include "wlan_cm_roam_public_struct.h"
|
||||
|
||||
#define GET_CM_ROAM_TX_OPS_FROM_VDEV(vdev) \
|
||||
(wlan_vdev_mlme_get_ext_hdl(vdev)->cm_roam.tx_ops)
|
||||
|
@@ -22,7 +22,7 @@
|
||||
#define _WMI_UNIFIED_ROAM_API_H_
|
||||
|
||||
#include <wmi_unified_roam_param.h>
|
||||
#include <wlan_cm_roam_public_srtuct.h>
|
||||
#include <wlan_cm_roam_public_struct.h>
|
||||
|
||||
#ifdef FEATURE_LFR_SUBNET_DETECTION
|
||||
/**
|
||||
@@ -126,7 +126,7 @@ QDF_STATUS wmi_unified_roam_scan_offload_scan_period(
|
||||
*/
|
||||
QDF_STATUS
|
||||
wmi_unified_roam_mawc_params_cmd(wmi_unified_t wmi_handle,
|
||||
struct wmi_mawc_roam_params *params);
|
||||
struct wlan_roam_mawc_params *params);
|
||||
|
||||
/**
|
||||
* wmi_unified_roam_scan_filter_cmd() - send roam scan whitelist,
|
||||
@@ -398,12 +398,13 @@ QDF_STATUS wmi_unified_send_btm_config(wmi_unified_t wmi_handle,
|
||||
/**
|
||||
* wmi_unified_send_bss_load_config() - Send bss load trigger params to fw
|
||||
* @wmi_handle: wmi handle
|
||||
* @params: pointer to wmi_bss_load_config
|
||||
* @params: pointer to wlan_roam_bss_load_config
|
||||
*
|
||||
* Return: QDF_STATUS
|
||||
*/
|
||||
QDF_STATUS wmi_unified_send_bss_load_config(wmi_unified_t wmi_handle,
|
||||
struct wmi_bss_load_config *params);
|
||||
QDF_STATUS wmi_unified_send_bss_load_config(
|
||||
wmi_unified_t wmi_handle,
|
||||
struct wlan_roam_bss_load_config *params);
|
||||
|
||||
/**
|
||||
* wmi_unified_offload_11k_cmd() - send 11k offload command
|
||||
|
@@ -153,24 +153,6 @@ struct roam_scan_period_params {
|
||||
};
|
||||
#endif
|
||||
|
||||
/**
|
||||
* struct wmi_mawc_roam_params - Motion Aided wireless connectivity params
|
||||
* @vdev_id: VDEV on which the parameters should be applied
|
||||
* @enable: MAWC roaming feature enable/disable
|
||||
* @traffic_load_threshold: Traffic threshold in kBps for MAWC roaming
|
||||
* @best_ap_rssi_threshold: AP RSSI Threshold for MAWC roaming
|
||||
* @rssi_stationary_high_adjust: High RSSI adjustment value to suppress scan
|
||||
* @rssi_stationary_low_adjust: Low RSSI adjustment value to suppress scan
|
||||
*/
|
||||
struct wmi_mawc_roam_params {
|
||||
uint8_t vdev_id;
|
||||
bool enable;
|
||||
uint32_t traffic_load_threshold;
|
||||
uint32_t best_ap_rssi_threshold;
|
||||
uint8_t rssi_stationary_high_adjust;
|
||||
uint8_t rssi_stationary_low_adjust;
|
||||
};
|
||||
|
||||
#define WMI_CFG_VALID_CHANNEL_LIST_LEN 100
|
||||
/* Occupied channel list remains static */
|
||||
#define WMI_CHANNEL_LIST_STATIC 1
|
||||
@@ -263,27 +245,6 @@ struct hlp_params {
|
||||
uint8_t hlp_ie[WMI_MAX_HLP_IE_LEN];
|
||||
};
|
||||
|
||||
/**
|
||||
* struct wmi_bss_load_config - BSS load trigger parameters
|
||||
* @vdev_id: VDEV on which the parameters should be applied
|
||||
* @bss_load_threshold: BSS load threshold after which roam scan should trigger
|
||||
* @bss_load_sample_time: Time duration in milliseconds for which the bss load
|
||||
* trigger needs to be enabled
|
||||
* @rssi_threshold_5ghz: RSSI threshold of the current connected AP below which
|
||||
* roam should be triggered if bss load threshold exceeds the configured value.
|
||||
* This value is applicable only when we are connected in 5GHz band.
|
||||
* @rssi_threshold_24ghz: RSSI threshold of the current connected AP below which
|
||||
* roam should be triggered if bss load threshold exceeds the configured value.
|
||||
* This value is applicable only when we are connected in 2.4GHz band.
|
||||
*/
|
||||
struct wmi_bss_load_config {
|
||||
uint32_t vdev_id;
|
||||
uint32_t bss_load_threshold;
|
||||
uint32_t bss_load_sample_time;
|
||||
int32_t rssi_threshold_5ghz;
|
||||
int32_t rssi_threshold_24ghz;
|
||||
};
|
||||
|
||||
/**
|
||||
* struct wmi_roam_auth_status_params - WPA3 roam auth response status
|
||||
* parameters
|
||||
|
@@ -95,7 +95,7 @@ wmi_unified_roam_scan_offload_scan_period(wmi_unified_t wmi_handle,
|
||||
|
||||
QDF_STATUS wmi_unified_roam_mawc_params_cmd(
|
||||
wmi_unified_t wmi_handle,
|
||||
struct wmi_mawc_roam_params *params)
|
||||
struct wlan_roam_mawc_params *params)
|
||||
{
|
||||
if (wmi_handle->ops->send_roam_mawc_params_cmd)
|
||||
return wmi_handle->ops->send_roam_mawc_params_cmd(wmi_handle,
|
||||
@@ -318,8 +318,9 @@ QDF_STATUS wmi_unified_send_btm_config(wmi_unified_t wmi_handle,
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
|
||||
QDF_STATUS wmi_unified_send_bss_load_config(wmi_unified_t wmi_handle,
|
||||
struct wmi_bss_load_config *params)
|
||||
QDF_STATUS wmi_unified_send_bss_load_config(
|
||||
wmi_unified_t wmi_handle,
|
||||
struct wlan_roam_bss_load_config *params)
|
||||
{
|
||||
if (wmi_handle->ops->send_roam_bss_load_config)
|
||||
return wmi_handle->ops->send_roam_bss_load_config(wmi_handle,
|
||||
|
@@ -571,8 +571,9 @@ send_roam_scan_offload_scan_period_cmd_tlv(
|
||||
}
|
||||
#endif
|
||||
|
||||
static QDF_STATUS send_roam_mawc_params_cmd_tlv(wmi_unified_t wmi_handle,
|
||||
struct wmi_mawc_roam_params *params)
|
||||
static QDF_STATUS send_roam_mawc_params_cmd_tlv(
|
||||
wmi_unified_t wmi_handle,
|
||||
struct wlan_roam_mawc_params *params)
|
||||
{
|
||||
wmi_buf_t buf = NULL;
|
||||
QDF_STATUS status;
|
||||
@@ -2830,7 +2831,7 @@ static QDF_STATUS send_btm_config_cmd_tlv(wmi_unified_t wmi_handle,
|
||||
/**
|
||||
* send_roam_bss_load_config_tlv() - send roam load bss trigger configuration
|
||||
* @wmi_handle: wmi handle
|
||||
* @parms: pointer to wmi_bss_load_config
|
||||
* @parms: pointer to wlan_roam_bss_load_config
|
||||
*
|
||||
* This function sends the roam load bss trigger configuration to fw.
|
||||
* the bss_load_threshold parameter is used to configure the maximum
|
||||
@@ -2840,7 +2841,7 @@ static QDF_STATUS send_btm_config_cmd_tlv(wmi_unified_t wmi_handle,
|
||||
*/
|
||||
static QDF_STATUS
|
||||
send_roam_bss_load_config_tlv(wmi_unified_t wmi_handle,
|
||||
struct wmi_bss_load_config *params)
|
||||
struct wlan_roam_bss_load_config *params)
|
||||
{
|
||||
wmi_roam_bss_load_config_cmd_fixed_param *cmd;
|
||||
wmi_buf_t buf;
|
||||
|
@@ -105,7 +105,7 @@
|
||||
#include "wlan_mlme_ucfg_api.h"
|
||||
#include "pld_common.h"
|
||||
#include <dp_txrx.h>
|
||||
#include "wlan_cm_roam_public_srtuct.h"
|
||||
#include "wlan_cm_roam_public_struct.h"
|
||||
|
||||
#ifdef WLAN_FEATURE_DP_BUS_BANDWIDTH
|
||||
#include "qdf_periodic_work.h"
|
||||
|
@@ -2327,7 +2327,7 @@ struct roam_offload_scan_req {
|
||||
bool roam_force_rssi_trigger;
|
||||
/* bss load triggered roam related params */
|
||||
bool bss_load_trig_enabled;
|
||||
struct wmi_bss_load_config bss_load_config;
|
||||
struct wlan_roam_bss_load_config bss_load_config;
|
||||
bool roaming_scan_policy;
|
||||
uint32_t roam_scan_inactivity_time;
|
||||
uint32_t roam_inactive_data_packet_count;
|
||||
|
@@ -46,7 +46,7 @@
|
||||
#include <qca_vendor.h>
|
||||
#include "wmi_unified.h"
|
||||
#include "wmi_unified_param.h"
|
||||
#include "wlan_cm_roam_public_srtuct.h"
|
||||
#include "wlan_cm_roam_public_struct.h"
|
||||
|
||||
/*--------------------------------------------------------------------------
|
||||
Preprocessor definitions and constants
|
||||
|
@@ -19997,9 +19997,9 @@ wlan_cm_roam_scan_offload_rsp(uint8_t vdev_id, uint8_t reason)
|
||||
|
||||
if (reason == REASON_OS_REQUESTED_ROAMING_NOW) {
|
||||
scan_offload_rsp = qdf_mem_malloc(sizeof(*scan_offload_rsp));
|
||||
if (!scan_offload_rsp) {
|
||||
if (!scan_offload_rsp)
|
||||
return QDF_STATUS_E_NOMEM;
|
||||
}
|
||||
|
||||
cds_msg.type = eWNI_SME_ROAM_SCAN_OFFLOAD_RSP;
|
||||
scan_offload_rsp->sessionId = vdev_id;
|
||||
scan_offload_rsp->reason = reason;
|
||||
|
@@ -46,7 +46,7 @@
|
||||
#include "wma_api.h"
|
||||
#include "wmi_unified_param.h"
|
||||
#include "wmi.h"
|
||||
#include "wlan_cm_roam_public_srtuct.h"
|
||||
#include "wlan_cm_roam_public_struct.h"
|
||||
|
||||
/* Platform specific configuration for max. no. of fragments */
|
||||
#define QCA_OL_11AC_TX_MAX_FRAGS 2
|
||||
|
@@ -224,7 +224,7 @@ QDF_STATUS wma_update_channel_list(WMA_HANDLE handle,
|
||||
QDF_STATUS wma_roam_scan_mawc_params(tp_wma_handle wma_handle,
|
||||
struct roam_offload_scan_req *roam_req)
|
||||
{
|
||||
struct wmi_mawc_roam_params *params;
|
||||
struct wlan_roam_mawc_params *params;
|
||||
QDF_STATUS status;
|
||||
|
||||
if (!roam_req) {
|
||||
@@ -1670,7 +1670,7 @@ wma_roam_scan_btm_offload(tp_wma_handle wma_handle,
|
||||
*/
|
||||
static
|
||||
void wma_send_roam_bss_load_config(WMA_HANDLE handle,
|
||||
struct wmi_bss_load_config *params)
|
||||
struct wlan_roam_bss_load_config *params)
|
||||
{
|
||||
QDF_STATUS status;
|
||||
tp_wma_handle wma_handle = (tp_wma_handle) handle;
|
||||
@@ -1907,7 +1907,7 @@ QDF_STATUS wma_process_roaming_config(tp_wma_handle wma_handle,
|
||||
uint32_t mode = 0;
|
||||
uint8_t enable_roam_reason_vsie = 0;
|
||||
struct wma_txrx_node *intr = NULL;
|
||||
struct wmi_bss_load_config *bss_load_cfg;
|
||||
struct wlan_roam_bss_load_config *bss_load_cfg;
|
||||
|
||||
if (!mac) {
|
||||
wma_err("mac is NULL");
|
||||
|
Reference in New Issue
Block a user