Эх сурвалжийг харах

qcacld-3.0: Enable scan mac randomization if INI cfg is set

Enable scan randomization only if gEnableMacAddrSpoof
configuration is enabled

Change-Id: I1b9accb7fe1049ee6c5dda2a4f5920c0908196ff
CRs-Fixed: 2104796
Kiran Kumar Lokere 7 жил өмнө
parent
commit
d547fdda5b

+ 2 - 1
core/hdd/src/wlan_hdd_cfg80211.c

@@ -13231,7 +13231,8 @@ int wlan_hdd_cfg80211_init(struct device *dev,
 
 	hdd_add_channel_switch_support(&wiphy->flags);
 	wiphy->max_num_csa_counters = WLAN_HDD_MAX_NUM_CSA_COUNTERS;
-	wlan_hdd_cfg80211_scan_randomization_init(wiphy);
+	if (pCfg->enable_mac_spoofing)
+		wlan_hdd_cfg80211_scan_randomization_init(wiphy);
 
 	EXIT();
 	return 0;

+ 1 - 0
core/hdd/src/wlan_hdd_main.c

@@ -12158,6 +12158,7 @@ static int hdd_update_scan_config(struct hdd_context *hdd_ctx)
 	scan_cfg.usr_cfg_probe_rpt_time = cfg->scan_probe_repeat_time ;
 	scan_cfg.usr_cfg_num_probes = cfg->scan_num_probes ;
 	scan_cfg.is_bssid_hint_priority = cfg->is_bssid_hint_priority;
+	scan_cfg.enable_mac_spoofing = cfg->enable_mac_spoofing;
 
 	hdd_update_pno_config(&scan_cfg.pno_cfg, cfg);
 	hdd_update_ie_whitelist_attr(&scan_cfg.ie_whitelist, cfg);