]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
wcn36xx: Clear encrypt_type when deleting bss key
authorPontus Fuchs <pontus.fuchs@gmail.com>
Tue, 19 Apr 2016 05:00:50 +0000 (22:00 -0700)
committerKalle Valo <kvalo@qca.qualcomm.com>
Mon, 25 Apr 2016 17:37:06 +0000 (20:37 +0300)
This fixes a problem connecting to an open network after being
connected to an encrypted network.

Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com>
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
drivers/net/wireless/ath/wcn36xx/main.c

index 7c06ca9fdd2c7acb0d8227a98319876694290927..f9c77de9458360e1ff4ce0f7539b3848d3107baa 100644 (file)
@@ -471,6 +471,7 @@ static int wcn36xx_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd,
                break;
        case DISABLE_KEY:
                if (!(IEEE80211_KEY_FLAG_PAIRWISE & key_conf->flags)) {
+                       vif_priv->encrypt_type = WCN36XX_HAL_ED_NONE;
                        wcn36xx_smd_remove_bsskey(wcn,
                                vif_priv->encrypt_type,
                                key_conf->keyidx);
@@ -626,6 +627,7 @@ static void wcn36xx_bss_info_changed(struct ieee80211_hw *hw,
                } else {
                        vif_priv->is_joining = false;
                        wcn36xx_smd_delete_bss(wcn, vif);
+                       vif_priv->encrypt_type = WCN36XX_HAL_ED_NONE;
                }
        }