diff --git a/components/mlme/core/src/wlan_mlme_main.c b/components/mlme/core/src/wlan_mlme_main.c
index e5c6bef7e591..a780b0f55d67 100644
--- a/components/mlme/core/src/wlan_mlme_main.c
+++ b/components/mlme/core/src/wlan_mlme_main.c
@@ -1219,21 +1219,55 @@ static void mlme_init_sta_cfg(struct wlan_objmgr_psoc *psoc,
sta->allow_tpc_from_ap = cfg_get(psoc, CFG_TX_POWER_CTRL);
}
+#ifdef WLAN_FEATURE_ROAM_OFFLOAD
+static void mlme_init_roam_offload_cfg(struct wlan_objmgr_psoc *psoc,
+ struct wlan_mlme_lfr_cfg *lfr)
+{
+ lfr->lfr3_roaming_offload =
+ cfg_get(psoc, CFG_LFR3_ROAMING_OFFLOAD);
+}
+
+#else
+static void mlme_init_roam_offload_cfg(struct wlan_objmgr_psoc *psoc,
+ struct wlan_mlme_lfr_cfg *lfr)
+{
+}
+
+#endif
+
+#ifdef FEATURE_WLAN_ESE
+static void mlme_init_ese_cfg(struct wlan_objmgr_psoc *psoc,
+ struct wlan_mlme_lfr_cfg *lfr)
+{
+ lfr->ese_enabled = cfg_get(psoc, CFG_LFR_ESE_FEATURE_ENABLED);
+}
+#else
+static void mlme_init_ese_cfg(struct wlan_objmgr_psoc *psoc,
+ struct wlan_mlme_lfr_cfg *lfr)
+{
+}
+#endif
+
static void mlme_init_lfr_cfg(struct wlan_objmgr_psoc *psoc,
struct wlan_mlme_lfr_cfg *lfr)
{
+ qdf_size_t neighbor_scan_chan_list_num;
+
lfr->mawc_roam_enabled =
cfg_get(psoc, CFG_LFR_MAWC_ROAM_ENABLED);
lfr->enable_fast_roam_in_concurrency =
cfg_get(psoc, CFG_LFR_ENABLE_FAST_ROAM_IN_CONCURRENCY);
- lfr->lfr3_roaming_offload =
- cfg_get(psoc, CFG_LFR3_ROAMING_OFFLOAD);
lfr->early_stop_scan_enable =
cfg_get(psoc, CFG_LFR_EARLY_STOP_SCAN_ENABLE);
lfr->lfr3_enable_subnet_detection =
cfg_get(psoc, CFG_LFR3_ENABLE_SUBNET_DETECTION);
lfr->enable_5g_band_pref =
cfg_get(psoc, CFG_LFR_ENABLE_5G_BAND_PREF);
+ lfr->lfr_enabled = cfg_get(psoc, CFG_LFR_FEATURE_ENABLED);
+ lfr->mawc_enabled = cfg_get(psoc, CFG_LFR_MAWC_FEATURE_ENABLED);
+ lfr->fast_transition_enabled =
+ cfg_get(psoc, CFG_LFR_FAST_TRANSITION_ENABLED);
+ lfr->wes_mode_enabled = cfg_get(psoc, CFG_LFR_ENABLE_WES_MODE);
lfr->mawc_roam_traffic_threshold =
cfg_get(psoc, CFG_LFR_MAWC_ROAM_TRAFFIC_THRESHOLD);
lfr->mawc_roam_ap_rssi_threshold =
@@ -1304,6 +1338,61 @@ static void mlme_init_lfr_cfg(struct wlan_objmgr_psoc *psoc,
cfg_get(psoc, CFG_LFR3_ROAM_PREAUTH_NO_ACK_TIMEOUT);
lfr->roam_preauth_retry_count =
cfg_get(psoc, CFG_LFR3_ROAM_PREAUTH_RETRY_COUNT);
+ lfr->roam_rssi_diff = cfg_get(psoc, CFG_LFR_ROAM_RSSI_DIFF);
+ lfr->roam_scan_offload_enabled =
+ cfg_get(psoc, CFG_LFR_ROAM_SCAN_OFFLOAD_ENABLED);
+ lfr->neighbor_scan_timer_period =
+ cfg_get(psoc, CFG_LFR_NEIGHBOR_SCAN_TIMER_PERIOD);
+ lfr->neighbor_scan_min_timer_period =
+ cfg_get(psoc, CFG_LFR_NEIGHBOR_SCAN_MIN_TIMER_PERIOD);
+ lfr->neighbor_lookup_rssi_threshold =
+ cfg_get(psoc, CFG_LFR_NEIGHBOR_LOOKUP_RSSI_THRESHOLD);
+ lfr->opportunistic_scan_threshold_diff =
+ cfg_get(psoc, CFG_LFR_OPPORTUNISTIC_SCAN_THRESHOLD_DIFF);
+ lfr->roam_rescan_rssi_diff =
+ cfg_get(psoc, CFG_LFR_ROAM_RESCAN_RSSI_DIFF);
+ lfr->neighbor_scan_min_chan_time =
+ cfg_get(psoc, CFG_LFR_NEIGHBOR_SCAN_MIN_CHAN_TIME);
+ lfr->neighbor_scan_max_chan_time =
+ cfg_get(psoc, CFG_LFR_NEIGHBOR_SCAN_MAX_CHAN_TIME);
+ lfr->neighbor_scan_results_refresh_period =
+ cfg_get(psoc, CFG_LFR_NEIGHBOR_SCAN_RESULTS_REFRESH_PERIOD);
+ lfr->empty_scan_refresh_period =
+ cfg_get(psoc, CFG_LFR_EMPTY_SCAN_REFRESH_PERIOD);
+ lfr->roam_bmiss_first_bcnt =
+ cfg_get(psoc, CFG_LFR_ROAM_BMISS_FIRST_BCNT);
+ lfr->roam_bmiss_final_bcnt =
+ cfg_get(psoc, CFG_LFR_ROAM_BMISS_FINAL_BCNT);
+ lfr->roam_beacon_rssi_weight =
+ cfg_get(psoc, CFG_LFR_ROAM_BEACON_RSSI_WEIGHT);
+ lfr->roaming_dfs_channel =
+ cfg_get(psoc, CFG_LFR_ROAMING_DFS_CHANNEL);
+ lfr->roam_scan_hi_rssi_maxcount =
+ cfg_get(psoc, CFG_LFR_ROAM_SCAN_HI_RSSI_MAXCOUNT);
+ lfr->roam_scan_hi_rssi_delta =
+ cfg_get(psoc, CFG_LFR_ROAM_SCAN_HI_RSSI_DELTA);
+ lfr->roam_scan_hi_rssi_delay =
+ cfg_get(psoc, CFG_LFR_ROAM_SCAN_HI_RSSI_DELAY);
+ lfr->roam_scan_hi_rssi_ub =
+ cfg_get(psoc, CFG_LFR_ROAM_SCAN_HI_RSSI_UB);
+ lfr->roam_prefer_5ghz =
+ cfg_get(psoc, CFG_LFR_ROAM_PREFER_5GHZ);
+ lfr->roam_intra_band =
+ cfg_get(psoc, CFG_LFR_ROAM_INTRA_BAND);
+ lfr->roam_scan_home_away_time =
+ cfg_get(psoc, CFG_LFR_ROAM_SCAN_HOME_AWAY_TIME);
+ lfr->roam_scan_n_probes =
+ cfg_get(psoc, CFG_LFR_ROAM_SCAN_N_PROBES);
+ lfr->delay_before_vdev_stop =
+ cfg_get(psoc, CFG_LFR_DELAY_BEFORE_VDEV_STOP);
+ qdf_uint8_array_parse(cfg_default(CFG_LFR_NEIGHBOR_SCAN_CHANNEL_LIST),
+ lfr->neighbor_scan_channel_list,
+ CFG_VALID_CHANNEL_LIST_STRING_LEN,
+ &neighbor_scan_chan_list_num);
+ lfr->neighbor_scan_channel_list_num =
+ (uint8_t)neighbor_scan_chan_list_num;
+ mlme_init_roam_offload_cfg(psoc, lfr);
+ mlme_init_ese_cfg(psoc, lfr);
}
static uint32_t
diff --git a/components/mlme/dispatcher/inc/cfg_mlme_lfr.h b/components/mlme/dispatcher/inc/cfg_mlme_lfr.h
index d8581a5c67a4..7f773e08d85e 100644
--- a/components/mlme/dispatcher/inc/cfg_mlme_lfr.h
+++ b/components/mlme/dispatcher/inc/cfg_mlme_lfr.h
@@ -233,28 +233,6 @@
1, \
"Enable LFR roaming on STA during concurrency")
-/*
- *
- * gRoamOffloadEnabled - enable/disable roam offload feature
- * @Min: 0
- * @Max: 1
- * @Default: 1
- *
- * This INI is used to enable/disable roam offload feature
- *
- * Related: None
- *
- * Supported Feature: Roaming
- *
- * Usage: External
- *
- *
- */
-#define CFG_LFR3_ROAMING_OFFLOAD CFG_INI_BOOL( \
- "gRoamOffloadEnabled", \
- 1, \
- "enable roam offload")
-
/*
*
* gEnableEarlyStopScan - Set early stop scan
@@ -1141,6 +1119,789 @@
CFG_VALUE_OR_DEFAULT, \
"Time to wait after sending an preauth or reassoc")
+/*
+ *
+ * FastRoamEnabled - Enable fast roaming
+ * @Min: 0
+ * @Max: 1
+ * @Default: 0
+ *
+ * This ini is used to inform FW to enable fast roaming
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_FEATURE_ENABLED CFG_INI_BOOL( \
+ "FastRoamEnabled", \
+ 0, \
+ "Enable fast roaming")
+
+/*
+ *
+ * MAWCEnabled - Enable/Disable Motion Aided Wireless Connectivity Global
+ * @Min: 0 - Disabled
+ * @Max: 1 - Enabled
+ * @Default: 0
+ *
+ * This ini is used to controls the MAWC feature globally.
+ * MAWC is Motion Aided Wireless Connectivity.
+ *
+ * Related: mawc_roam_enabled.
+ *
+ * Supported Feature: Roaming and PNO/NLO
+ *
+ * Usage: Internal/External
+ *
+ *
+ */
+#define CFG_LFR_MAWC_FEATURE_ENABLED CFG_INI_BOOL( \
+ "MAWCEnabled", \
+ 0, \
+ "Enable MAWC")
+
+/*
+ *
+ * FastTransitionEnabled - Enable fast transition in case of 11r and ese.
+ * @Min: 0
+ * @Max: 1
+ * @Default: 1
+ *
+ * This ini is used to turn ON/OFF the whole neighbor roam, pre-auth, reassoc.
+ * With this turned OFF 11r will completely not work. For 11r this flag has to
+ * be ON. For ESE fastroam will not work.
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_FAST_TRANSITION_ENABLED CFG_INI_BOOL( \
+ "FastTransitionEnabled", \
+ 1, \
+ "Enable fast transition")
+
+/*
+ *
+ * RoamRssiDiff - Enable roam based on rssi
+ * @Min: 0
+ * @Max: 30
+ * @Default: 5
+ *
+ * This INI is used to decide whether to Roam or not based on RSSI. AP1 is the
+ * currently associated AP and AP2 is chosen for roaming. The Roaming will
+ * happen only if AP2 has better Signal Quality and it has a RSSI better than
+ * AP2. RoamRssiDiff is the number of units (typically measured in dB) AP2
+ * is better than AP1.
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ROAM_RSSI_DIFF CFG_INI_UINT( \
+ "RoamRssiDiff", \
+ 0, \
+ 30, \
+ 5, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Enable roam based on rssi")
+
+/*
+ *
+ * gWESModeEnabled - Enable WES mode
+ * @Min: 0
+ * @Max: 1
+ * @Default: 0
+ *
+ * This ini is used to enable/disable Wireless Extended Security mode.
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ENABLE_WES_MODE CFG_INI_BOOL( \
+ "gWESModeEnabled", \
+ 0, \
+ "Enable WES mode")
+
+/*
+ *
+ * gRoamScanOffloadEnabled - Enable Roam Scan Offload
+ * @Min: 0
+ * @Max: 1
+ * @Default: 1
+ *
+ * This INI is used to enable Roam Scan Offload in firmware
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ROAM_SCAN_OFFLOAD_ENABLED CFG_INI_BOOL( \
+ "gRoamScanOffloadEnabled", \
+ 1, \
+ "Enable Roam Scan Offload")
+
+/*
+ *
+ * gNeighborScanChannelList - Set channels to be scanned
+ * by firmware for LFR scan
+ * @Default: ""
+ *
+ * This ini is used to set the channels to be scanned
+ * by firmware for LFR scan.
+ *
+ * Related: None
+ *
+ * Supported Feature: LFR Scan
+ *
+ * Usage: External
+ *
+ *
+ */
+
+#define CFG_LFR_NEIGHBOR_SCAN_CHANNEL_LIST CFG_INI_STRING( \
+ "gNeighborScanChanList", \
+ 0, \
+ CFG_VALID_CHANNEL_LIST_STRING_LEN, \
+ "", \
+ "Set channels to be scanned")
+
+/*
+ *
+ * gNeighborScanTimerPeriod - Set neighbor scan timer period
+ * @Min: 3
+ * @Max: 300
+ * @Default: 100
+ *
+ * This ini is used to set the timer period in secs after
+ * which neighbor scan is trigerred.
+ *
+ * Related: None
+ *
+ * Supported Feature: LFR Scan
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_NEIGHBOR_SCAN_TIMER_PERIOD CFG_INI_UINT( \
+ "gNeighborScanTimerPeriod", \
+ 3, \
+ 300, \
+ 100, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Neighbor scan timer period")
+
+/*
+ *
+ * gRoamRestTimeMin - Set min neighbor scan timer period
+ * @Min: 3
+ * @Max: 300
+ * @Default: 50
+ *
+ * This is the min rest time after which firmware will check for traffic
+ * and if there no traffic it will move to a new channel to scan
+ * else it will stay on the home channel till gNeighborScanTimerPeriod time
+ * and then will move to a new channel to scan.
+ *
+ * Related: None
+ *
+ * Supported Feature: LFR Scan
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_NEIGHBOR_SCAN_MIN_TIMER_PERIOD CFG_INI_UINT( \
+ "gRoamRestTimeMin", \
+ 3, \
+ 300, \
+ 50, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Min neighbor scan timer period")
+
+/*
+ *
+ * gNeighborLookupThreshold - Set neighbor lookup rssi threshold
+ * @Min: 10
+ * @Max: 120
+ * @Default: 78
+ *
+ * This is used to control the RSSI threshold for neighbor lookup.
+ *
+ * Related: None
+ *
+ * Supported Feature: LFR Scan
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_NEIGHBOR_LOOKUP_RSSI_THRESHOLD CFG_INI_UINT( \
+ "gNeighborLookupThreshold", \
+ 10, \
+ 120, \
+ 78, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Neighbor lookup rssi threshold")
+
+/*
+ *
+ * gOpportunisticThresholdDiff - Set oppurtunistic threshold diff
+ * @Min: 0
+ * @Max: 127
+ * @Default: 0
+ *
+ * This ini is used to set opportunistic threshold diff.
+ * This parameter is the RSSI diff above neighbor lookup
+ * threshold, when opportunistic scan should be triggered.
+ * MAX value is chosen so that this type of scan can be
+ * always enabled by user.
+ * MIN value will cause opportunistic scan to be triggered
+ * in neighbor lookup RSSI range.
+ *
+ * Related: None
+ *
+ * Supported Feature: LFR Scan
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_OPPORTUNISTIC_SCAN_THRESHOLD_DIFF CFG_INI_UINT( \
+ "gOpportunisticThresholdDiff", \
+ 0, \
+ 127, \
+ 0, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Set oppurtunistic threshold diff")
+
+/*
+ *
+ * gRoamRescanRssiDiff - Sets RSSI for Scan trigger in firmware
+ * @Min: 0
+ * @Max: 100
+ * @Default: 5
+ *
+ * This INI is the drop in RSSI value that will trigger a precautionary
+ * scan by firmware. Max value is chosen in such a way that this type
+ * of scan can be disabled by user.
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ROAM_RESCAN_RSSI_DIFF CFG_INI_UINT( \
+ "gRoamRescanRssiDiff", \
+ 0, \
+ 100, \
+ 5, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Sets RSSI for Scan trigger in firmware")
+
+/*
+ *
+ * gNeighborScanChannelMinTime - Set neighbor scan channel min time
+ * @Min: 10
+ * @Max: 40
+ * @Default: 20
+ *
+ * This ini is used to set the minimum time in secs spent on each
+ * channel in LFR scan inside firmware.
+ *
+ * Related: None
+ *
+ * Supported Feature: LFR Scan
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_NEIGHBOR_SCAN_MIN_CHAN_TIME CFG_INI_UINT( \
+ "gNeighborScanChannelMinTime", \
+ 10, \
+ 40, \
+ 20, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Neighbor scan channel min time")
+
+/*
+ *
+ * gNeighborScanChannelMaxTime - Set neighbor scan channel max time
+ * @Min: 3
+ * @Max: 300
+ * @Default: 30
+ *
+ * This ini is used to set the maximum time in secs spent on each
+ * channel in LFR scan inside firmware.
+ *
+ * Related: None
+ *
+ * Supported Feature: LFR Scan
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_NEIGHBOR_SCAN_MAX_CHAN_TIME CFG_INI_UINT( \
+ "gNeighborScanChannelMaxTime", \
+ 3, \
+ 300, \
+ 30, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Neighbor scan channel max time")
+
+/*
+ *
+ * gNeighborScanRefreshPeriod - Set neighbor scan refresh period
+ * @Min: 1000
+ * @Max: 60000
+ * @Default: 20000
+ *
+ * This ini is used by firmware to set scan refresh period
+ * in msecs for lfr scan.
+ *
+ * Related: None
+ *
+ * Supported Feature: LFR Scan
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_NEIGHBOR_SCAN_RESULTS_REFRESH_PERIOD CFG_INI_UINT( \
+ "gNeighborScanRefreshPeriod", \
+ 1000, \
+ 60000, \
+ 20000, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Neighbor scan refresh period")
+
+/*
+ *
+ * gEmptyScanRefreshPeriod - Set empty scan refresh period
+ * @Min: 0
+ * @Max: 60000
+ * @Default: 0
+ *
+ * This ini is used by firmware to set scan period in msecs
+ * following empty scan results.
+ *
+ * Related: None
+ *
+ * Supported Feature: LFR Scan
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_EMPTY_SCAN_REFRESH_PERIOD CFG_INI_UINT( \
+ "gEmptyScanRefreshPeriod", \
+ 0, \
+ 60000, \
+ 0, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Empty scan refresh period")
+
+/*
+ *
+ * gRoamBmissFirstBcnt - Beacon miss count to trigger 1st bmiss event
+ * @Min: 5
+ * @Max: 100
+ * @Default: 10
+ *
+ * This ini used to control how many beacon miss will trigger first bmiss
+ * event. First bmiss event will result in roaming scan.
+ *
+ * Related: None
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ROAM_BMISS_FIRST_BCNT CFG_INI_UINT( \
+ "gRoamBmissFirstBcnt", \
+ 5, \
+ 100, \
+ 10, \
+ CFG_VALUE_OR_DEFAULT, \
+ "First beacon miss count")
+
+/*
+ *
+ * gRoamBmissFinalBcnt - Beacon miss count to trigger final bmiss event
+ * @Min: 5
+ * @Max: 100
+ * @Default: 20
+ *
+ * This ini used to control how many beacon miss will trigger final bmiss
+ * event. Final bmiss event will make roaming take place or cause the
+ * indication of final bmiss event.
+ *
+ * Related: None
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ROAM_BMISS_FINAL_BCNT CFG_INI_UINT( \
+ "gRoamBmissFinalBcnt", \
+ 5, \
+ 100, \
+ 20, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Final beacon miss count")
+
+/*
+ *
+ * gRoamBeaconRssiWeight - Set beacon miss weight
+ * @Min: 5
+ * @Max: 16
+ * @Default: 14
+ *
+ * This ini controls how many beacons' RSSI values will be used to calculate
+ * the average value of RSSI.
+ *
+ * Related: None
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ROAM_BEACON_RSSI_WEIGHT CFG_INI_UINT( \
+ "gRoamBeaconRssiWeight", \
+ 0, \
+ 16, \
+ 14, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Beacon miss weight")
+
+/*
+ *
+ * gAllowDFSChannelRoam - Allow dfs channel in roam
+ * @Min: 0
+ * @Max: 2
+ * @Default: 0
+ *
+ * This ini is used to set default dfs channel
+ *
+ * Related: None
+ *
+ * Supported Feature: STA
+ *
+ * Usage: Internal/External
+ *
+ *
+ */
+#define CFG_LFR_ROAMING_DFS_CHANNEL CFG_INI_UINT( \
+ "gAllowDFSChannelRoam", \
+ 0, \
+ 2, \
+ 0, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Allow dfs channel in roam")
+
+/*
+ *
+ * gRoamScanHiRssiMaxCount - Sets 5GHz maximum scan count
+ * @Min: 0
+ * @Max: 10
+ * @Default: 3
+ *
+ * This INI is used to set maximum scan count in 5GHz
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ROAM_SCAN_HI_RSSI_MAXCOUNT CFG_INI_UINT( \
+ "gRoamScanHiRssiMaxCount", \
+ 0, \
+ 10, \
+ 3, \
+ CFG_VALUE_OR_DEFAULT, \
+ "5GHz maximum scan count")
+
+/*
+ *
+ * gRoamScanHiRssiDelta - Sets RSSI Delta for scan trigger
+ * @Min: 0
+ * @Max: 16
+ * @Default: 10
+ *
+ * This INI is used to set change in RSSI at which scan is triggered
+ * in 5GHz.
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ROAM_SCAN_HI_RSSI_DELTA CFG_INI_UINT( \
+ "gRoamScanHiRssiDelta", \
+ 0, \
+ 16, \
+ 10, \
+ CFG_VALUE_OR_DEFAULT, \
+ "RSSI Delta for scan trigger")
+
+/*
+ *
+ * gRoamScanHiRssiDelay - Sets minimum delay between 5GHz scans
+ * @Min: 5000
+ * @Max: 0x7fffffff
+ * @Default: 15000
+ *
+ * This INI is used to set the minimum delay between 5GHz scans.
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ROAM_SCAN_HI_RSSI_DELAY CFG_INI_UINT( \
+ "gRoamScanHiRssiDelay", \
+ 5000, \
+ 0x7fffffff, \
+ 15000, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Minimum delay between 5GHz scans")
+
+/*
+ *
+ * gRoamScanHiRssiUpperBound - Sets upper bound after which 5GHz scan
+ * @Min: -66
+ * @Max: 0
+ * @Default: -30
+ *
+ * This INI is used to set the RSSI upper bound above which the 5GHz scan
+ * will not be performed.
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ROAM_SCAN_HI_RSSI_UB CFG_INI_INT( \
+ "gRoamScanHiRssiUpperBound", \
+ -66, \
+ 0, \
+ -30, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Upper bound after which 5GHz scan")
+
+/*
+ *
+ * gRoamPrefer5GHz - Prefer roaming to 5GHz Bss
+ * @Min: 0
+ * @Max: 1
+ * @Default: 1
+ *
+ * This ini is used to inform FW to prefer roaming to 5GHz BSS
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ROAM_PREFER_5GHZ CFG_INI_BOOL( \
+ "gRoamPrefer5GHz", \
+ 1, \
+ "Prefer roaming to 5GHz Bss")
+
+/*
+ *
+ * gRoamIntraBand - Prefer roaming within Band
+ * @Min: 0
+ * @Max: 1
+ * @Default: 0
+ *
+ * This ini is used to inform FW to prefer roaming within band
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ROAM_INTRA_BAND CFG_INI_BOOL( \
+ "gRoamIntraBand", \
+ 0, \
+ "Prefer roaming within Band")
+
+/*
+ *
+ * gRoamScanNProbes - Sets the number of probes to be sent for firmware roaming
+ * @Min: 1
+ * @Max: 10
+ * @Default: 2
+ *
+ * This INI is used to set the maximum number of probes the firmware can send
+ * for firmware internal roaming cases.
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ROAM_SCAN_N_PROBES CFG_INI_UINT( \
+ "gRoamScanNProbes", \
+ 1, \
+ 10, \
+ 2, \
+ CFG_VALUE_OR_DEFAULT, \
+ "The number of probes to be sent for firmware roaming")
+
+/*
+ *
+ * gRoamScanHomeAwayTime - Sets the Home Away Time to firmware
+ * @Min: 0
+ * @Max: 300
+ * @Default: 0
+ *
+ * Home Away Time should be at least equal to (gNeighborScanChannelMaxTime
+ * + (2*RFS)), where RFS is the RF Switching time(3). It is twice RFS
+ * to consider the time to go off channel and return to the home channel.
+ *
+ * Related: gNeighborScanChannelMaxTime
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ROAM_SCAN_HOME_AWAY_TIME CFG_INI_UINT( \
+ "gRoamScanHomeAwayTime", \
+ 0, \
+ 300, \
+ 0, \
+ CFG_VALUE_OR_DEFAULT, \
+ "the home away time to firmware")
+
+/*
+ *
+ * gDelayBeforeVdevStop - wait time for tx complete before vdev stop
+ * @Min: 2
+ * @Max: 200
+ * @Default: 20
+ *
+ * This INI is used to set wait time for tx complete before vdev stop.
+ *
+ * Related: None
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_DELAY_BEFORE_VDEV_STOP CFG_INI_UINT( \
+ "gDelayBeforeVdevStop", \
+ 2, \
+ 200, \
+ 20, \
+ CFG_VALUE_OR_DEFAULT, \
+ "wait time for tx complete before vdev stop")
+
+#ifdef WLAN_FEATURE_ROAM_OFFLOAD
+/*
+ *
+ * gRoamOffloadEnabled - enable/disable roam offload feature
+ * @Min: 0
+ * @Max: 1
+ * @Default: 1
+ *
+ * This INI is used to enable/disable roam offload feature
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR3_ROAMING_OFFLOAD CFG_INI_BOOL( \
+ "gRoamOffloadEnabled", \
+ 1, \
+ "enable roam offload")
+
+#define ROAM_OFFLOAD_ALL CFG(CFG_LFR3_ROAMING_OFFLOAD)
+#else
+#define ROAM_OFFLOAD_ALL
+#endif
+
+#ifdef FEATURE_WLAN_ESE
+/*
+ *
+ * EseEnabled - Enable ESE feature
+ * @Min: 0
+ * @Max: 1
+ * @Default: 0
+ *
+ * This ini is used to enable/disable ESE feature
+ *
+ * Related: None
+ *
+ * Supported Feature: Roaming
+ *
+ * Usage: External
+ *
+ *
+ */
+#define CFG_LFR_ESE_FEATURE_ENABLED CFG_INI_BOOL( \
+ "EseEnabled", \
+ 0, \
+ "Enable ESE")
+#define LFR_ESE_ALL CFG(CFG_LFR_ESE_FEATURE_ENABLED)
+#else
+#define LFR_ESE_ALL
+#endif
+
#define CFG_LFR_ALL \
CFG(CFG_LFR_MAWC_ROAM_ENABLED) \
CFG(CFG_LFR_MAWC_ROAM_TRAFFIC_THRESHOLD) \
@@ -1150,7 +1911,6 @@
CFG(CFG_LFR_ROAM_RSSI_ABS_THRESHOLD) \
CFG(CFG_LFR_5G_RSSI_THRESHOLD_OFFSET) \
CFG(CFG_LFR_ENABLE_FAST_ROAM_IN_CONCURRENCY) \
- CFG(CFG_LFR3_ROAMING_OFFLOAD) \
CFG(CFG_LFR_EARLY_STOP_SCAN_ENABLE) \
CFG(CFG_LFR_EARLY_STOP_SCAN_MIN_THRESHOLD) \
CFG(CFG_LFR_EARLY_STOP_SCAN_MAX_THRESHOLD) \
@@ -1182,6 +1942,37 @@
CFG(CFG_LFR_5G_MAX_RSSI_PENALIZE) \
CFG(CFG_LFR_MAX_NUM_PRE_AUTH) \
CFG(CFG_LFR3_ROAM_PREAUTH_RETRY_COUNT) \
- CFG(CFG_LFR3_ROAM_PREAUTH_NO_ACK_TIMEOUT)
+ CFG(CFG_LFR3_ROAM_PREAUTH_NO_ACK_TIMEOUT) \
+ CFG(CFG_LFR_FEATURE_ENABLED) \
+ CFG(CFG_LFR_MAWC_FEATURE_ENABLED) \
+ CFG(CFG_LFR_FAST_TRANSITION_ENABLED) \
+ CFG(CFG_LFR_ROAM_RSSI_DIFF) \
+ CFG(CFG_LFR_ENABLE_WES_MODE) \
+ CFG(CFG_LFR_ROAM_SCAN_OFFLOAD_ENABLED) \
+ CFG(CFG_LFR_NEIGHBOR_SCAN_CHANNEL_LIST) \
+ CFG(CFG_LFR_NEIGHBOR_SCAN_TIMER_PERIOD) \
+ CFG(CFG_LFR_NEIGHBOR_SCAN_MIN_TIMER_PERIOD) \
+ CFG(CFG_LFR_NEIGHBOR_LOOKUP_RSSI_THRESHOLD) \
+ CFG(CFG_LFR_OPPORTUNISTIC_SCAN_THRESHOLD_DIFF) \
+ CFG(CFG_LFR_ROAM_RESCAN_RSSI_DIFF) \
+ CFG(CFG_LFR_NEIGHBOR_SCAN_MIN_CHAN_TIME) \
+ CFG(CFG_LFR_NEIGHBOR_SCAN_MAX_CHAN_TIME) \
+ CFG(CFG_LFR_NEIGHBOR_SCAN_RESULTS_REFRESH_PERIOD) \
+ CFG(CFG_LFR_EMPTY_SCAN_REFRESH_PERIOD) \
+ CFG(CFG_LFR_ROAM_BMISS_FIRST_BCNT) \
+ CFG(CFG_LFR_ROAM_BMISS_FINAL_BCNT) \
+ CFG(CFG_LFR_ROAM_BEACON_RSSI_WEIGHT) \
+ CFG(CFG_LFR_ROAMING_DFS_CHANNEL) \
+ CFG(CFG_LFR_ROAM_SCAN_HI_RSSI_MAXCOUNT) \
+ CFG(CFG_LFR_ROAM_SCAN_HI_RSSI_DELTA) \
+ CFG(CFG_LFR_ROAM_SCAN_HI_RSSI_DELAY) \
+ CFG(CFG_LFR_ROAM_SCAN_HI_RSSI_UB) \
+ CFG(CFG_LFR_ROAM_PREFER_5GHZ) \
+ CFG(CFG_LFR_ROAM_INTRA_BAND) \
+ CFG(CFG_LFR_ROAM_SCAN_N_PROBES) \
+ CFG(CFG_LFR_ROAM_SCAN_HOME_AWAY_TIME) \
+ CFG(CFG_LFR_DELAY_BEFORE_VDEV_STOP) \
+ ROAM_OFFLOAD_ALL \
+ LFR_ESE_ALL
#endif /* CFG_MLME_LFR_H__ */
diff --git a/components/mlme/dispatcher/inc/wlan_mlme_public_struct.h b/components/mlme/dispatcher/inc/wlan_mlme_public_struct.h
index 05e11af92da4..e8359f9d611b 100644
--- a/components/mlme/dispatcher/inc/wlan_mlme_public_struct.h
+++ b/components/mlme/dispatcher/inc/wlan_mlme_public_struct.h
@@ -44,6 +44,8 @@
#define CFG_STR_DATA_LEN 17
#define CFG_EDCA_DATA_LEN 17
+#define CFG_VALID_CHANNEL_LIST_LEN 100
+#define CFG_VALID_CHANNEL_LIST_STRING_LEN (CFG_VALID_CHANNEL_LIST_LEN * 4)
/**
* struct mlme_cfg_str - generic structure for all mlme CFG string items
*
@@ -1041,6 +1043,18 @@ struct wlan_mlme_sta_cfg {
bool allow_tpc_from_ap;
};
+/**
+ * enum roaming_dfs_channel_type - Allow dfs channel in roam
+ * @CFG_ROAMING_DFS_CHANNEL_DISABLED: Disallow dfs channel in roam
+ * @CFG_ROAMING_DFS_CHANNEL_ENABLED_NORMAL: Allow dfs channel
+ * @CFG_ROAMING_DFS_CHANNEL_ENABLED_ACTIVE: Allow dfs channel with active scan
+ */
+enum roaming_dfs_channel_type {
+ ROAMING_DFS_CHANNEL_DISABLED,
+ ROAMING_DFS_CHANNEL_ENABLED_NORMAL,
+ ROAMING_DFS_CHANNEL_ENABLED_ACTIVE,
+};
+
/*
* @mawc_roam_enabled: Enable/Disable MAWC during roaming
* @enable_fast_roam_in_concurrency:Enable LFR roaming on STA during concurrency
@@ -1048,6 +1062,11 @@ struct wlan_mlme_sta_cfg {
* @early_stop_scan_enable: Set early stop scan
* @lfr3_enable_subnet_detection: Enable LFR3 subnet detection
* @enable_5g_band_pref: Enable preference for 5G from INI
+ * @ese_enabled: Enable ESE feature
+ * @lfr_enabled: Enable fast roaming
+ * @mawc_enabled: Enable MAWC
+ * @fast_transition_enabled: Enable fast transition
+ * @wes_mode_enabled: Enable WES mode
* @mawc_roam_traffic_threshold: Configure traffic threshold
* @mawc_roam_ap_rssi_threshold: Best AP RSSI threshold
* @mawc_roam_rssi_high_adjust: Adjust MAWC roam high RSSI
@@ -1083,14 +1102,49 @@ struct wlan_mlme_sta_cfg {
* @max_num_pre_auth: Configure max number of pre-auth
* @roam_preauth_retry_count: Configure the max number of preauth retry
* @roam_preauth_no_ack_timeout: Configure the no ack timeout period
+ * @roam_rssi_diff: Enable roam based on rssi
+ * @roam_scan_offload_enabled: Enable Roam Scan Offload
+ * @neighbor_scan_timer_period: Neighbor scan timer period
+ * @neighbor_scan_min_timer_period: Min neighbor scan timer period
+ * @neighbor_lookup_rssi_threshold: Neighbor lookup rssi threshold
+ * @opportunistic_scan_threshold_diff: Set oppurtunistic threshold diff
+ * @roam_rescan_rssi_diff: Sets RSSI for Scan trigger in firmware
+ * @neighbor_scan_min_chan_time: Neighbor scan channel min time
+ * @neighbor_scan_max_chan_time: Neighbor scan channel max time
+ * @neighbor_scan_results_refresh_period: Neighbor scan refresh period
+ * @empty_scan_refresh_period: Empty scan refresh period
+ * @roam_bmiss_first_bcnt: First beacon miss count
+ * @roam_bmiss_final_bcnt: Final beacon miss count
+ * @roam_beacon_rssi_weight: Beacon miss weight
+ * @roaming_dfs_channel: Allow dfs channel in roam
+ * @roam_scan_hi_rssi_maxcount: 5GHz maximum scan count
+ * @roam_scan_hi_rssi_delta: RSSI Delta for scan trigger
+ * @roam_scan_hi_rssi_delay: Minimum delay between 5GHz scans
+ * @roam_scan_hi_rssi_ub: Upper bound after which 5GHz scan
+ * @roam_prefer_5ghz: Prefer roaming to 5GHz Bss
+ * @roam_intra_band: Prefer roaming within Band
+ * @roam_scan_home_away_time: The home away time to firmware
+ * @roam_scan_n_probes: The number of probes to be sent for firmware roaming
+ * @delay_before_vdev_stop:Wait time for tx complete before vdev stop
+ * @neighbor_scan_channel_list: Neighbor scan channel list
+ * @neighbor_scan_channel_list_num: Neighbor scan channel list number
*/
struct wlan_mlme_lfr_cfg {
bool mawc_roam_enabled;
bool enable_fast_roam_in_concurrency;
+#ifdef WLAN_FEATURE_ROAM_OFFLOAD
bool lfr3_roaming_offload;
+#endif
bool early_stop_scan_enable;
bool lfr3_enable_subnet_detection;
bool enable_5g_band_pref;
+#ifdef FEATURE_WLAN_ESE
+ bool ese_enabled;
+#endif
+ bool lfr_enabled;
+ bool mawc_enabled;
+ bool fast_transition_enabled;
+ bool wes_mode_enabled;
uint32_t mawc_roam_traffic_threshold;
uint32_t mawc_roam_ap_rssi_threshold;
uint32_t mawc_roam_rssi_high_adjust;
@@ -1126,6 +1180,32 @@ struct wlan_mlme_lfr_cfg {
uint32_t max_num_pre_auth;
uint32_t roam_preauth_retry_count;
uint32_t roam_preauth_no_ack_timeout;
+ uint32_t roam_rssi_diff;
+ bool roam_scan_offload_enabled;
+ uint32_t neighbor_scan_timer_period;
+ uint32_t neighbor_scan_min_timer_period;
+ uint32_t neighbor_lookup_rssi_threshold;
+ uint32_t opportunistic_scan_threshold_diff;
+ uint32_t roam_rescan_rssi_diff;
+ uint16_t neighbor_scan_min_chan_time;
+ uint16_t neighbor_scan_max_chan_time;
+ uint32_t neighbor_scan_results_refresh_period;
+ uint32_t empty_scan_refresh_period;
+ uint8_t roam_bmiss_first_bcnt;
+ uint8_t roam_bmiss_final_bcnt;
+ uint32_t roam_beacon_rssi_weight;
+ enum roaming_dfs_channel_type roaming_dfs_channel;
+ uint32_t roam_scan_hi_rssi_maxcount;
+ uint32_t roam_scan_hi_rssi_delta;
+ uint32_t roam_scan_hi_rssi_delay;
+ uint32_t roam_scan_hi_rssi_ub;
+ bool roam_prefer_5ghz;
+ bool roam_intra_band;
+ uint16_t roam_scan_home_away_time;
+ uint32_t roam_scan_n_probes;
+ uint8_t delay_before_vdev_stop;
+ uint8_t neighbor_scan_channel_list[CFG_VALID_CHANNEL_LIST_LEN];
+ uint8_t neighbor_scan_channel_list_num;
};
/**
diff --git a/components/mlme/dispatcher/inc/wlan_mlme_ucfg_api.h b/components/mlme/dispatcher/inc/wlan_mlme_ucfg_api.h
index 1aeeb7f34486..f19a6aa0ed4c 100644
--- a/components/mlme/dispatcher/inc/wlan_mlme_ucfg_api.h
+++ b/components/mlme/dispatcher/inc/wlan_mlme_ucfg_api.h
@@ -764,6 +764,7 @@ ucfg_mlme_get_tgt_gtx_usr_cfg(struct wlan_objmgr_psoc *psoc,
QDF_STATUS
ucfg_mlme_is_override_ht20_40_24g(struct wlan_objmgr_psoc *psoc, bool *val);
+#ifdef WLAN_FEATURE_ROAM_OFFLOAD
/**
* ucfg_mlme_get_roaming_offload() - Get roaming offload setting
* @psoc: pointer to psoc object
@@ -785,6 +786,7 @@ ucfg_mlme_get_roaming_offload(struct wlan_objmgr_psoc *psoc,
QDF_STATUS
ucfg_mlme_set_roaming_offload(struct wlan_objmgr_psoc *psoc,
bool val);
+#endif
/**
* ucfg_mlme_get_first_scan_bucket_threshold() - Get first scan bucket thre
@@ -797,6 +799,188 @@ QDF_STATUS
ucfg_mlme_get_first_scan_bucket_threshold(struct wlan_objmgr_psoc *psoc,
uint8_t *val);
+/**
+ * ucfg_mlme_is_mawc_enabled() - MAWC enabled or not
+ * @psoc: pointer to psoc object
+ * @val: Pointer to the value which will be filled for the caller
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_is_mawc_enabled(struct wlan_objmgr_psoc *psoc, bool *val);
+
+/**
+ * ucfg_mlme_set_mawc_enabled() - Set MAWC enable or disable
+ * @psoc: pointer to psoc object
+ * @val: enable or disable MAWC
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_set_mawc_enabled(struct wlan_objmgr_psoc *psoc, bool val);
+
+/**
+ * ucfg_mlme_is_fast_transition_enabled() - Fast transition enable or not
+ * @psoc: pointer to psoc object
+ * @val: Pointer to the value which will be filled for the caller
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_is_fast_transition_enabled(struct wlan_objmgr_psoc *psoc,
+ bool *val);
+
+/**
+ * ucfg_mlme_set_fast_transition_enabled() - Set fast transition enable
+ * @psoc: pointer to psoc object
+ * @val: Fast transition enable or disable
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_set_fast_transition_enabled(struct wlan_objmgr_psoc *psoc,
+ bool val);
+
+/**
+ * ucfg_mlme_is_roam_scan_offload_enabled() - Roam scan offload enable or not
+ * @psoc: pointer to psoc object
+ * @val: Pointer to the value which will be filled for the caller
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_is_roam_scan_offload_enabled(struct wlan_objmgr_psoc *psoc,
+ bool *val);
+
+/**
+ * ucfg_mlme_set_roam_scan_offload_enabled() - Set roam scan offload enable
+ * @psoc: pointer to psoc object
+ * @val: Roam scan offload enable or disable
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_set_roam_scan_offload_enabled(struct wlan_objmgr_psoc *psoc,
+ bool val);
+
+/**
+ * ucfg_mlme_get_neighbor_scan_max_chan_time() - Get neighbor scan max
+ * channel time
+ * @psoc: pointer to psoc object
+ * @val: Pointer to the value which will be filled for the caller
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_get_neighbor_scan_max_chan_time(struct wlan_objmgr_psoc *psoc,
+ uint16_t *val);
+
+/**
+ * ucfg_mlme_get_neighbor_scan_min_chan_time() - Get neighbor scan min
+ * channel time
+ * @psoc: pointer to psoc object
+ * @val: Pointer to the value which will be filled for the caller
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_get_neighbor_scan_min_chan_time(struct wlan_objmgr_psoc *psoc,
+ uint16_t *val);
+
+/**
+ * ucfg_mlme_get_delay_before_vdev_stop() - Get the delay before vdev stop
+ * @psoc: pointer to psoc object
+ * @val: Pointer to the value which will be filled for the caller
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_get_delay_before_vdev_stop(struct wlan_objmgr_psoc *psoc,
+ uint8_t *val);
+
+/**
+ * ucfg_mlme_get_roam_bmiss_final_bcnt() - Get roam bmiss first count
+ * @psoc: pointer to psoc object
+ * @val: Pointer to the value which will be filled for the caller
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_get_roam_bmiss_final_bcnt(struct wlan_objmgr_psoc *psoc,
+ uint8_t *val);
+/**
+ * ucfg_mlme_get_roam_bmiss_first_bcnt() - Get roam bmiss final count
+ * @psoc: pointer to psoc object
+ * @val: Pointer to the value which will be filled for the caller
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_get_roam_bmiss_first_bcnt(struct wlan_objmgr_psoc *psoc,
+ uint8_t *val);
+
+/**
+ * ucfg_mlme_is_lfr_enabled() - LFR enable or not
+ * @psoc: pointer to psoc object
+ * @val: Pointer to the value which will be filled for the caller
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_is_lfr_enabled(struct wlan_objmgr_psoc *psoc, bool *val);
+
+/**
+ * ucfg_mlme_set_lfr_enabled() - Enable or disable LFR
+ * @psoc: pointer to psoc object
+ * @val: Enable or disable LFR
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_set_lfr_enabled(struct wlan_objmgr_psoc *psoc, bool val);
+
+/**
+ * ucfg_mlme_is_roam_prefer_5ghz() - prefer 5ghz or not
+ * @psoc: pointer to psoc object
+ * @val: Pointer to the value which will be filled for the caller
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_is_roam_prefer_5ghz(struct wlan_objmgr_psoc *psoc, bool *val);
+
+/**
+ * ucfg_mlme_set_roam_intra_band() - Set roam intra modes
+ * @psoc: pointer to psoc object
+ * @val: roam intra modes or not
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_set_roam_intra_band(struct wlan_objmgr_psoc *psoc, bool val);
+
+/**
+ * ucfg_mlme_get_home_away_time() - Get home away time
+ * @psoc: pointer to psoc object
+ * @val: Pointer to the value which will be filled for the caller
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_get_home_away_time(struct wlan_objmgr_psoc *psoc, uint16_t *val);
+
+/**
+ * ucfg_mlme_set_fast_roam_in_concurrency_enabled() - Enable fast roam in
+ * concurrency
+ * @psoc: pointer to psoc object
+ * @val: Enable or disable fast roam in concurrency
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_set_fast_roam_in_concurrency_enabled(struct wlan_objmgr_psoc *psoc,
+ bool val);
+
/**
* ucfg_mlme_get_ps_data_inactivity_timeout() - Get data inactivity timeout
* @psoc: pointer to psoc object
@@ -1962,6 +2146,7 @@ ucfg_mlme_set_supported_mcs_set(struct wlan_objmgr_psoc *psoc, uint8_t *buf,
QDF_STATUS
ucfg_mlme_get_current_mcs_set(struct wlan_objmgr_psoc *psoc, uint8_t *buf,
qdf_size_t *len);
+
/**
* ucfg_mlme_get_wmm_dir_ac_vi() - Get TSPEC direction
* for VI
@@ -2467,7 +2652,17 @@ ucfg_mlme_get_inactivity_interval(struct wlan_objmgr_psoc *psoc,
{
wlan_mlme_get_inactivity_interval(psoc, value);
}
-#endif
+
+/**
+ * ucfg_mlme_is_ese_enabled() - ese feature enable or not
+ * @psoc: pointer to psoc object
+ * @val: Pointer to the value which will be filled for the caller
+ *
+ * Return: QDF Status
+ */
+QDF_STATUS
+ucfg_mlme_is_ese_enabled(struct wlan_objmgr_psoc *psoc, bool *val);
+#endif /* FEATURE_WLAN_ESE */
/**
* ucfg_mlme_get_is_ts_burst_size_enable() - Get TS burst size flag
diff --git a/components/mlme/dispatcher/src/wlan_mlme_ucfg_api.c b/components/mlme/dispatcher/src/wlan_mlme_ucfg_api.c
index 8545152d9935..f4b5176e2598 100644
--- a/components/mlme/dispatcher/src/wlan_mlme_ucfg_api.c
+++ b/components/mlme/dispatcher/src/wlan_mlme_ucfg_api.c
@@ -347,6 +347,7 @@ ucfg_mlme_is_override_ht20_40_24g(struct wlan_objmgr_psoc *psoc, bool *val)
return QDF_STATUS_SUCCESS;
}
+#ifdef WLAN_FEATURE_ROAM_OFFLOAD
QDF_STATUS
ucfg_mlme_get_roaming_offload(struct wlan_objmgr_psoc *psoc,
bool *val)
@@ -381,6 +382,7 @@ ucfg_mlme_set_roaming_offload(struct wlan_objmgr_psoc *psoc,
return QDF_STATUS_SUCCESS;
}
+#endif
QDF_STATUS
ucfg_mlme_get_first_scan_bucket_threshold(struct wlan_objmgr_psoc *psoc,
@@ -400,6 +402,317 @@ ucfg_mlme_get_first_scan_bucket_threshold(struct wlan_objmgr_psoc *psoc,
return QDF_STATUS_SUCCESS;
}
+QDF_STATUS
+ucfg_mlme_is_mawc_enabled(struct wlan_objmgr_psoc *psoc, bool *val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ *val = cfg_default(CFG_LFR_MAWC_FEATURE_ENABLED);
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+ *val = mlme_obj->cfg.lfr.mawc_enabled;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_set_mawc_enabled(struct wlan_objmgr_psoc *psoc, bool val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ mlme_obj->cfg.lfr.mawc_enabled = val;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_is_fast_transition_enabled(struct wlan_objmgr_psoc *psoc,
+ bool *val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ *val = cfg_default(CFG_LFR_FAST_TRANSITION_ENABLED);
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ *val = mlme_obj->cfg.lfr.fast_transition_enabled;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_set_fast_transition_enabled(struct wlan_objmgr_psoc *psoc,
+ bool val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ mlme_obj->cfg.lfr.fast_transition_enabled = val;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_is_roam_scan_offload_enabled(struct wlan_objmgr_psoc *psoc,
+ bool *val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ *val = cfg_default(CFG_LFR_ROAM_SCAN_OFFLOAD_ENABLED);
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ *val = mlme_obj->cfg.lfr.roam_scan_offload_enabled;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_set_roam_scan_offload_enabled(struct wlan_objmgr_psoc *psoc,
+ bool val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ mlme_obj->cfg.lfr.roam_scan_offload_enabled = val;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_get_neighbor_scan_max_chan_time(struct wlan_objmgr_psoc *psoc,
+ uint16_t *val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ *val = cfg_default(CFG_LFR_NEIGHBOR_SCAN_MAX_CHAN_TIME);
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ *val = mlme_obj->cfg.lfr.neighbor_scan_max_chan_time;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_get_neighbor_scan_min_chan_time(struct wlan_objmgr_psoc *psoc,
+ uint16_t *val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ *val = cfg_default(CFG_LFR_NEIGHBOR_SCAN_MIN_CHAN_TIME);
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ *val = mlme_obj->cfg.lfr.neighbor_scan_min_chan_time;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_get_delay_before_vdev_stop(struct wlan_objmgr_psoc *psoc,
+ uint8_t *val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ *val = cfg_default(CFG_LFR_DELAY_BEFORE_VDEV_STOP);
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ *val = mlme_obj->cfg.lfr.delay_before_vdev_stop;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_get_roam_bmiss_final_bcnt(struct wlan_objmgr_psoc *psoc,
+ uint8_t *val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ *val = cfg_default(CFG_LFR_ROAM_BMISS_FINAL_BCNT);
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ *val = mlme_obj->cfg.lfr.roam_bmiss_final_bcnt;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_get_roam_bmiss_first_bcnt(struct wlan_objmgr_psoc *psoc,
+ uint8_t *val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ *val = cfg_default(CFG_LFR_ROAM_BMISS_FIRST_BCNT);
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ *val = mlme_obj->cfg.lfr.roam_bmiss_first_bcnt;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_is_lfr_enabled(struct wlan_objmgr_psoc *psoc, bool *val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ *val = cfg_default(CFG_LFR_FEATURE_ENABLED);
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ *val = mlme_obj->cfg.lfr.lfr_enabled;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_set_lfr_enabled(struct wlan_objmgr_psoc *psoc, bool val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ mlme_obj->cfg.lfr.lfr_enabled = val;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_is_roam_prefer_5ghz(struct wlan_objmgr_psoc *psoc, bool *val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ *val = cfg_default(CFG_LFR_ROAM_PREFER_5GHZ);
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ *val = mlme_obj->cfg.lfr.roam_prefer_5ghz;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_set_roam_intra_band(struct wlan_objmgr_psoc *psoc, bool val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ mlme_obj->cfg.lfr.roam_intra_band = val;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_get_home_away_time(struct wlan_objmgr_psoc *psoc, uint16_t *val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ *val = cfg_default(CFG_LFR_ROAM_SCAN_HOME_AWAY_TIME);
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ *val = mlme_obj->cfg.lfr.roam_scan_home_away_time;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+ucfg_mlme_set_fast_roam_in_concurrency_enabled(struct wlan_objmgr_psoc *psoc,
+ bool val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ mlme_obj->cfg.lfr.enable_fast_roam_in_concurrency = val;
+
+ return QDF_STATUS_SUCCESS;
+}
+
+#ifdef FEATURE_WLAN_ESE
+QDF_STATUS
+ucfg_mlme_is_ese_enabled(struct wlan_objmgr_psoc *psoc, bool *val)
+{
+ struct wlan_mlme_psoc_obj *mlme_obj;
+
+ mlme_obj = mlme_get_psoc_obj(psoc);
+ if (!mlme_obj) {
+ *val = cfg_default(CFG_LFR_ESE_FEATURE_ENABLED);
+ mlme_err("mlme obj null");
+ return QDF_STATUS_E_INVAL;
+ }
+
+ *val = mlme_obj->cfg.lfr.ese_enabled;
+
+ return QDF_STATUS_SUCCESS;
+}
+#endif /* FEATURE_WLAN_ESE */
+
QDF_STATUS
ucfg_mlme_get_opr_rate_set(struct wlan_objmgr_psoc *psoc,
uint8_t *buf, qdf_size_t *len)
@@ -493,10 +806,7 @@ ucfg_mlme_get_ps_data_inactivity_timeout(struct wlan_objmgr_psoc *psoc,
if (!mlme_obj) {
*inactivity_timeout =
cfg_default(CFG_PS_DATA_INACTIVITY_TIMEOUT);
- mlme_err("mlme obj null");
- return QDF_STATUS_E_INVAL;
}
-
*inactivity_timeout = mlme_obj->cfg.timeouts.ps_data_inactivity_timeout;
return QDF_STATUS_SUCCESS;
@@ -519,7 +829,6 @@ ucfg_mlme_set_ps_data_inactivity_timeout(struct wlan_objmgr_psoc *psoc,
inactivity_timeout);
return QDF_STATUS_E_INVAL;
}
-
mlme_obj->cfg.timeouts.ps_data_inactivity_timeout = inactivity_timeout;
return QDF_STATUS_SUCCESS;