mwifiex: remove redundant encryption_mode mapping
remove MWIFIEX_ENCRYPTION_MODE_ and use WLAN_CIPHER_SUITE_
macros directly
Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
diff --git a/drivers/net/wireless/mwifiex/scan.c b/drivers/net/wireless/mwifiex/scan.c
index 64ed60a8..6bb52d0 100644
--- a/drivers/net/wireless/mwifiex/scan.c
+++ b/drivers/net/wireless/mwifiex/scan.c
@@ -273,8 +273,8 @@
&& ((!bss_desc->bcn_rsn_ie) ||
((*(bss_desc->bcn_rsn_ie)).ieee_hdr.element_id !=
WLAN_EID_RSN))
- && priv->sec_info.encryption_mode ==
- MWIFIEX_ENCRYPTION_MODE_NONE && !bss_desc->privacy) {
+ && !priv->sec_info.encryption_mode
+ && !bss_desc->privacy) {
return true;
}
return false;
@@ -386,8 +386,8 @@
element_id != WLAN_EID_WPA))
&& ((!bss_desc->bcn_rsn_ie) || ((*(bss_desc->bcn_rsn_ie)).ieee_hdr.
element_id != WLAN_EID_RSN))
- && priv->sec_info.encryption_mode ==
- MWIFIEX_ENCRYPTION_MODE_NONE && bss_desc->privacy) {
+ && !priv->sec_info.encryption_mode
+ && bss_desc->privacy) {
return true;
}
return false;
@@ -408,8 +408,8 @@
element_id != WLAN_EID_WPA))
&& ((!bss_desc->bcn_rsn_ie) || ((*(bss_desc->bcn_rsn_ie)).ieee_hdr.
element_id != WLAN_EID_RSN))
- && priv->sec_info.encryption_mode !=
- MWIFIEX_ENCRYPTION_MODE_NONE && bss_desc->privacy) {
+ && priv->sec_info.encryption_mode
+ && bss_desc->privacy) {
dev_dbg(priv->adapter->dev, "info: %s: dynamic "
"WEP: index=%d wpa_ie=%#x wpa2_ie=%#x "
"EncMode=%#x privacy=%#x\n",