From cdcec49770cf9c485b1d4b34ccdb690fc9b034ea Mon Sep 17 00:00:00 2001 From: Abhishek Singh Date: Tue, 18 Dec 2018 16:09:52 +0530 Subject: [PATCH] qcacmn: Cleanup unused scan configs and params Cleanup unused scan configs and params from scan module. Change-Id: Icbc6ccf63071606e97d36c7efee65b5fd6c3f5f4 CRs-Fixed: 2369076 --- umac/scan/core/src/wlan_scan_main.h | 7 ---- .../dispatcher/inc/wlan_scan_public_structs.h | 33 ------------------- umac/scan/dispatcher/src/wlan_scan_ucfg_api.c | 22 ------------- 3 files changed, 62 deletions(-) diff --git a/umac/scan/core/src/wlan_scan_main.h b/umac/scan/core/src/wlan_scan_main.h index 032623eb4171..d5577de55524 100644 --- a/umac/scan/core/src/wlan_scan_main.h +++ b/umac/scan/core/src/wlan_scan_main.h @@ -293,14 +293,11 @@ struct extscan_def_config { * @max_scan_time: default max scan time * @num_probes: default maximum number of probes to sent * @cache_aging_time: default scan cache aging time - * @prefer_5ghz: Prefer 5ghz AP over 2.4Ghz AP * @select_5gh_margin: Prefer connecting to 5G AP even if * its RSSI is lower by select_5gh_margin dbm than 2.4G AP. * applicable if prefer_5ghz is set. * @is_bssid_hint_priority: True if bssid_hint is given priority * @enable_mac_spoofing: enable mac address spoof in scan - * @bss_prefer_val: bss prefer value for the RSSI category - * @rssi_cat: RSSI category * @max_bss_per_pdev: maximum number of bss entries to be maintained per pdev * @max_active_scans_allowed: maximum number of active parallel scan allowed * per psoc @@ -369,15 +366,11 @@ struct scan_default_params { uint32_t max_scan_time; uint32_t num_probes; uint32_t scan_cache_aging_time; - uint32_t prefer_5ghz; uint32_t select_5ghz_margin; bool enable_mac_spoofing; bool is_bssid_hint_priority; uint32_t usr_cfg_probe_rpt_time; uint32_t usr_cfg_num_probes; - /* each RSSI category has one value */ - uint32_t bss_prefer_val[SCM_NUM_RSSI_CAT]; - int rssi_cat[SCM_NUM_RSSI_CAT]; uint16_t max_bss_per_pdev; uint32_t max_active_scans_allowed; enum scan_priority scan_priority; diff --git a/umac/scan/dispatcher/inc/wlan_scan_public_structs.h b/umac/scan/dispatcher/inc/wlan_scan_public_structs.h index 514d8bf801dc..1f5d2461487c 100644 --- a/umac/scan/dispatcher/inc/wlan_scan_public_structs.h +++ b/umac/scan/dispatcher/inc/wlan_scan_public_structs.h @@ -1311,52 +1311,19 @@ struct pno_user_cfg { /** * struct scan_user_cfg - user configuration required for for scan - * @active_dwell: default active dwell time - * @passive_dwell:default passive dwell time - * @conc_active_dwell: default concurrent active dwell time - * @conc_passive_dwell: default concurrent passive dwell time - * @conc_max_rest_time: default concurrent max rest time - * @conc_min_rest_time: default concurrent min rest time - * @conc_idle_time: default concurrent idle time * @scan_cache_aging_time: default scan cache aging time * @is_snr_monitoring_enabled: whether snr monitoring enabled or not - * @prefer_5ghz: Prefer 5ghz AP over 2.4Ghz AP - * @select_5gh_margin: Prefer connecting to 5G AP even if - * its RSSI is lower by select_5gh_margin dbm than 2.4G AP. - * applicable if prefer_5ghz is set. - * @scan_bucket_threshold: first scan bucket - * threshold to the mentioned value and all the AP's which - * have RSSI under this threshold will fall under this - * bucket - * @rssi_cat_gap: set rssi category gap - * @scan_dwell_time_mode: Adaptive dweltime mode * @pno_cfg: Pno related config params * @ie_whitelist: probe req IE whitelist attrs - * @is_bssid_hint_priority: True if bssid_hint is priority * @enable_mac_spoofing: enable mac address spoof in scan * @sta_miracast_mcc_rest_time: sta miracast mcc rest time * @score_config: scoring logic configuration */ struct scan_user_cfg { - uint32_t active_dwell; - uint32_t passive_dwell; - uint32_t conc_active_dwell; - uint32_t conc_passive_dwell; - uint32_t conc_max_rest_time; - uint32_t conc_min_rest_time; - uint32_t conc_idle_time; uint32_t scan_cache_aging_time; bool is_snr_monitoring_enabled; - uint32_t prefer_5ghz; - uint32_t select_5ghz_margin; - int32_t scan_bucket_threshold; - uint32_t rssi_cat_gap; - enum scan_dwelltime_adaptive_mode scan_dwell_time_mode; struct pno_user_cfg pno_cfg; struct probe_req_whitelist_attr ie_whitelist; - uint32_t usr_cfg_probe_rpt_time; - uint32_t usr_cfg_num_probes; - bool is_bssid_hint_priority; bool enable_mac_spoofing; uint32_t sta_miracast_mcc_rest_time; struct scoring_config score_config; diff --git a/umac/scan/dispatcher/src/wlan_scan_ucfg_api.c b/umac/scan/dispatcher/src/wlan_scan_ucfg_api.c index eb09c7ec54ce..4ad3cccd820b 100644 --- a/umac/scan/dispatcher/src/wlan_scan_ucfg_api.c +++ b/umac/scan/dispatcher/src/wlan_scan_ucfg_api.c @@ -1908,22 +1908,6 @@ ucfg_scan_register_unregister_bcn_cb(struct wlan_objmgr_psoc *psoc, enable ? "Registering" : "Deregistering"); } -static void ucfg_scan_assign_rssi_category(struct scan_default_params *params, - int32_t best_ap_rssi, uint32_t cat_offset) -{ - int i; - - scm_debug("best AP RSSI:%d, cat offset: %d", best_ap_rssi, cat_offset); - if (cat_offset) - for (i = 0; i < SCM_NUM_RSSI_CAT; i++) { - params->rssi_cat[SCM_NUM_RSSI_CAT - i - 1] = - (best_ap_rssi - - params->select_5ghz_margin - - (int)(i * cat_offset)); - params->bss_prefer_val[i] = i; - } -} - QDF_STATUS ucfg_scan_update_user_config(struct wlan_objmgr_psoc *psoc, struct scan_user_cfg *scan_cfg) { @@ -1942,18 +1926,12 @@ QDF_STATUS ucfg_scan_update_user_config(struct wlan_objmgr_psoc *psoc, scan_def = &scan_obj->scan_def; scan_def->scan_cache_aging_time = scan_cfg->scan_cache_aging_time; - scan_def->prefer_5ghz = scan_cfg->prefer_5ghz; - scan_def->select_5ghz_margin = scan_cfg->select_5ghz_margin; scan_def->scan_f_chan_stat_evnt = scan_cfg->is_snr_monitoring_enabled; scan_obj->ie_whitelist = scan_cfg->ie_whitelist; scan_def->enable_mac_spoofing = scan_cfg->enable_mac_spoofing; scan_def->sta_miracast_mcc_rest_time = scan_cfg->sta_miracast_mcc_rest_time; - ucfg_scan_assign_rssi_category(scan_def, - scan_cfg->scan_bucket_threshold, - scan_cfg->rssi_cat_gap); - ucfg_scan_update_pno_config(&scan_obj->pno_cfg, &scan_cfg->pno_cfg);