From b07d3ff578b635fd3f08cd50b159f0604a2b5fdd Mon Sep 17 00:00:00 2001 From: Jeff Johnson Date: Sun, 15 Oct 2017 18:38:53 -0700 Subject: [PATCH] qcacld-3.0: Remove obsolete STA support for SIOCGIWAP At one time the predecessor to the current driver was managed via wireless extensions, but now the driver is managed by cfg80211. The STA implementation of SIOCGIWAP should no longer be used, so remove it. Change-Id: Ic513986029090b55f3df2ea31d07cf1594d17d4d CRs-Fixed: 2128993 --- core/hdd/inc/wlan_hdd_wext.h | 4 --- core/hdd/src/wlan_hdd_assoc.c | 65 ----------------------------------- core/hdd/src/wlan_hdd_wext.c | 2 +- 3 files changed, 1 insertion(+), 70 deletions(-) diff --git a/core/hdd/inc/wlan_hdd_wext.h b/core/hdd/inc/wlan_hdd_wext.h index 8610cbaff164..42fafdbe7097 100644 --- a/core/hdd/inc/wlan_hdd_wext.h +++ b/core/hdd/inc/wlan_hdd_wext.h @@ -280,10 +280,6 @@ extern int iw_set_ap_address(struct net_device *dev, struct iw_request_info *info, union iwreq_data *wrqu, char *extra); -extern int iw_get_ap_address(struct net_device *dev, - struct iw_request_info *info, - union iwreq_data *wrqu, char *extra); - extern int iw_set_var_ints_getnone(struct net_device *dev, struct iw_request_info *info, union iwreq_data *wrqu, char *extra); diff --git a/core/hdd/src/wlan_hdd_assoc.c b/core/hdd/src/wlan_hdd_assoc.c index 46cbe84b8c4b..fabc7cf03558 100644 --- a/core/hdd/src/wlan_hdd_assoc.c +++ b/core/hdd/src/wlan_hdd_assoc.c @@ -5362,68 +5362,3 @@ int iw_set_ap_address(struct net_device *dev, struct iw_request_info *info, return ret; } - -/** - * __iw_get_ap_address() - get ap address - * @dev: pointer to the net device - * @info: pointer to the iw request info - * @wrqu: pointer to iwreq_data - * @extra: pointer to the data - * - * This function returns currently associated BSSID. - * - * Return: 0 on success, error number otherwise - */ -static int __iw_get_ap_address(struct net_device *dev, - struct iw_request_info *info, - union iwreq_data *wrqu, char *extra) -{ - struct hdd_adapter *adapter = WLAN_HDD_GET_PRIV_PTR(dev); - struct hdd_context *hdd_ctx; - struct hdd_station_ctx *sta_ctx = - WLAN_HDD_GET_STATION_CTX_PTR(adapter); - int ret; - - ENTER_DEV(dev); - - hdd_ctx = WLAN_HDD_GET_CTX(adapter); - ret = wlan_hdd_validate_context(hdd_ctx); - if (ret) - return ret; - - ret = hdd_check_standard_wext_control(hdd_ctx, info); - if (0 != ret) - return ret; - - if (sta_ctx->conn_info.connState == eConnectionState_Associated || - eConnectionState_IbssConnected == sta_ctx->conn_info.connState) { - qdf_mem_copy(wrqu->ap_addr.sa_data, - sta_ctx->conn_info.bssId.bytes, - QDF_MAC_ADDR_SIZE); - } else { - memset(wrqu->ap_addr.sa_data, 0, sizeof(wrqu->ap_addr.sa_data)); - } - EXIT(); - return 0; -} - -/** - * iw_get_ap_address() - get ap addresses callback function - * @dev: Pointer to the net device. - * @info: Pointer to the iw_request_info. - * @wrqu: Pointer to the iwreq_data. - * @extra: Pointer to the data. - * - * Return: 0 for success, error number on failure. - */ -int iw_get_ap_address(struct net_device *dev, struct iw_request_info *info, - union iwreq_data *wrqu, char *extra) -{ - int ret; - - cds_ssr_protect(__func__); - ret = __iw_get_ap_address(dev, info, wrqu, extra); - cds_ssr_unprotect(__func__); - - return ret; -} diff --git a/core/hdd/src/wlan_hdd_wext.c b/core/hdd/src/wlan_hdd_wext.c index a1b355f6dbfa..87f0625d20c4 100644 --- a/core/hdd/src/wlan_hdd_wext.c +++ b/core/hdd/src/wlan_hdd_wext.c @@ -11232,7 +11232,7 @@ static const iw_handler we_handler[] = { (iw_handler) NULL, /* SIOCSIWTHRSPY */ (iw_handler) NULL, /* SIOCGIWTHRSPY */ (iw_handler) iw_set_ap_address, /* SIOCSIWAP */ - (iw_handler) iw_get_ap_address, /* SIOCGIWAP */ + (iw_handler) NULL, /* SIOCGIWAP */ (iw_handler) NULL, /* SIOCSIWMLME */ (iw_handler) NULL, /* SIOCGIWAPLIST */ (iw_handler) NULL, /* SIOCSIWSCAN */