From: Amitkumar Karwar Date: Sat, 25 Feb 2012 05:35:35 +0000 (-0800) Subject: mwifiex: reset encryption mode flag before association X-Git-Tag: v3.3-rc7~11^2~10^2^2~1 X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=00f157b49780e194c38dafdf9df8e10b8a6a9626;p=~emulex%2Finfiniband.git mwifiex: reset encryption mode flag before association Recent commit "mwifiex: clear previous security setting during association" fixes association failure problems observed in some corner cases by clearing previous security setting before each association. We should reset encryption mode flag as well. This patch takes care of it. Signed-off-by: Amitkumar Karwar Signed-off-by: Bing Zhao Signed-off-by: John W. Linville --- diff --git a/drivers/net/wireless/mwifiex/cfg80211.c b/drivers/net/wireless/mwifiex/cfg80211.c index 5b2972b43b0..2210a0f9af2 100644 --- a/drivers/net/wireless/mwifiex/cfg80211.c +++ b/drivers/net/wireless/mwifiex/cfg80211.c @@ -846,6 +846,7 @@ mwifiex_cfg80211_assoc(struct mwifiex_private *priv, size_t ssid_len, u8 *ssid, priv->sec_info.wpa_enabled = false; priv->sec_info.wpa2_enabled = false; priv->wep_key_curr_index = 0; + priv->sec_info.encryption_mode = 0; ret = mwifiex_set_encode(priv, NULL, 0, 0, 1); if (mode == NL80211_IFTYPE_ADHOC) {