From a8f66581e7e83fe5121a99c4b27170026fa84f69 Mon Sep 17 00:00:00 2001 From: Srinivas Girigowda Date: Mon, 26 Jun 2017 23:02:30 -0700 Subject: [PATCH] qcacld-3.0: Fix to set roaming capability in get_supported_features() Because of obsolete macros FEATURE_WLAN_LFR and WLAN_FEATURE_ROAM_SCAN_OFFLOAD roaming capability is not properly set in get_supported_features. Fix this by using the proper macros. Change-Id: I4dec8c32c71fde01b663e11e60f1da171adee3e4 CRs-Fixed: 2067126 --- core/hdd/inc/wlan_hdd_main.h | 30 +++++++++--------------------- 1 file changed, 9 insertions(+), 21 deletions(-) diff --git a/core/hdd/inc/wlan_hdd_main.h b/core/hdd/inc/wlan_hdd_main.h index 320abe26f41b..7736f534e82d 100644 --- a/core/hdd/inc/wlan_hdd_main.h +++ b/core/hdd/inc/wlan_hdd_main.h @@ -1941,25 +1941,25 @@ bool hdd_is_5g_supported(hdd_context_t *pHddCtx); int wlan_hdd_scan_abort(hdd_adapter_t *pAdapter); -#ifdef FEATURE_WLAN_LFR -static inline bool hdd_driver_roaming_supported(hdd_context_t *hdd_ctx) +#ifdef WLAN_FEATURE_ROAM_OFFLOAD +static inline bool roaming_offload_enabled(hdd_context_t *hdd_ctx) { - return hdd_ctx->cfg_ini->isFastRoamIniFeatureEnabled; + return hdd_ctx->config->isRoamOffloadEnabled; } #else -static inline bool hdd_driver_roaming_supported(hdd_context_t *hdd_ctx) +static inline bool roaming_offload_enabled(hdd_context_t *hdd_ctx) { return false; } #endif -#ifdef WLAN_FEATURE_ROAM_SCAN_OFFLOAD -static inline bool hdd_firmware_roaming_supported(hdd_context_t *hdd_ctx) +#ifdef WLAN_FEATURE_HOST_ROAM +static inline bool hdd_driver_roaming_supported(hdd_context_t *hdd_ctx) { - return hdd_ctx->cfg_ini->isRoamOffloadScanEnabled; + return hdd_ctx->config->isFastRoamIniFeatureEnabled; } #else -static inline bool hdd_firmware_roaming_supported(hdd_context_t *hdd_ctx) +static inline bool hdd_driver_roaming_supported(hdd_context_t *hdd_ctx) { return false; } @@ -1970,7 +1970,7 @@ static inline bool hdd_roaming_supported(hdd_context_t *hdd_ctx) bool val; val = hdd_driver_roaming_supported(hdd_ctx) || - hdd_firmware_roaming_supported(hdd_ctx); + roaming_offload_enabled(hdd_ctx); return val; } @@ -2202,18 +2202,6 @@ static inline void wlan_hdd_restart_sap(hdd_adapter_t *ap_adapter) } #endif -#ifdef WLAN_FEATURE_ROAM_OFFLOAD -static inline bool roaming_offload_enabled(hdd_context_t *hdd_ctx) -{ - return hdd_ctx->config->isRoamOffloadEnabled; -} -#else -static inline bool roaming_offload_enabled(hdd_context_t *hdd_ctx) -{ - return false; -} -#endif - void hdd_get_ibss_peer_info_cb(void *pUserData, tSirPeerInfoRspParams *pPeerInfo);