From: Jes Sorensen Date: Mon, 9 Jun 2014 13:16:01 +0000 (+0200) Subject: staging: rtl8723au: Remove obsolete rtw_get_sec_ie23a() X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=0b548a5c4d55058393b27c888a5cd04610c95ee3;p=openwrt%2Fstaging%2Fblogic.git staging: rtl8723au: Remove obsolete rtw_get_sec_ie23a() Signed-off-by: Jes Sorensen Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/rtl8723au/core/rtw_ieee80211.c b/drivers/staging/rtl8723au/core/rtw_ieee80211.c index 484272e66177..cbb1b85bd727 100644 --- a/drivers/staging/rtl8723au/core/rtw_ieee80211.c +++ b/drivers/staging/rtl8723au/core/rtw_ieee80211.c @@ -621,81 +621,6 @@ int rtw_parse_wpa2_ie23a(const u8* rsn_ie, int rsn_ie_len, int *group_cipher, return ret; } -int rtw_get_sec_ie23a(u8 *in_ie, uint in_len, u8 *rsn_ie, u16 *rsn_len, - u8 *wpa_ie, u16 *wpa_len) -{ - u8 authmode, sec_idx, i; - uint cnt; - - - /* Search required WPA or WPA2 IE and copy to sec_ie[ ] */ - - cnt = (_TIMESTAMP_ + _BEACON_ITERVAL_ + _CAPABILITY_); - - sec_idx = 0; - - while(cnt < in_len) { - authmode = in_ie[cnt]; - - if ((authmode == WLAN_EID_VENDOR_SPECIFIC) && - !memcmp(&in_ie[cnt+2], RTW_WPA_OUI23A_TYPE, 4)) { - RT_TRACE(_module_rtl871x_mlme_c_, _drv_info_, - ("\n rtw_get_wpa_ie23a: sec_idx =%d " - "in_ie[cnt+1]+2 =%d\n", - sec_idx, in_ie[cnt + 1] + 2)); - - if (wpa_ie) { - memcpy(wpa_ie, &in_ie[cnt], in_ie[cnt+1]+2); - - for (i = 0; i < (in_ie[cnt + 1] + 2); i = i + 8) { - RT_TRACE(_module_rtl871x_mlme_c_, - _drv_info_, - ("\n %2x,%2x,%2x,%2x,%2x,%2x," - "%2x,%2x\n", wpa_ie[i], - wpa_ie[i + 1], wpa_ie[i + 2], - wpa_ie[i + 3], wpa_ie[i + 4], - wpa_ie[i + 5], wpa_ie[i + 6], - wpa_ie[i + 7])); - } - } - - *wpa_len = in_ie[cnt + 1] + 2; - cnt += in_ie[cnt + 1] + 2; /* get next */ - } else { - if (authmode == _WPA2_IE_ID_) { - RT_TRACE(_module_rtl871x_mlme_c_, _drv_info_, - ("\n get_rsn_ie: sec_idx =%d in_ie" - "[cnt+1]+2 =%d\n", sec_idx, - in_ie[cnt + 1] + 2)); - - if (rsn_ie) { - memcpy(rsn_ie, &in_ie[cnt], in_ie[cnt + 1] + 2); - - for (i = 0; i < (in_ie[cnt + 1] + 2); i = i + 8) { - RT_TRACE(_module_rtl871x_mlme_c_, - _drv_info_, - ("\n %2x,%2x,%2x,%2x,%2x,%2x," - "%2x,%2x\n", rsn_ie[i], - rsn_ie[i + 1], rsn_ie[i + 2], - rsn_ie[i + 3], rsn_ie[i + 4], - rsn_ie[i + 5], rsn_ie[i + 6], - rsn_ie[i + 7])); - } - } - - *rsn_len = in_ie[cnt + 1] + 2; - cnt += in_ie[cnt + 1] + 2; /* get next */ - } else { - cnt += in_ie[cnt + 1] + 2; /* get next */ - } - } - } - - - - return *rsn_len + *wpa_len; -} - /** * rtw_get_wps_attr23a - Search a specific WPS attribute from a given WPS IE * @wps_ie: Address of WPS IE to search diff --git a/drivers/staging/rtl8723au/include/ieee80211.h b/drivers/staging/rtl8723au/include/ieee80211.h index 6f42d2db9ea1..373897831f8a 100644 --- a/drivers/staging/rtl8723au/include/ieee80211.h +++ b/drivers/staging/rtl8723au/include/ieee80211.h @@ -430,8 +430,6 @@ int rtw_get_wpa2_cipher_suite23a(const u8 *s); int rtw_parse_wpa_ie23a(const u8* wpa_ie, int wpa_ie_len, int *group_cipher, int *pairwise_cipher, int *is_8021x); int rtw_parse_wpa2_ie23a(const u8* wpa_ie, int wpa_ie_len, int *group_cipher, int *pairwise_cipher, int *is_8021x); -int rtw_get_sec_ie23a(u8 *in_ie,uint in_len,u8 *rsn_ie,u16 *rsn_len,u8 *wpa_ie,u16 *wpa_len); - const u8 *rtw_get_wps_attr23a(const u8 *wps_ie, uint wps_ielen, u16 target_attr_id ,u8 *buf_attr, u32 *len_attr); const u8 *rtw_get_wps_attr_content23a(const u8 *wps_ie, uint wps_ielen, u16 target_attr_id ,u8 *buf_content, uint *len_content);