diff options
author | Subhani Shaik <subhanis@codeaurora.org> | 2017-06-13 21:15:43 +0000 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2017-06-13 21:15:43 +0000 |
commit | 1e2253cc22c72f65e9617785bd7b3bcf70800676 (patch) | |
tree | ce6042c59e30914ee3cd06ee782799db47e16905 | |
parent | ec97908217928498387712c0633d7b4ad0e1f42b (diff) | |
parent | 37f39c7dac1445e02c81c93448d5c8b78b174eff (diff) | |
download | android_hardware_qcom_wlan-1e2253cc22c72f65e9617785bd7b3bcf70800676.tar.gz android_hardware_qcom_wlan-1e2253cc22c72f65e9617785bd7b3bcf70800676.tar.bz2 android_hardware_qcom_wlan-1e2253cc22c72f65e9617785bd7b3bcf70800676.zip |
Wifi-HAL: Remove gscan APIs route to LOWI
am: 37f39c7dac
Change-Id: Ie4415df62c343e8258b788e9b76bc21025a0406a
-rw-r--r-- | qcwcn/wifi_hal/gscan.cpp | 125 |
1 files changed, 0 insertions, 125 deletions
diff --git a/qcwcn/wifi_hal/gscan.cpp b/qcwcn/wifi_hal/gscan.cpp index e6d71a0..7894b26 100644 --- a/qcwcn/wifi_hal/gscan.cpp +++ b/qcwcn/wifi_hal/gscan.cpp @@ -97,20 +97,6 @@ wifi_error wifi_get_valid_channels(wifi_interface_handle handle, struct nlattr *nlData; interface_info *ifaceInfo = getIfaceInfo(handle); wifi_handle wifiHandle = getWifiHandle(handle); - lowi_cb_table_t *lowiWifiHalApi = NULL; - - /* Route GSCAN request through LOWI if supported */ - lowiWifiHalApi = getLowiCallbackTable(GSCAN_SUPPORTED); - if (lowiWifiHalApi == NULL || - lowiWifiHalApi->get_valid_channels == NULL) { - ALOGV("%s: Sending cmd directly to host", __FUNCTION__); - } else { - ret = lowiWifiHalApi->get_valid_channels(handle, band, max_channels, - channels, num_channels); - ALOGV("%s: lowi get_valid_channels " - "returned: %d. Exit.", __FUNCTION__, ret); - return (wifi_error)ret; - } /* No request id from caller, so generate one and pass it on to the driver. * Generate one randomly. @@ -184,7 +170,6 @@ wifi_error wifi_get_gscan_capabilities(wifi_interface_handle handle, wifi_error ret = WIFI_SUCCESS; wifi_handle wifiHandle = getWifiHandle(handle); hal_info *info = getHalInfo(wifiHandle); - lowi_cb_table_t *lowiWifiHalApi = NULL; if (!(info->supported_feature_set & WIFI_FEATURE_GSCAN)) { ALOGE("%s: GSCAN is not supported by driver", __FUNCTION__); @@ -196,17 +181,6 @@ wifi_error wifi_get_gscan_capabilities(wifi_interface_handle handle, return WIFI_ERROR_INVALID_ARGS; } - /* Route GSCAN request through LOWI if supported */ - lowiWifiHalApi = getLowiCallbackTable(GSCAN_SUPPORTED); - if (lowiWifiHalApi == NULL || - lowiWifiHalApi->get_gscan_capabilities == NULL) { - ALOGV("%s: Sending cmd directly to host", __FUNCTION__); - } else { - ret = lowiWifiHalApi->get_gscan_capabilities(handle, capabilities); - ALOGV("%s: lowi get_gscan_capabilities returned: %d. Exit.", __FUNCTION__, ret); - return ret; - } - memcpy(capabilities, &info->capa.gscan_capa, sizeof(wifi_gscan_capabilities)); return ret; @@ -227,7 +201,6 @@ wifi_error wifi_start_gscan(wifi_request_id id, wifi_scan_bucket_spec bucketSpec; struct nlattr *nlBuckectSpecList; hal_info *info = getHalInfo(wifiHandle); - lowi_cb_table_t *lowiWifiHalApi = NULL; gscan_event_handlers* event_handlers; GScanCommandEventHandler *gScanStartCmdEventHandler; @@ -240,18 +213,6 @@ wifi_error wifi_start_gscan(wifi_request_id id, return WIFI_ERROR_NOT_SUPPORTED; } - /* Route GSCAN request through LOWI if supported */ - lowiWifiHalApi = getLowiCallbackTable(GSCAN_SUPPORTED); - if (lowiWifiHalApi == NULL || - lowiWifiHalApi->start_gscan == NULL) { - ALOGV("%s: Sending cmd directly to host", __FUNCTION__); - } else { - ret = lowiWifiHalApi->start_gscan(id, iface, params, handler); - ALOGV("%s: lowi start_gscan " - "returned: %d. Exit.", __FUNCTION__, ret); - return (wifi_error)ret; - } - ALOGV("%s: RequestId:%d ", __FUNCTION__, id); /* Wi-Fi HAL doesn't need to check if a similar request to start gscan was * made earlier. If start_gscan() is called while another gscan is already @@ -445,7 +406,6 @@ wifi_error wifi_stop_gscan(wifi_request_id id, int ret = 0; GScanCommand *gScanCommand; struct nlattr *nlData; - lowi_cb_table_t *lowiWifiHalApi = NULL; interface_info *ifaceInfo = getIfaceInfo(iface); wifi_handle wifiHandle = getWifiHandle(iface); @@ -462,18 +422,6 @@ wifi_error wifi_stop_gscan(wifi_request_id id, return WIFI_ERROR_NOT_SUPPORTED; } - /* Route GSCAN request through LOWI if supported */ - lowiWifiHalApi = getLowiCallbackTable(GSCAN_SUPPORTED); - if (lowiWifiHalApi == NULL || - lowiWifiHalApi->stop_gscan == NULL) { - ALOGV("%s: Sending cmd directly to host", __FUNCTION__); - } else { - ret = lowiWifiHalApi->stop_gscan(id, iface); - ALOGV("%s: lowi stop_gscan " - "returned: %d. Exit.", __FUNCTION__, ret); - return (wifi_error)ret; - } - if (gScanStartCmdEventHandler == NULL || gScanStartCmdEventHandler->isEventHandlingEnabled() == false) { ALOGE("%s: GSCAN isn't running or already stopped. " @@ -541,7 +489,6 @@ wifi_error wifi_set_bssid_hotlist(wifi_request_id id, interface_info *ifaceInfo = getIfaceInfo(iface); wifi_handle wifiHandle = getWifiHandle(iface); hal_info *info = getHalInfo(wifiHandle); - lowi_cb_table_t *lowiWifiHalApi = NULL; gscan_event_handlers* event_handlers; GScanCommandEventHandler *gScanSetBssidHotlistCmdEventHandler; @@ -555,18 +502,6 @@ wifi_error wifi_set_bssid_hotlist(wifi_request_id id, return WIFI_ERROR_NOT_SUPPORTED; } - /* Route request through LOWI if supported*/ - lowiWifiHalApi = getLowiCallbackTable(GSCAN_SUPPORTED); - if (lowiWifiHalApi == NULL || - lowiWifiHalApi->set_bssid_hotlist == NULL) { - ALOGV("%s: Sending cmd directly to host", __FUNCTION__); - } else { - ret = lowiWifiHalApi->set_bssid_hotlist(id, iface, params,handler); - ALOGV("%s: lowi set_bssid_hotlist " - "returned: %d. Exit.", __FUNCTION__, ret); - return (wifi_error)ret; - } - /* Wi-Fi HAL doesn't need to check if a similar request to set bssid * hotlist was made earlier. If set_bssid_hotlist() is called while * another one is running, the request will be sent down to driver and @@ -714,7 +649,6 @@ wifi_error wifi_reset_bssid_hotlist(wifi_request_id id, interface_info *ifaceInfo = getIfaceInfo(iface); wifi_handle wifiHandle = getWifiHandle(iface); hal_info *info = getHalInfo(wifiHandle); - lowi_cb_table_t *lowiWifiHalApi = NULL; gscan_event_handlers* event_handlers; GScanCommandEventHandler *gScanSetBssidHotlistCmdEventHandler; @@ -728,19 +662,6 @@ wifi_error wifi_reset_bssid_hotlist(wifi_request_id id, return WIFI_ERROR_NOT_SUPPORTED; } - /* Route request through LOWI if supported*/ - lowiWifiHalApi = getLowiCallbackTable(GSCAN_SUPPORTED); - if (lowiWifiHalApi == NULL || - lowiWifiHalApi->reset_bssid_hotlist == NULL) { - ALOGV("%s: Sending cmd directly to host", __FUNCTION__); - } else { - ret = lowiWifiHalApi->reset_bssid_hotlist(id, iface); - ALOGV("%s: lowi reset_bssid_hotlist " - "returned: %d. Exit.", __FUNCTION__, ret); - return (wifi_error)ret; - } - - if (gScanSetBssidHotlistCmdEventHandler == NULL || (gScanSetBssidHotlistCmdEventHandler->isEventHandlingEnabled() == false)) { @@ -809,7 +730,6 @@ wifi_error wifi_set_significant_change_handler(wifi_request_id id, interface_info *ifaceInfo = getIfaceInfo(iface); wifi_handle wifiHandle = getWifiHandle(iface); hal_info *info = getHalInfo(wifiHandle); - lowi_cb_table_t *lowiWifiHalApi = NULL; gscan_event_handlers* event_handlers; GScanCommandEventHandler *gScanSetSignificantChangeCmdEventHandler; @@ -823,21 +743,6 @@ wifi_error wifi_set_significant_change_handler(wifi_request_id id, return WIFI_ERROR_NOT_SUPPORTED; } - /* Route request through LOWI if supported*/ - lowiWifiHalApi = getLowiCallbackTable(GSCAN_SUPPORTED); - if (lowiWifiHalApi == NULL || - lowiWifiHalApi->set_significant_change_handler == NULL) { - ALOGV("%s: Sending cmd directly to host", __FUNCTION__); - } else { - ret = lowiWifiHalApi->set_significant_change_handler(id, - iface, - params, - handler); - ALOGV("%s: lowi set_significant_change_handler " - "returned: %d. Exit.", __FUNCTION__, ret); - return (wifi_error)ret; - } - /* Wi-Fi HAL doesn't need to check if a similar request to set significant * change list was made earlier. If set_significant_change() is called while * another one is running, the request will be sent down to driver and @@ -997,7 +902,6 @@ wifi_error wifi_reset_significant_change_handler(wifi_request_id id, interface_info *ifaceInfo = getIfaceInfo(iface); wifi_handle wifiHandle = getWifiHandle(iface); hal_info *info = getHalInfo(wifiHandle); - lowi_cb_table_t *lowiWifiHalApi = NULL; gscan_event_handlers* event_handlers; GScanCommandEventHandler *gScanSetSignificantChangeCmdEventHandler; @@ -1011,18 +915,6 @@ wifi_error wifi_reset_significant_change_handler(wifi_request_id id, return WIFI_ERROR_NOT_SUPPORTED; } - /* Route request through LOWI if supported*/ - lowiWifiHalApi = getLowiCallbackTable(GSCAN_SUPPORTED); - if (lowiWifiHalApi == NULL || - lowiWifiHalApi->reset_significant_change_handler == NULL) { - ALOGV("%s: Sending cmd directly to host", __FUNCTION__); - } else { - ret = lowiWifiHalApi->reset_significant_change_handler(id, iface); - ALOGV("%s: lowi reset_significant_change_handler " - "returned: %d. Exit.", __FUNCTION__, ret); - return (wifi_error)ret; - } - if (gScanSetSignificantChangeCmdEventHandler == NULL || (gScanSetSignificantChangeCmdEventHandler->isEventHandlingEnabled() == false)) { @@ -1090,7 +982,6 @@ wifi_error wifi_get_cached_gscan_results(wifi_interface_handle iface, int requestId, ret = 0, retRequestRsp = 0; GScanCommand *gScanCommand; struct nlattr *nlData; - lowi_cb_table_t *lowiWifiHalApi = NULL; interface_info *ifaceInfo = getIfaceInfo(iface); wifi_handle wifiHandle = getWifiHandle(iface); @@ -1102,22 +993,6 @@ wifi_error wifi_get_cached_gscan_results(wifi_interface_handle iface, return WIFI_ERROR_NOT_SUPPORTED; } - /* Route GSCAN request through LOWI if supported */ - lowiWifiHalApi = getLowiCallbackTable(GSCAN_SUPPORTED); - if (lowiWifiHalApi == NULL || - lowiWifiHalApi->get_cached_gscan_results == NULL) { - ALOGV("%s: Sending cmd directly to host", __FUNCTION__); - } else { - ret = lowiWifiHalApi->get_cached_gscan_results(iface, - flush, - max, - results, - num); - ALOGV("%s: lowi get_cached_gscan_results" - "returned: %d. Exit.", __FUNCTION__, ret); - return (wifi_error)ret; - } - /* No request id from caller, so generate one and pass it on to the driver. */ /* Generate it randomly */ requestId = get_requestid(); |