From a398d5fb2e47a0b11f10cbc7463cf3715a742358 Mon Sep 17 00:00:00 2001 From: gaurank kathpalia Date: Tue, 27 Feb 2018 16:42:22 +0530 Subject: [PATCH] qcacld-3.0: Modify dwell time and DBS scan based on scan request Update wiphy with feature to modify dwell time and DBS scan based on scan request from cfg. Change-Id: I23498799c05a252cbc9c9f6d50b847130dd0ceac CRs-Fixed: 2197172 --- core/hdd/src/wlan_hdd_cfg80211.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/core/hdd/src/wlan_hdd_cfg80211.c b/core/hdd/src/wlan_hdd_cfg80211.c index 96cd3bc0e55c..67d2ef325163 100644 --- a/core/hdd/src/wlan_hdd_cfg80211.c +++ b/core/hdd/src/wlan_hdd_cfg80211.c @@ -15104,6 +15104,20 @@ static void wlan_hdd_cfg80211_set_wiphy_fils_feature(struct wiphy *wiphy) } #endif +#if defined (CFG80211_SCAN_DBS_CONTROL_SUPPORT) || \ + (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 16, 0)) +static void wlan_hdd_cfg80211_set_wiphy_scan_flags(struct wiphy *wiphy) +{ + wiphy_ext_feature_set(wiphy, NL80211_EXT_FEATURE_LOW_SPAN_SCAN); + wiphy_ext_feature_set(wiphy, NL80211_EXT_FEATURE_LOW_POWER_SCAN); + wiphy_ext_feature_set(wiphy, NL80211_EXT_FEATURE_HIGH_ACCURACY_SCAN); +} +#else +static void wlan_hdd_cfg80211_set_wiphy_scan_flags(struct wiphy *wiphy) +{ +} +#endif + #ifdef WLAN_FEATURE_SAE /** * wlan_hdd_cfg80211_set_wiphy_sae_feature() - Indicates support of SAE feature @@ -15185,6 +15199,8 @@ int wlan_hdd_cfg80211_init(struct device *dev, if (pCfg->is_fils_enabled) wlan_hdd_cfg80211_set_wiphy_fils_feature(wiphy); + wlan_hdd_cfg80211_set_wiphy_scan_flags(wiphy); + wlan_hdd_cfg80211_set_wiphy_sae_feature(wiphy, pCfg); hdd_config_sched_scan_plans_to_wiphy(wiphy, pCfg);