qcacld-3.0: Add ini support to send oce subnet id scoring

Introduce an INI "oce_subnet_id_weightage" to indicate firmware
about oce subnet id weightage so that firmware can use subnet id
weightage to calculate candidate AP's score.

Change-Id: Iaf3be1947f8966a2e2c34162d251a31950058231
CRs-Fixed: 2674596
This commit is contained in:
Abhishek Ambure
2020-04-29 00:33:44 +05:30
committed by nshrivas
parent 7f6b2addb3
commit 94d53d68a7
5 changed files with 50 additions and 4 deletions

View File

@@ -1262,7 +1262,7 @@
/*
* <ini>
* CFG_OCE_AP_TX_PWR_WEIGHTAGE - update scoring param based on ap tx power
* oce_ap_tx_pwr_weightage - update scoring param based on ap tx power
* @Min: 0
* @Max: 10
* @Default: 5
@@ -1285,6 +1285,42 @@
CFG_VALUE_OR_DEFAULT,\
"AP weigtage for OCE ap tx power")
/*
* <ini>
* oce_subnet_id_weightage - update scoring param based on subnet id
* @Min: 0
* @Max: 10
* @Default: 3
*
* This ini is used to calculate subnet id weightage in roam score.
* If the MBO-OCE ie has "IP subnet indication attribute", then host
* considers 50% of the "oce_subnet_id_weightage" value to calculate
* roam score for the initial connection and 100% of the
* "oce_subnet_id_weightage" value to calculate roam score for roaming
* case.
* "oce_ap_tx_pwr_weightage" adds a small amount of percentage advantage
* in roam score while selection of an AP candidate within the same subnet
* ID. If "oce_ap_tx_pwr_weightage" value is 0(min), roam score doesn't
* include percentage weightage for subnet id and if "oce_ap_tx_pwr_weightage"
* value is 10(max), then the weightage given because of same subnet ID is
* more in roam score. This ini is also used for WFA certification.
*
* Related: None
*
* Supported Feature: STA
*
* Usage: External
*
* </ini>
*/
#define CFG_OCE_SUBNET_ID_WEIGHTAGE CFG_INI_UINT( \
"oce_subnet_id_weightage", \
0, \
10, \
3, \
CFG_VALUE_OR_DEFAULT,\
"AP weigtage for OCE subnet id")
#define CFG_SCORING_ALL \
CFG(CFG_SCORING_RSSI_WEIGHTAGE) \
CFG(CFG_SCORING_HT_CAPS_WEIGHTAGE) \
@@ -1329,5 +1365,6 @@
CFG(CFG_BTM_ROAM_SCORE_DELTA) \
CFG(CFG_VENDOR_ROAM_SCORE_ALGORITHM) \
CFG(CFG_OCE_AP_TX_PWR_WEIGHTAGE) \
CFG(CFG_OCE_SUBNET_ID_WEIGHTAGE) \
#endif /* __CFG_MLME_SCORING_H */

View File

@@ -1818,7 +1818,6 @@ struct wlan_mlme_wmm_params {
/**
* struct wlan_mlme_weight_config - weight params to
* calculate best candidate
*
* @rssi_weightage: RSSI weightage
* @ht_caps_weightage: HT caps weightage
* @vht_caps_weightage: VHT caps weightage
@@ -1831,6 +1830,7 @@ struct wlan_mlme_wmm_params {
* @channel_congestion_weightage: channel congestion weightage
* @oce_wan_weightage: OCE WAN metrics weightage
* @oce_ap_tx_pwr_weightage: weightage based on ap tx power
* @oce_subnet_id_weightage: weightage based on subnet id
*/
struct wlan_mlme_weight_config {
uint8_t rssi_weightage;
@@ -1845,12 +1845,12 @@ struct wlan_mlme_weight_config {
uint8_t channel_congestion_weightage;
uint8_t oce_wan_weightage;
uint8_t oce_ap_tx_pwr_weightage;
uint8_t oce_subnet_id_weightage;
};
/**
* struct wlan_mlme_rssi_cfg_score - RSSI params to
* calculate best candidate
*
* @best_rssi_threshold: Best RSSI threshold
* @good_rssi_threshold: Good RSSI threshold
* @bad_rssi_threshold: Bad RSSI threshold