summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMasti, Narayanraddi <c_nmasti@qti.qualcomm.com>2016-05-20 15:22:40 +0530
committerAnjaneedevi Kapparapu <akappa@codeaurora.org>2016-05-24 15:44:10 +0530
commit972998cb54d216739a0fc768f34733fa4a3dbcfb (patch)
tree2dcf8e852db8e94612e2e4bf7840fc917524ff6d
parent6bdc116d3f37eca89b8c2c6b318955eaf024e0ac (diff)
qcacld-2.0: Ensure that phy mode from ini is considered for wlan scan
Regardless of phy mode in ini, 5Ghz band is configured to wiphy which was leading to scan on 5ghz even though phy mode was set to 11b/g. Fix will ensure to configure 5Ghz band if ini supports for 5ghz. Change-Id: Ie7735b06ca5ae370077c962a645296ba054ac5d4 CRs-Fixed: 1018993
-rw-r--r--CORE/HDD/src/wlan_hdd_cfg80211.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/CORE/HDD/src/wlan_hdd_cfg80211.c b/CORE/HDD/src/wlan_hdd_cfg80211.c
index 9aad401541b1..740714b06bf4 100644
--- a/CORE/HDD/src/wlan_hdd_cfg80211.c
+++ b/CORE/HDD/src/wlan_hdd_cfg80211.c
@@ -11979,7 +11979,11 @@ int wlan_hdd_cfg80211_init(struct device *dev,
vos_mem_copy(wiphy->bands[IEEE80211_BAND_2GHZ]->channels,
&hdd_channels_2_4_GHZ[0],
sizeof(hdd_channels_2_4_GHZ));
- if (hdd_is_5g_supported(pHddCtx))
+ if (hdd_is_5g_supported(pHddCtx) &&
+ ((eHDD_DOT11_MODE_11b != pCfg->dot11Mode) ||
+ (eHDD_DOT11_MODE_11g != pCfg->dot11Mode) ||
+ (eHDD_DOT11_MODE_11b_ONLY != pCfg->dot11Mode) ||
+ (eHDD_DOT11_MODE_11g_ONLY != pCfg->dot11Mode)))
{
wiphy->bands[IEEE80211_BAND_5GHZ] = &wlan_hdd_band_5_GHZ;
wiphy->bands[IEEE80211_BAND_5GHZ]->channels =