aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/mwifiex/scan.c
diff options
context:
space:
mode:
authorArend van Spriel <arend@broadcom.com>2012-10-12 06:28:14 -0400
committerJohannes Berg <johannes.berg@intel.com>2012-10-18 03:01:54 -0400
commit04b2312a683537eec3dbac013920b0e3cfc06123 (patch)
tree6652aea04871bbbf6beda1e4d42cbb9a15a9019c /drivers/net/wireless/mwifiex/scan.c
parentc13a765bd96f4e2f52d218ee6e5c0715380eeeb8 (diff)
wireless: drivers: make use of WLAN_EID_VENDOR_SPECIFIC
The include file linux/ieee80211.h contains three definitions for the same thing in enum ieee80211_eid due to historic changes: /* Information Element IDs */ enum ieee80211_eid { : WLAN_EID_WPA = 221, WLAN_EID_GENERIC = 221, WLAN_EID_VENDOR_SPECIFIC = 221, : }; The standard refers to this as "vendor specific" element so the other two definitions are better not used. This patch changes the wireless drivers to use one definition, ie. WLAN_EID_VENDOR_SPECIFIC. Cc: Jouni Malinen <j@w1.fi> Cc: Dan Williams <dcbw@redhat.com> Cc: Larry Finger <Larry.Finger@lwfinger.net> Acked-by: Kalle Valo <kvalo@qca.qualcomm.com> [ath6kl] Acked-by: Bing Zhao <bzhao@marvell.com> [mwifiex] Acked-by: Stanislav Yakovlev <stas.yakovlev@gmail.com> [ipw2x00] Signed-off-by: Arend van Spriel <arend@broadcom.com> [change libipw as well] Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'drivers/net/wireless/mwifiex/scan.c')
-rw-r--r--drivers/net/wireless/mwifiex/scan.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/drivers/net/wireless/mwifiex/scan.c b/drivers/net/wireless/mwifiex/scan.c
index 00b658d3b6ec..5896b1fb4a2d 100644
--- a/drivers/net/wireless/mwifiex/scan.c
+++ b/drivers/net/wireless/mwifiex/scan.c
@@ -153,7 +153,7 @@ mwifiex_is_wpa_oui_present(struct mwifiex_bssdescriptor *bss_desc, u32 cipher)
153 153
154 if (((bss_desc->bcn_wpa_ie) && 154 if (((bss_desc->bcn_wpa_ie) &&
155 ((*(bss_desc->bcn_wpa_ie)).vend_hdr.element_id == 155 ((*(bss_desc->bcn_wpa_ie)).vend_hdr.element_id ==
156 WLAN_EID_WPA))) { 156 WLAN_EID_VENDOR_SPECIFIC))) {
157 iebody = (struct ie_body *) bss_desc->bcn_wpa_ie->data; 157 iebody = (struct ie_body *) bss_desc->bcn_wpa_ie->data;
158 oui = &mwifiex_wpa_oui[cipher][0]; 158 oui = &mwifiex_wpa_oui[cipher][0];
159 ret = mwifiex_search_oui_in_ie(iebody, oui); 159 ret = mwifiex_search_oui_in_ie(iebody, oui);
@@ -202,7 +202,7 @@ mwifiex_is_bss_no_sec(struct mwifiex_private *priv,
202 if (!priv->sec_info.wep_enabled && !priv->sec_info.wpa_enabled && 202 if (!priv->sec_info.wep_enabled && !priv->sec_info.wpa_enabled &&
203 !priv->sec_info.wpa2_enabled && ((!bss_desc->bcn_wpa_ie) || 203 !priv->sec_info.wpa2_enabled && ((!bss_desc->bcn_wpa_ie) ||
204 ((*(bss_desc->bcn_wpa_ie)).vend_hdr.element_id != 204 ((*(bss_desc->bcn_wpa_ie)).vend_hdr.element_id !=
205 WLAN_EID_WPA)) && 205 WLAN_EID_VENDOR_SPECIFIC)) &&
206 ((!bss_desc->bcn_rsn_ie) || 206 ((!bss_desc->bcn_rsn_ie) ||
207 ((*(bss_desc->bcn_rsn_ie)).ieee_hdr.element_id != 207 ((*(bss_desc->bcn_rsn_ie)).ieee_hdr.element_id !=
208 WLAN_EID_RSN)) && 208 WLAN_EID_RSN)) &&
@@ -237,7 +237,8 @@ mwifiex_is_bss_wpa(struct mwifiex_private *priv,
237{ 237{
238 if (!priv->sec_info.wep_enabled && priv->sec_info.wpa_enabled && 238 if (!priv->sec_info.wep_enabled && priv->sec_info.wpa_enabled &&
239 !priv->sec_info.wpa2_enabled && ((bss_desc->bcn_wpa_ie) && 239 !priv->sec_info.wpa2_enabled && ((bss_desc->bcn_wpa_ie) &&
240 ((*(bss_desc->bcn_wpa_ie)).vend_hdr.element_id == WLAN_EID_WPA)) 240 ((*(bss_desc->bcn_wpa_ie)).
241 vend_hdr.element_id == WLAN_EID_VENDOR_SPECIFIC))
241 /* 242 /*
242 * Privacy bit may NOT be set in some APs like 243 * Privacy bit may NOT be set in some APs like
243 * LinkSys WRT54G && bss_desc->privacy 244 * LinkSys WRT54G && bss_desc->privacy
@@ -309,7 +310,8 @@ mwifiex_is_bss_adhoc_aes(struct mwifiex_private *priv,
309 if (!priv->sec_info.wep_enabled && !priv->sec_info.wpa_enabled && 310 if (!priv->sec_info.wep_enabled && !priv->sec_info.wpa_enabled &&
310 !priv->sec_info.wpa2_enabled && 311 !priv->sec_info.wpa2_enabled &&
311 ((!bss_desc->bcn_wpa_ie) || 312 ((!bss_desc->bcn_wpa_ie) ||
312 ((*(bss_desc->bcn_wpa_ie)).vend_hdr.element_id != WLAN_EID_WPA)) && 313 ((*(bss_desc->bcn_wpa_ie)).
314 vend_hdr.element_id != WLAN_EID_VENDOR_SPECIFIC)) &&
313 ((!bss_desc->bcn_rsn_ie) || 315 ((!bss_desc->bcn_rsn_ie) ||
314 ((*(bss_desc->bcn_rsn_ie)).ieee_hdr.element_id != WLAN_EID_RSN)) && 316 ((*(bss_desc->bcn_rsn_ie)).ieee_hdr.element_id != WLAN_EID_RSN)) &&
315 !priv->sec_info.encryption_mode && bss_desc->privacy) { 317 !priv->sec_info.encryption_mode && bss_desc->privacy) {
@@ -329,7 +331,8 @@ mwifiex_is_bss_dynamic_wep(struct mwifiex_private *priv,
329 if (!priv->sec_info.wep_enabled && !priv->sec_info.wpa_enabled && 331 if (!priv->sec_info.wep_enabled && !priv->sec_info.wpa_enabled &&
330 !priv->sec_info.wpa2_enabled && 332 !priv->sec_info.wpa2_enabled &&
331 ((!bss_desc->bcn_wpa_ie) || 333 ((!bss_desc->bcn_wpa_ie) ||
332 ((*(bss_desc->bcn_wpa_ie)).vend_hdr.element_id != WLAN_EID_WPA)) && 334 ((*(bss_desc->bcn_wpa_ie)).
335 vend_hdr.element_id != WLAN_EID_VENDOR_SPECIFIC)) &&
333 ((!bss_desc->bcn_rsn_ie) || 336 ((!bss_desc->bcn_rsn_ie) ||
334 ((*(bss_desc->bcn_rsn_ie)).ieee_hdr.element_id != WLAN_EID_RSN)) && 337 ((*(bss_desc->bcn_rsn_ie)).ieee_hdr.element_id != WLAN_EID_RSN)) &&
335 priv->sec_info.encryption_mode && bss_desc->privacy) { 338 priv->sec_info.encryption_mode && bss_desc->privacy) {