wlan: Fix DHCP failure caused by PTK overwrite
On disconnection we are clearing WextState->roamProfile
and on re-association will be using key type from the same.
This causing HDD to send PTK set request again to the
firmware with 0 encryption type leading to DHCP failure.
Change-Id: I66490e565e32a8f487086823d8847060746f9c3b
CRs-Fixed: 529205
diff --git a/CORE/HDD/src/wlan_hdd_cfg80211.c b/CORE/HDD/src/wlan_hdd_cfg80211.c
index 718f885..729033e 100644
--- a/CORE/HDD/src/wlan_hdd_cfg80211.c
+++ b/CORE/HDD/src/wlan_hdd_cfg80211.c
@@ -3897,9 +3897,9 @@
)
{
if ( (eCSR_ENCRYPT_TYPE_TKIP !=
- pWextState->roamProfile.EncryptionType.encryptionType[0]) &&
+ pHddStaCtx->conn_info.ucEncryptionType) &&
(eCSR_ENCRYPT_TYPE_AES !=
- pWextState->roamProfile.EncryptionType.encryptionType[0])
+ pHddStaCtx->conn_info.ucEncryptionType)
)
{
/* if default key index is not same as previous one,